diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2021-02-22 09:49:59 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2021-02-22 09:49:59 -0800 |
commit | a7dcf5f2356506677c03be5760b5b2111a24a1ec (patch) | |
tree | a75adb5005c01ad41a551d7cf1ae9050b3c1b9e1 /arch/arm | |
parent | 28b9aaac4cc5a11485b6f70656e4e9ead590cf5b (diff) | |
parent | a72acc56f3e939b9e10f2dd460ac1e4519de621f (diff) | |
download | linux-rpi-a7dcf5f2356506677c03be5760b5b2111a24a1ec.tar.gz linux-rpi-a7dcf5f2356506677c03be5760b5b2111a24a1ec.tar.bz2 linux-rpi-a7dcf5f2356506677c03be5760b5b2111a24a1ec.zip |
Merge tag 'for-v5.12' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply
Pull power supply and reset updates from Sebastian Reichel:
"Battery/charger driver changes:
- acer_a500: new fuel gauge driver for Acer Iconia Tab A500
- bq256xx: new charger driver
- bq27xxx: Support CHARGE_NOW for bq27z561/bq28z610/bq34z100
- bq27xxx: Fix inverted CURRENT_NOW sign
- cpcap: rework fuel gauge and charger drivers
- ltc4162l: new charger driver
- max8997-charger: add extcon based current limit configuration
- max8903, wm97xx, z2: convert to GPIO descriptors (incl. ARM board files)
- misc cleanup and fixes
Reset drivers:
- new poweroff driver for ATC260x
- at91-sama5d2_shdwc: add support for sama7g5
- drop zte zx driver (SoC support is removed from kernel)"
* tag 'for-v5.12' of git://git.kernel.org/pub/scm/linux/kernel/git/sre/linux-power-supply: (55 commits)
power-supply: use kobj_to_dev()
power: supply: charger-manager: fix typo
power/reset: remove zte zx driver
power: supply: bq25980: Fix repetive bq25975 with bq25960
power: supply: smb347-charger: Fix interrupt usage if interrupt is unavailable
power: supply: axp20x_usb_power: Init work before enabling IRQs
power: supply: fix sbs-charger build, needs REGMAP_I2C
power: supply: bq27xxx: fix polarity of current_now
power: supply: charger-manager: fix incorrect health status
power: reset: at91-sama5d2_shdwc: add support for sama7g5
dt-bindings: atmel-sysreg: add microchip,sama7g5-shdwc
power: reset: at91-sama5d2_shdwc: fix wkupdbc mask
dt-bindings: power/supply: Add ltc4162-l-charger
power: supply: bq24190_charger: convert comma to semicolon
power: supply: ab8500_fg: convert comma to semicolon
power: supply: ds2780: Switch to using the new API kobj_to_dev()
power: supply: bq27xxx: Support CHARGE_NOW for bq27z561/bq28z610/bq34z100
power: supply: cpcap-charger: Fix power_supply_put on null battery pointer
power: supply: cpcap-battery: constify psy_desc
power: supply: cpcap-battery: Fix typo
...
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-pxa/mioa701.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-pxa/palm27x.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-pxa/palmte2.c | 1 | ||||
-rw-r--r-- | arch/arm/mach-pxa/z2.c | 12 |
4 files changed, 11 insertions, 4 deletions
diff --git a/arch/arm/mach-pxa/mioa701.c b/arch/arm/mach-pxa/mioa701.c index d3af80317f2d..a79f296e81e0 100644 --- a/arch/arm/mach-pxa/mioa701.c +++ b/arch/arm/mach-pxa/mioa701.c @@ -577,7 +577,6 @@ static struct platform_device power_dev = { static struct wm97xx_batt_pdata mioa701_battery_data = { .batt_aux = WM97XX_AUX_ID1, .temp_aux = -1, - .charge_gpio = -1, .min_voltage = 0xc00, .max_voltage = 0xfc0, .batt_tech = POWER_SUPPLY_TECHNOLOGY_LION, diff --git a/arch/arm/mach-pxa/palm27x.c b/arch/arm/mach-pxa/palm27x.c index 0d246a1aebbc..6230381a7ca0 100644 --- a/arch/arm/mach-pxa/palm27x.c +++ b/arch/arm/mach-pxa/palm27x.c @@ -212,7 +212,6 @@ void __init palm27x_irda_init(int pwdn) static struct wm97xx_batt_pdata palm27x_batt_pdata = { .batt_aux = WM97XX_AUX_ID3, .temp_aux = WM97XX_AUX_ID2, - .charge_gpio = -1, .batt_mult = 1000, .batt_div = 414, .temp_mult = 1, diff --git a/arch/arm/mach-pxa/palmte2.c b/arch/arm/mach-pxa/palmte2.c index e3bcf58b4e63..a2b10db4aacc 100644 --- a/arch/arm/mach-pxa/palmte2.c +++ b/arch/arm/mach-pxa/palmte2.c @@ -273,7 +273,6 @@ static struct platform_device power_supply = { static struct wm97xx_batt_pdata palmte2_batt_pdata = { .batt_aux = WM97XX_AUX_ID3, .temp_aux = WM97XX_AUX_ID2, - .charge_gpio = -1, .max_voltage = PALMTE2_BAT_MAX_VOLTAGE, .min_voltage = PALMTE2_BAT_MIN_VOLTAGE, .batt_mult = 1000, diff --git a/arch/arm/mach-pxa/z2.c b/arch/arm/mach-pxa/z2.c index 89eb5243c85f..8e74fbb0a96e 100644 --- a/arch/arm/mach-pxa/z2.c +++ b/arch/arm/mach-pxa/z2.c @@ -487,7 +487,6 @@ static struct z2_battery_info batt_chip_info = { .batt_I2C_bus = 0, .batt_I2C_addr = 0x55, .batt_I2C_reg = 2, - .charge_gpio = GPIO0_ZIPITZ2_AC_DETECT, .min_voltage = 3475000, .max_voltage = 4190000, .batt_div = 59, @@ -496,9 +495,19 @@ static struct z2_battery_info batt_chip_info = { .batt_name = "Z2", }; +static struct gpiod_lookup_table z2_battery_gpio_table = { + .dev_id = "aer915", + .table = { + GPIO_LOOKUP("gpio-pxa", GPIO0_ZIPITZ2_AC_DETECT, + NULL, GPIO_ACTIVE_HIGH), + { }, + }, +}; + static struct i2c_board_info __initdata z2_i2c_board_info[] = { { I2C_BOARD_INFO("aer915", 0x55), + .dev_name = "aer915", .platform_data = &batt_chip_info, }, { I2C_BOARD_INFO("wm8750", 0x1b), @@ -509,6 +518,7 @@ static struct i2c_board_info __initdata z2_i2c_board_info[] = { static void __init z2_i2c_init(void) { pxa_set_i2c_info(NULL); + gpiod_add_lookup_table(&z2_battery_gpio_table); i2c_register_board_info(0, ARRAY_AND_SIZE(z2_i2c_board_info)); } #else |