Skip to content

Commit 4c07e2d

Browse files
committed
Merge tag 'mfd-next-5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd
Pull MFD updates from Lee Jones: "New Drivers: - Add support for Merrifield Basin Cove PMIC New Device Support: - Add support for Intel Tiger Lake to Intel LPSS PCI - Add support for Intel Sky Lake to Intel LPSS PCI - Add support for ST-Ericsson DB8520 to DB8500 PRCMU New Functionality: - Add RTC and PWRC support to MT6323 Fix-ups: - Clean-up include files; davinci_voicecodec, asic3, sm501, mt6397 - Ignore return values from debugfs_create*(); ab3100-*, ab8500-debugfs, aat2870-core - Device Tree changes; rn5t618, mt6397 - Use new I2C API; tps80031, 88pm860x-core, ab3100-core, bcm590xx, da9150-core, max14577, max77693, max77843, max8907, max8925-i2c, max8997, max8998, palmas, twl-core, - Remove obsolete code; da9063, jz4740-adc - Simplify semantics; timberdale, htc-i2cpld - Add 'fall-through' tags; omap-usb-host, db8500-prcmu - Remove superfluous prints; ab8500-debugfs, db8500-prcmu, fsl-imx25-tsadc, intel_soc_pmic_bxtwc, qcom_rpm, sm501 - Trivial rename/whitespace/typo fixes; mt6397-core, MAINTAINERS - Reorganise code structure; mt6397-* - Improve code consistency; intel-lpss - Use MODULE_SOFTDEP() helper; intel-lpss - Use DEFINE_RES_*() helpers; mt6397-core Bug Fixes: - Clean-up resources; max77620 - Prevent input events being dropped on resume; intel-lpss-pci - Prevent sleeping in IRQ context; ezx-pcap" * tag 'mfd-next-5.4' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (48 commits) mfd: mt6323: Add MT6323 RTC and PWRC mfd: mt6323: Replace boilerplate resource code with DEFINE_RES_* macros mfd: mt6397: Add mutex include dt-bindings: mfd: mediatek: Add MT6323 Power Controller dt-bindings: mfd: mediatek: Update RTC to include MT6323 dt-bindings: mfd: mediatek: mt6397: Change to relative paths mfd: db8500-prcmu: Support the higher DB8520 ARMSS mfd: intel-lpss: Use MODULE_SOFTDEP() instead of implicit request mfd: htc-i2cpld: Drop check because i2c_unregister_device() is NULL safe mfd: sm501: Include the GPIO driver header mfd: intel-lpss: Add Intel Skylake ACPI IDs mfd: intel-lpss: Consistently use GENMASK() mfd: Add support for Merrifield Basin Cove PMIC mfd: ezx-pcap: Replace mutex_lock with spin_lock mfd: asic3: Include the right header MAINTAINERS: altera-sysmgr: Fix typo in a filepath mfd: mt6397: Extract IRQ related code from core driver mfd: mt6397: Rename macros to something more readable mfd: Remove dev_err() usage after platform_get_irq() mfd: db8500-prcmu: Mark expected switch fall-throughs ...
2 parents d0b3cfe + 8391c6c commit 4c07e2d

45 files changed

Lines changed: 742 additions & 727 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎Documentation/devicetree/bindings/mfd/mt6397.txt‎

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,12 @@ MT6397/MT6323 is a multifunction device with the following sub modules:
88
- Clock
99
- LED
1010
- Keys
11+
- Power controller
1112

1213
It is interfaced to host controller using SPI interface by a proprietary hardware
1314
called PMIC wrapper or pwrap. MT6397/MT6323 MFD is a child device of pwrap.
1415
See the following for pwarp node definitions:
15-
Documentation/devicetree/bindings/soc/mediatek/pwrap.txt
16+
../soc/mediatek/pwrap.txt
1617

1718
This document describes the binding for MFD device and its sub module.
1819

@@ -22,14 +23,16 @@ compatible: "mediatek,mt6397" or "mediatek,mt6323"
2223
Optional subnodes:
2324

2425
- rtc
25-
Required properties:
26+
Required properties: Should be one of follows
27+
- compatible: "mediatek,mt6323-rtc"
2628
- compatible: "mediatek,mt6397-rtc"
29+
For details, see ../rtc/rtc-mt6397.txt
2730
- regulators
2831
Required properties:
2932
- compatible: "mediatek,mt6397-regulator"
30-
see Documentation/devicetree/bindings/regulator/mt6397-regulator.txt
33+
see ../regulator/mt6397-regulator.txt
3134
- compatible: "mediatek,mt6323-regulator"
32-
see Documentation/devicetree/bindings/regulator/mt6323-regulator.txt
35+
see ../regulator/mt6323-regulator.txt
3336
- codec
3437
Required properties:
3538
- compatible: "mediatek,mt6397-codec"
@@ -39,12 +42,17 @@ Optional subnodes:
3942
- led
4043
Required properties:
4144
- compatible: "mediatek,mt6323-led"
42-
see Documentation/devicetree/bindings/leds/leds-mt6323.txt
45+
see ../leds/leds-mt6323.txt
4346

