bci 940 drivers/mfd/twl-core.c if (IS_ENABLED(CONFIG_CHARGER_TWL4030) && pdata->bci && bci 943 drivers/mfd/twl-core.c pdata->bci, sizeof(*pdata->bci), false, bci 467 drivers/mtd/inftlcore.c struct inftl_bci bci; bci 486 drivers/mtd/inftlcore.c blockofs, 8, &retlen, (char *)&bci); bci 488 drivers/mtd/inftlcore.c status = bci.Status | bci.Status1; bci 632 drivers/mtd/inftlcore.c struct inftl_bci bci; bci 660 drivers/mtd/inftlcore.c (char *)&bci) < 0) bci 663 drivers/mtd/inftlcore.c status = bci.Status | bci.Status1; bci 753 drivers/mtd/inftlcore.c struct inftl_bci bci; bci 760 drivers/mtd/inftlcore.c blockofs, 8, &retlen, (char *)&bci) < 0) bci 763 drivers/mtd/inftlcore.c status = bci.Status | bci.Status1; bci 794 drivers/mtd/inftlcore.c if (inftl_read_oob(mtd, ptr, 8, &retlen, (char *)&bci) < 0) bci 796 drivers/mtd/inftlcore.c bci.Status = bci.Status1 = SECTOR_DELETED; bci 797 drivers/mtd/inftlcore.c if (inftl_write_oob(mtd, ptr, 8, &retlen, (char *)&bci) < 0) bci 861 drivers/mtd/inftlcore.c struct inftl_bci bci; bci 869 drivers/mtd/inftlcore.c blockofs, 8, &retlen, (char *)&bci) < 0) bci 872 drivers/mtd/inftlcore.c status = bci.Status | bci.Status1; bci 545 drivers/mtd/nftlcore.c struct nftl_bci bci; bci 553 drivers/mtd/nftlcore.c 8, &retlen, (char *)&bci); bci 556 drivers/mtd/nftlcore.c block , writeEUN, le16_to_cpu(bci.Status)); bci 558 drivers/mtd/nftlcore.c status = bci.Status | bci.Status1; bci 712 drivers/mtd/nftlcore.c struct nftl_bci bci; bci 720 drivers/mtd/nftlcore.c (char *)&bci) < 0) bci 723 drivers/mtd/nftlcore.c status = bci.Status | bci.Status1; bci 376 drivers/mtd/nftlmount.c struct nftl_bci bci; bci 386 drivers/mtd/nftlmount.c 8, &retlen, (char *)&bci) < 0) bci 389 drivers/mtd/nftlmount.c status = bci.Status | bci.Status1; bci 395 drivers/mtd/nftlmount.c if (memcmpb(&bci, 0xff, 8) != 0 || bci 403 drivers/mtd/nftlmount.c bci.Status = SECTOR_IGNORE; bci 404 drivers/mtd/nftlmount.c bci.Status1 = SECTOR_IGNORE; bci 408 drivers/mtd/nftlmount.c &retlen, (char *)&bci); bci 238 drivers/power/supply/twl4030_charger.c static int twl4030_charger_update_current(struct twl4030_bci *bci) bci 251 drivers/power/supply/twl4030_charger.c if (ac_available(bci->channel_vac)) { bci 252 drivers/power/supply/twl4030_charger.c cur = bci->ac_cur; bci 253 drivers/power/supply/twl4030_charger.c bci->ac_is_active = true; bci 255 drivers/power/supply/twl4030_charger.c cur = bci->usb_cur; bci 256 drivers/power/supply/twl4030_charger.c bci->ac_is_active = false; bci 257 drivers/power/supply/twl4030_charger.c if (cur > bci->usb_cur_target) { bci 258 drivers/power/supply/twl4030_charger.c cur = bci->usb_cur_target; bci 259 drivers/power/supply/twl4030_charger.c bci->usb_cur = cur; bci 261 drivers/power/supply/twl4030_charger.c if (cur < bci->usb_cur_target) bci 262 drivers/power/supply/twl4030_charger.c schedule_delayed_work(&bci->current_worker, USB_CUR_DELAY); bci 266 drivers/power/supply/twl4030_charger.c if (bci->ichg_eoc >= 200000) bci 268 drivers/power/supply/twl4030_charger.c if (bci->ichg_lo >= 400000) bci 270 drivers/power/supply/twl4030_charger.c if (bci->ichg_hi >= 820000) bci 295 drivers/power/supply/twl4030_charger.c reg = ua2regval(bci->ichg_eoc, cgain); bci 307 drivers/power/supply/twl4030_charger.c reg = ua2regval(bci->ichg_lo, cgain); bci 329 drivers/power/supply/twl4030_charger.c reg = ua2regval(bci->ichg_hi, cgain); bci 403 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = container_of(data, struct twl4030_bci, bci 414 drivers/power/supply/twl4030_charger.c dev_dbg(bci->dev, "v=%d cur=%d limit=%d target=%d\n", v, curr, bci 415 drivers/power/supply/twl4030_charger.c bci->usb_cur, bci->usb_cur_target); bci 419 drivers/power/supply/twl4030_charger.c if (bci->usb_cur >= USB_CUR_STEP) bci 420 drivers/power/supply/twl4030_charger.c bci->usb_cur -= USB_CUR_STEP; bci 421 drivers/power/supply/twl4030_charger.c bci->usb_cur_target = bci->usb_cur; bci 422 drivers/power/supply/twl4030_charger.c } else if (bci->usb_cur >= bci->usb_cur_target || bci 423 drivers/power/supply/twl4030_charger.c bci->usb_cur + USB_CUR_STEP > USB_MAX_CURRENT) { bci 427 drivers/power/supply/twl4030_charger.c bci->usb_cur += USB_CUR_STEP; bci 428 drivers/power/supply/twl4030_charger.c schedule_delayed_work(&bci->current_worker, USB_CUR_DELAY); bci 430 drivers/power/supply/twl4030_charger.c twl4030_charger_update_current(bci); bci 436 drivers/power/supply/twl4030_charger.c static int twl4030_charger_enable_usb(struct twl4030_bci *bci, bool enable) bci 441 drivers/power/supply/twl4030_charger.c if (bci->usb_mode == CHARGE_OFF) bci 443 drivers/power/supply/twl4030_charger.c if (enable && !IS_ERR_OR_NULL(bci->transceiver)) { bci 445 drivers/power/supply/twl4030_charger.c twl4030_charger_update_current(bci); bci 448 drivers/power/supply/twl4030_charger.c if (!bci->usb_enabled) { bci 449 drivers/power/supply/twl4030_charger.c pm_runtime_get_sync(bci->transceiver->dev); bci 450 drivers/power/supply/twl4030_charger.c bci->usb_enabled = 1; bci 453 drivers/power/supply/twl4030_charger.c if (bci->usb_mode == CHARGE_AUTO) { bci 461 drivers/power/supply/twl4030_charger.c dev_err(bci->dev, bci 473 drivers/power/supply/twl4030_charger.c if (bci->usb_mode == CHARGE_LINEAR) { bci 480 drivers/power/supply/twl4030_charger.c dev_err(bci->dev, bci 513 drivers/power/supply/twl4030_charger.c if (bci->usb_enabled) { bci 514 drivers/power/supply/twl4030_charger.c pm_runtime_mark_last_busy(bci->transceiver->dev); bci 515 drivers/power/supply/twl4030_charger.c pm_runtime_put_autosuspend(bci->transceiver->dev); bci 516 drivers/power/supply/twl4030_charger.c bci->usb_enabled = 0; bci 518 drivers/power/supply/twl4030_charger.c bci->usb_cur = 0; bci 527 drivers/power/supply/twl4030_charger.c static int twl4030_charger_enable_ac(struct twl4030_bci *bci, bool enable) bci 531 drivers/power/supply/twl4030_charger.c if (bci->ac_mode == CHARGE_OFF) bci 590 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = arg; bci 592 drivers/power/supply/twl4030_charger.c dev_dbg(bci->dev, "CHG_PRES irq\n"); bci 594 drivers/power/supply/twl4030_charger.c bci->ac_cur = 500000; bci 595 drivers/power/supply/twl4030_charger.c twl4030_charger_update_current(bci); bci 596 drivers/power/supply/twl4030_charger.c power_supply_changed(bci->ac); bci 597 drivers/power/supply/twl4030_charger.c power_supply_changed(bci->usb); bci 607 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = arg; bci 621 drivers/power/supply/twl4030_charger.c dev_dbg(bci->dev, "BCI irq %02x %02x\n", irqs2, irqs1); bci 625 drivers/power/supply/twl4030_charger.c power_supply_changed(bci->ac); bci 626 drivers/power/supply/twl4030_charger.c power_supply_changed(bci->usb); bci 628 drivers/power/supply/twl4030_charger.c twl4030_charger_update_current(bci); bci 632 drivers/power/supply/twl4030_charger.c dev_warn(bci->dev, "battery temperature out of range\n"); bci 635 drivers/power/supply/twl4030_charger.c dev_crit(bci->dev, "battery disconnected\n"); bci 638 drivers/power/supply/twl4030_charger.c dev_crit(bci->dev, "VBAT overvoltage\n"); bci 641 drivers/power/supply/twl4030_charger.c dev_crit(bci->dev, "VBUS overvoltage\n"); bci 644 drivers/power/supply/twl4030_charger.c dev_crit(bci->dev, "Ac charger overvoltage\n"); bci 651 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = container_of(data, struct twl4030_bci, work); bci 653 drivers/power/supply/twl4030_charger.c switch (bci->event) { bci 656 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_usb(bci, true); bci 659 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_usb(bci, false); bci 667 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = container_of(nb, struct twl4030_bci, usb_nb); bci 669 drivers/power/supply/twl4030_charger.c dev_dbg(bci->dev, "OTG notify %lu\n", val); bci 673 drivers/power/supply/twl4030_charger.c bci->usb_cur_target = 500000; bci 675 drivers/power/supply/twl4030_charger.c bci->usb_cur_target = 100000; bci 677 drivers/power/supply/twl4030_charger.c bci->event = val; bci 678 drivers/power/supply/twl4030_charger.c schedule_work(&bci->work); bci 690 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = dev_get_drvdata(dev->parent); bci 698 drivers/power/supply/twl4030_charger.c if (dev == &bci->ac->dev) { bci 701 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_ac(bci, false); bci 702 drivers/power/supply/twl4030_charger.c bci->ac_mode = mode; bci 703 drivers/power/supply/twl4030_charger.c status = twl4030_charger_enable_ac(bci, true); bci 705 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_usb(bci, false); bci 706 drivers/power/supply/twl4030_charger.c bci->usb_mode = mode; bci 707 drivers/power/supply/twl4030_charger.c status = twl4030_charger_enable_usb(bci, true); bci 719 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = dev_get_drvdata(dev->parent); bci 722 drivers/power/supply/twl4030_charger.c int mode = bci->usb_mode; bci 724 drivers/power/supply/twl4030_charger.c if (dev == &bci->ac->dev) bci 725 drivers/power/supply/twl4030_charger.c mode = bci->ac_mode; bci 761 drivers/power/supply/twl4030_charger.c static int twl4030bci_state(struct twl4030_bci *bci) bci 768 drivers/power/supply/twl4030_charger.c dev_err(bci->dev, "error reading BCIMSTATEC\n"); bci 772 drivers/power/supply/twl4030_charger.c dev_dbg(bci->dev, "state: %02x\n", state); bci 793 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = dev_get_drvdata(psy->dev.parent); bci 798 drivers/power/supply/twl4030_charger.c state = twl4030bci_state(bci); bci 862 drivers/power/supply/twl4030_charger.c if (!bci->ac_is_active) bci 863 drivers/power/supply/twl4030_charger.c val->intval = bci->ac_cur; bci 865 drivers/power/supply/twl4030_charger.c if (bci->ac_is_active) bci 866 drivers/power/supply/twl4030_charger.c val->intval = bci->usb_cur_target; bci 892 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = dev_get_drvdata(psy->dev.parent); bci 897 drivers/power/supply/twl4030_charger.c bci->usb_cur_target = val->intval; bci 899 drivers/power/supply/twl4030_charger.c bci->ac_cur = val->intval; bci 900 drivers/power/supply/twl4030_charger.c twl4030_charger_update_current(bci); bci 978 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci; bci 983 drivers/power/supply/twl4030_charger.c bci = devm_kzalloc(&pdev->dev, sizeof(*bci), GFP_KERNEL); bci 984 drivers/power/supply/twl4030_charger.c if (bci == NULL) bci 990 drivers/power/supply/twl4030_charger.c bci->ichg_eoc = 80100; /* Stop charging when current drops to here */ bci 991 drivers/power/supply/twl4030_charger.c bci->ichg_lo = 241000; /* Low threshold */ bci 992 drivers/power/supply/twl4030_charger.c bci->ichg_hi = 500000; /* High threshold */ bci 993 drivers/power/supply/twl4030_charger.c bci->ac_cur = 500000; /* 500mA */ bci 995 drivers/power/supply/twl4030_charger.c bci->usb_cur_target = 500000; /* 500mA */ bci 997 drivers/power/supply/twl4030_charger.c bci->usb_cur_target = 100000; /* 100mA */ bci 998 drivers/power/supply/twl4030_charger.c bci->usb_mode = CHARGE_AUTO; bci 999 drivers/power/supply/twl4030_charger.c bci->ac_mode = CHARGE_AUTO; bci 1001 drivers/power/supply/twl4030_charger.c bci->dev = &pdev->dev; bci 1002 drivers/power/supply/twl4030_charger.c bci->irq_chg = platform_get_irq(pdev, 0); bci 1003 drivers/power/supply/twl4030_charger.c bci->irq_bci = platform_get_irq(pdev, 1); bci 1005 drivers/power/supply/twl4030_charger.c platform_set_drvdata(pdev, bci); bci 1007 drivers/power/supply/twl4030_charger.c INIT_WORK(&bci->work, twl4030_bci_usb_work); bci 1008 drivers/power/supply/twl4030_charger.c INIT_DELAYED_WORK(&bci->current_worker, twl4030_current_worker); bci 1010 drivers/power/supply/twl4030_charger.c bci->channel_vac = devm_iio_channel_get(&pdev->dev, "vac"); bci 1011 drivers/power/supply/twl4030_charger.c if (IS_ERR(bci->channel_vac)) { bci 1012 drivers/power/supply/twl4030_charger.c ret = PTR_ERR(bci->channel_vac); bci 1017 drivers/power/supply/twl4030_charger.c bci->channel_vac = NULL; bci 1020 drivers/power/supply/twl4030_charger.c if (bci->dev->of_node) { bci 1023 drivers/power/supply/twl4030_charger.c phynode = of_get_compatible_child(bci->dev->of_node->parent, bci 1026 drivers/power/supply/twl4030_charger.c bci->usb_nb.notifier_call = twl4030_bci_usb_ncb; bci 1027 drivers/power/supply/twl4030_charger.c bci->transceiver = devm_usb_get_phy_by_node( bci 1028 drivers/power/supply/twl4030_charger.c bci->dev, phynode, &bci->usb_nb); bci 1030 drivers/power/supply/twl4030_charger.c if (IS_ERR(bci->transceiver)) { bci 1031 drivers/power/supply/twl4030_charger.c ret = PTR_ERR(bci->transceiver); bci 1036 drivers/power/supply/twl4030_charger.c bci->transceiver = NULL; bci 1041 drivers/power/supply/twl4030_charger.c bci->ac = devm_power_supply_register(&pdev->dev, &twl4030_bci_ac_desc, bci 1043 drivers/power/supply/twl4030_charger.c if (IS_ERR(bci->ac)) { bci 1044 drivers/power/supply/twl4030_charger.c ret = PTR_ERR(bci->ac); bci 1049 drivers/power/supply/twl4030_charger.c bci->usb = devm_power_supply_register(&pdev->dev, &twl4030_bci_usb_desc, bci 1051 drivers/power/supply/twl4030_charger.c if (IS_ERR(bci->usb)) { bci 1052 drivers/power/supply/twl4030_charger.c ret = PTR_ERR(bci->usb); bci 1057 drivers/power/supply/twl4030_charger.c ret = devm_request_threaded_irq(&pdev->dev, bci->irq_chg, NULL, bci 1059 drivers/power/supply/twl4030_charger.c bci); bci 1062 drivers/power/supply/twl4030_charger.c bci->irq_chg, ret); bci 1066 drivers/power/supply/twl4030_charger.c ret = devm_request_threaded_irq(&pdev->dev, bci->irq_bci, NULL, bci 1067 drivers/power/supply/twl4030_charger.c twl4030_bci_interrupt, IRQF_ONESHOT, pdev->name, bci); bci 1070 drivers/power/supply/twl4030_charger.c bci->irq_bci, ret); bci 1090 drivers/power/supply/twl4030_charger.c twl4030_charger_update_current(bci); bci 1091 drivers/power/supply/twl4030_charger.c if (device_create_file(&bci->usb->dev, &dev_attr_mode)) bci 1093 drivers/power/supply/twl4030_charger.c if (device_create_file(&bci->ac->dev, &dev_attr_mode)) bci 1096 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_ac(bci, true); bci 1097 drivers/power/supply/twl4030_charger.c if (!IS_ERR_OR_NULL(bci->transceiver)) bci 1098 drivers/power/supply/twl4030_charger.c twl4030_bci_usb_ncb(&bci->usb_nb, bci 1099 drivers/power/supply/twl4030_charger.c bci->transceiver->last_event, bci 1102 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_usb(bci, false); bci 1114 drivers/power/supply/twl4030_charger.c struct twl4030_bci *bci = platform_get_drvdata(pdev); bci 1116 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_ac(bci, false); bci 1117 drivers/power/supply/twl4030_charger.c twl4030_charger_enable_usb(bci, false); bci 1120 drivers/power/supply/twl4030_charger.c device_remove_file(&bci->usb->dev, &dev_attr_mode); bci 1121 drivers/power/supply/twl4030_charger.c device_remove_file(&bci->ac->dev, &dev_attr_mode); bci 695 include/linux/mfd/twl.h struct twl4030_bci_platform_data *bci; bci 35 tools/perf/jvmti/libjvmti.c do_get_line_numbers(jvmtiEnv *jvmti, void *pc, jmethodID m, jint bci, bci 50 tools/perf/jvmti/libjvmti.c if (loc_tab[i].start_location < bci) {