diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-07 10:29:24 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-10-07 10:29:24 +0200 |
commit | e665faa424a4a782aa986274920c1fc5b76f5560 (patch) | |
tree | 2cf64abadecbbeadcffc02cb7671cb593fc45488 /drivers/power/twl4030_charger.c | |
parent | Merge tag 'rdma-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/r... (diff) | |
parent | Merge with upstream to accommodate with MFD changes (diff) | |
download | linux-e665faa424a4a782aa986274920c1fc5b76f5560.tar.xz linux-e665faa424a4a782aa986274920c1fc5b76f5560.zip |
Merge tag 'for-v3.7' of git://git.infradead.org/battery-2.6
Pull battery updates from Anton Vorontsov:
"1. New drivers:
- Marvell 88pm860x charger and battery drivers;
- Texas Instruments LP8788 charger driver;
2. Two new power supply properties: whether a battery is authentic,
and chargers' maximal currents and voltages;
3. A lot of TI LP8727 Charger cleanups;
4. New features for Charger Manager, mainly now we can disable
specific regulators;
5. Random fixes and cleanups for other drivers."
Fix up trivial conflicts in <linux/mfd/88pm860x.h>
* tag 'for-v3.7' of git://git.infradead.org/battery-2.6: (52 commits)
pda_power: Remove ac_draw_failed goto and label
charger-manager: Add support sysfs entry for charger
charger-manager: Support limit of maximum possible
charger-manager: Check fully charged state of battery periodically
lp8727_charger: More pure cosmetic improvements
lp8727_charger: Fix checkpatch warning
lp8727_charger: Add description in the private data
lp8727_charger: Fix a typo - chg_parm to chg_param
lp8727_charger: Make some cosmetic changes in lp8727_delayed_func()
lp8727_charger: Clean up lp8727_charger_changed()
lp8727_charger: Return if the battery is discharging
lp8727_charger: Make lp8727_charger_get_propery() simpler
lp8727_charger: Make lp8727_ctrl_switch() inline
lp8727_charger: Make lp8727_init_device() shorter
lp8727_charger: Clean up lp8727_is_charger_attached()
lp8727_charger: Use specific definition
lp8727_charger: Clean up lp8727 definitions
lp8727_charger: Use the definition rather than enum
lp8727_charger: Fix code for getting battery temp
lp8727_charger: Clear interrrupts at inital time
...
Diffstat (limited to 'drivers/power/twl4030_charger.c')
-rw-r--r-- | drivers/power/twl4030_charger.c | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/drivers/power/twl4030_charger.c b/drivers/power/twl4030_charger.c index 15f4d5d8611b..f9e70cf08199 100644 --- a/drivers/power/twl4030_charger.c +++ b/drivers/power/twl4030_charger.c @@ -41,16 +41,16 @@ #define TWL4030_STS_VBUS BIT(7) #define TWL4030_STS_USB_ID BIT(2) #define TWL4030_BBCHEN BIT(4) -#define TWL4030_BBSEL_MASK 0b1100 -#define TWL4030_BBSEL_2V5 0b0000 -#define TWL4030_BBSEL_3V0 0b0100 -#define TWL4030_BBSEL_3V1 0b1000 -#define TWL4030_BBSEL_3V2 0b1100 -#define TWL4030_BBISEL_MASK 0b11 -#define TWL4030_BBISEL_25uA 0b00 -#define TWL4030_BBISEL_150uA 0b01 -#define TWL4030_BBISEL_500uA 0b10 -#define TWL4030_BBISEL_1000uA 0b11 +#define TWL4030_BBSEL_MASK 0x0c +#define TWL4030_BBSEL_2V5 0x00 +#define TWL4030_BBSEL_3V0 0x04 +#define TWL4030_BBSEL_3V1 0x08 +#define TWL4030_BBSEL_3V2 0x0c +#define TWL4030_BBISEL_MASK 0x03 +#define TWL4030_BBISEL_25uA 0x00 +#define TWL4030_BBISEL_150uA 0x01 +#define TWL4030_BBISEL_500uA 0x02 +#define TWL4030_BBISEL_1000uA 0x03 /* BCI interrupts */ #define TWL4030_WOVF BIT(0) /* Watchdog overflow */ @@ -534,7 +534,8 @@ static int __init twl4030_bci_probe(struct platform_device *pdev) } ret = request_threaded_irq(bci->irq_chg, NULL, - twl4030_charger_interrupt, 0, pdev->name, bci); + twl4030_charger_interrupt, IRQF_ONESHOT, pdev->name, + bci); if (ret < 0) { dev_err(&pdev->dev, "could not request irq %d, status %d\n", bci->irq_chg, ret); @@ -542,7 +543,7 @@ static int __init twl4030_bci_probe(struct platform_device *pdev) } ret = request_threaded_irq(bci->irq_bci, NULL, - twl4030_bci_interrupt, 0, pdev->name, bci); + twl4030_bci_interrupt, IRQF_ONESHOT, pdev->name, bci); if (ret < 0) { dev_err(&pdev->dev, "could not request irq %d, status %d\n", bci->irq_bci, ret); |