4447
- keys
4548
Required properties:
4649
- compatible: "mediatek,mt6397-keys" or "mediatek,mt6323-keys"
47-
see Documentation/devicetree/bindings/input/mtk-pmic-keys.txt
50+
see ../input/mtk-pmic-keys.txt
51+
52+
- power-controller
53+
Required properties:
54+
- compatible: "mediatek,mt6323-pwrc"
55+
For details, see ../power/reset/mt6323-poweroff.txt
4856

4957
Example:
5058
pwrap: pwrap@1000f000 {

‎Documentation/devicetree/bindings/mfd/rn5t618.txt‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ Required properties:
1414
"ricoh,rc5t619"
1515
- reg: the I2C slave address of the device
1616

17+
Optional properties:
18+
- system-power-controller:
19+
See Documentation/devicetree/bindings/power/power-controller.txt
20+
1721
Sub-nodes:
1822
- regulators: the node is required if the regulator functionality is
1923
needed. The valid regulator names are: DCDC1, DCDC2, DCDC3, DCDC4
@@ -28,6 +32,7 @@ Example:
2832
pmic@32 {
2933
compatible = "ricoh,rn5t618";
3034
reg = <0x32>;
35+
system-power-controller;
3136

3237
regulators {
3338
DCDC1 {
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
Device Tree Bindings for Power Controller on MediaTek PMIC
2+
3+
The power controller which could be found on PMIC is responsible for externally
4+
powering off or on the remote MediaTek SoC through the circuit BBPU.
5+
6+
Required properties:
7+
- compatible: Should be one of follows
8+
"mediatek,mt6323-pwrc": for MT6323 PMIC
9+
10+
Example:
11+
12+
pmic {
13+
compatible = "mediatek,mt6323";
14+
15+
...
16+
17+
power-controller {
18+
compatible = "mediatek,mt6323-pwrc";
19+
};
20+
}

‎MAINTAINERS‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,7 @@ ALTERA SYSTEM MANAGER DRIVER
728728
M: Thor Thayer <thor.thayer@linux.intel.com>
729729
S: Maintained
730730
F: drivers/mfd/altera-sysmgr.c
731-
F: include/linux/mfd/altera-sysgmr.h
731+
F: include/linux/mfd/altera-sysmgr.h
732732

733733
ALTERA SYSTEM RESOURCE DRIVER FOR ARRIA10 DEVKIT
734734
M: Thor Thayer <thor.thayer@linux.intel.com>

‎drivers/mfd/88pm800.c‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -425,10 +425,10 @@ static int pm800_pages_init(struct pm80x_chip *chip)
425425
return -ENODEV;
426426

427427
/* PM800 block power page */
428-
subchip->power_page = i2c_new_dummy(client->adapter,
428+
subchip->power_page = i2c_new_dummy_device(client->adapter,
429429
subchip->power_page_addr);
430-
if (subchip->power_page == NULL) {
431-
ret = -ENODEV;
430+
if (IS_ERR(subchip->power_page)) {
431+
ret = PTR_ERR(subchip->power_page);
432432
goto out;
433433
}
434434

@@ -444,10 +444,10 @@ static int pm800_pages_init(struct pm80x_chip *chip)
444444
i2c_set_clientdata(subchip->power_page, chip);
445445

446446
/* PM800 block GPADC */
447-
subchip->gpadc_page = i2c_new_dummy(client->adapter,
447+
subchip->gpadc_page = i2c_new_dummy_device(client->adapter,
448448
subchip->gpadc_page_addr);
449-
if (subchip->gpadc_page == NULL) {
450-
ret = -ENODEV;
449+
if (IS_ERR(subchip->gpadc_page)) {
450+
ret = PTR_ERR(subchip->gpadc_page);
451451
goto out;
452452
}
453453

‎drivers/mfd/88pm860x-core.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1178,12 +1178,12 @@ static int pm860x_probe(struct i2c_client *client)
11781178
*/
11791179
if (pdata->companion_addr && (pdata->companion_addr != client->addr)) {
11801180
chip->companion_addr = pdata->companion_addr;
1181-
chip->companion = i2c_new_dummy(chip->client->adapter,
1181+
chip->companion = i2c_new_dummy_device(chip->client->adapter,
11821182
chip->companion_addr);
1183-
if (!chip->companion) {
1183+
if (IS_ERR(chip->companion)) {
11841184
dev_err(&client->dev,
11851185
"Failed to allocate I2C companion device\n");
1186-
return -ENODEV;
1186+
return PTR_ERR(chip->companion);
11871187
}
11881188
chip->regmap_companion = regmap_init_i2c(chip->companion,
11891189
&pm860x_regmap_config);

‎drivers/mfd/Kconfig‎

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -589,6 +589,17 @@ config INTEL_SOC_PMIC_CHTDC_TI
589589
Select this option for supporting Dollar Cove (TI version) PMIC
590590
device that is found on some Intel Cherry Trail systems.
591591

592+
config INTEL_SOC_PMIC_MRFLD
593+
tristate "Support for Intel Merrifield Basin Cove PMIC"
594+
depends on GPIOLIB
595+
depends on ACPI
596+
depends on INTEL_SCU_IPC
597+
select MFD_CORE
598+
select REGMAP_IRQ
599+
help
600+
Select this option for supporting Basin Cove PMIC device
601+
that is found on Intel Merrifield systems.
602+
592603
config MFD_INTEL_LPSS
593604
tristate
594605
select COMMON_CLK
@@ -641,15 +652,6 @@ config MFD_JANZ_CMODIO
641652
host many different types of MODULbus daughterboards, including
642653
CAN and GPIO controllers.
643654

644-
config MFD_JZ4740_ADC
645-
bool "Janz JZ4740 ADC core"
646-
select MFD_CORE
647-
select GENERIC_IRQ_CHIP
648-
depends on MACH_JZ4740
649-
help
650-
Say yes here if you want support for the ADC unit in the JZ4740 SoC.
651-
This driver is necessary for jz4740-battery and jz4740-hwmon driver.
652-
653655
config MFD_KEMPLD
654656
tristate "Kontron module PLD device"
655657
select MFD_CORE

‎drivers/mfd/Makefile‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,6 @@ obj-$(CONFIG_LPC_SCH) += lpc_sch.o
189189
obj-$(CONFIG_LPC_ICH) += lpc_ich.o
190190
obj-$(CONFIG_MFD_RDC321X) += rdc321x-southbridge.o
191191
obj-$(CONFIG_MFD_JANZ_CMODIO) += janz-cmodio.o
192-
obj-$(CONFIG_MFD_JZ4740_ADC) += jz4740-adc.o
193192
obj-$(CONFIG_MFD_TPS6586X) += tps6586x.o
194193
obj-$(CONFIG_MFD_VX855) += vx855.o
195194
obj-$(CONFIG_MFD_WL1273_CORE) += wl1273-core.o
@@ -239,7 +238,9 @@ obj-$(CONFIG_INTEL_SOC_PMIC) += intel-soc-pmic.o
239238
obj-$(CONFIG_INTEL_SOC_PMIC_BXTWC) += intel_soc_pmic_bxtwc.o
240239
obj-$(CONFIG_INTEL_SOC_PMIC_CHTWC) += intel_soc_pmic_chtwc.o
241240
obj-$(CONFIG_INTEL_SOC_PMIC_CHTDC_TI) += intel_soc_pmic_chtdc_ti.o
242-
obj-$(CONFIG_MFD_MT6397) += mt6397-core.o
241+
mt6397-objs := mt6397-core.o mt6397-irq.o
242+
obj-$(CONFIG_MFD_MT6397) += mt6397.o
243+
obj-$(CONFIG_INTEL_SOC_PMIC_MRFLD) += intel_soc_pmic_mrfld.o
243244

244245
obj-$(CONFIG_MFD_ALTERA_A10SR) += altera-a10sr.o
245246
obj-$(CONFIG_MFD_ALTERA_SYSMGR) += altera-sysmgr.o

‎drivers/mfd/ab3100-core.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -865,10 +865,10 @@ static int ab3100_probe(struct i2c_client *client,
865865
&ab3100->chip_name[0]);
866866

867867
/* Attach a second dummy i2c_client to the test register address */
868-
ab3100->testreg_client = i2c_new_dummy(client->adapter,
868+
ab3100->testreg_client = i2c_new_dummy_device(client->adapter,
869869
client->addr + 1);
870-
if (!ab3100->testreg_client) {
871-
err = -ENOMEM;
870+
if (IS_ERR(ab3100->testreg_client)) {
871+
err = PTR_ERR(ab3100->testreg_client);
872872
goto exit_no_testreg_client;
873873
}
874874

‎drivers/mfd/ab8500-debugfs.c‎

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2680,16 +2680,12 @@ static int ab8500_debug_probe(struct platform_device *plf)
26802680
irq_ab8500 = res->start;
26812681

26822682
irq_first = platform_get_irq_byname(plf, "IRQ_FIRST");
2683-
if (irq_first < 0) {
2684-
dev_err(&plf->dev, "First irq not found, err %d\n", irq_first);
2683+
if (irq_first < 0)
26852684
return irq_first;
2686-
}
26872685

26882686
irq_last = platform_get_irq_byname(plf, "IRQ_LAST");
2689-
if (irq_last < 0) {
2690-
dev_err(&plf->dev, "Last irq not found, err %d\n", irq_last);
2687+
if (irq_last < 0)
26912688
return irq_last;
2692-
}
26932689

26942690
ab8500_dir = debugfs_create_dir(AB8500_NAME_STRING, NULL);
26952691

0 commit comments

Comments
 (0)