Skip to content

Commit 96836a3

Browse files
jdelvarelag-linaro
authored andcommitted
mfd: Drop obsolete dependencies on COMPILE_TEST
Since commit 0166dc1 ("of: make CONFIG_OF user selectable"), it is possible to test-build any driver which depends on OF on any architecture by explicitly selecting OF. Therefore depending on COMPILE_TEST as an alternative is no longer needed. It is actually better to always build such drivers with OF enabled, so that the test builds are closer to how each driver will actually be built on its intended target. Building them without OF may not test much as the compiler will optimize out potentially large parts of the code. In the worst case, this could even pop false positive warnings. Dropping COMPILE_TEST here improves the quality of our testing and avoids wasting time on non-existent issues. As a minor optimization, this also lets us drop of_match_ptr(), as we now know what it will resolve to, we might as well save cpp some work. Signed-off-by: Jean Delvare <[email protected]> Cc: Lee Jones <[email protected]> Cc: Bartosz Golaszewski <[email protected]> Cc: Chanwoo Choi <[email protected]> Cc: Krzysztof Kozlowski <[email protected]> Cc: Bartlomiej Zolnierkiewicz <[email protected]> Cc: Luca Ceresoli <[email protected]> Cc: "Jonathan Neuschäfer" <[email protected]> Signed-off-by: Lee Jones <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent 7ef5c57 commit 96836a3

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

drivers/mfd/Kconfig

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -797,7 +797,7 @@ config MFD_MAX14577
797797
config MFD_MAX77620
798798
bool "Maxim Semiconductor MAX77620 and MAX20024 PMIC Support"
799799
depends on I2C=y
800-
depends on OF || COMPILE_TEST
800+
depends on OF
801801
select MFD_CORE
802802
select REGMAP_I2C
803803
select REGMAP_IRQ
@@ -812,7 +812,7 @@ config MFD_MAX77620
812812
config MFD_MAX77650
813813
tristate "Maxim MAX77650/77651 PMIC Support"
814814
depends on I2C
815-
depends on OF || COMPILE_TEST
815+
depends on OF
816816
select MFD_CORE
817817
select REGMAP_I2C
818818
select REGMAP_IRQ
@@ -827,7 +827,7 @@ config MFD_MAX77650
827827
config MFD_MAX77686
828828
tristate "Maxim Semiconductor MAX77686/802 PMIC Support"
829829
depends on I2C
830-
depends on OF || COMPILE_TEST
830+
depends on OF
831831
select MFD_CORE
832832
select REGMAP_I2C
833833
select REGMAP_IRQ
@@ -856,7 +856,7 @@ config MFD_MAX77693
856856
config MFD_MAX77714
857857
tristate "Maxim Semiconductor MAX77714 PMIC Support"
858858
depends on I2C
859-
depends on OF || COMPILE_TEST
859+
depends on OF
860860
select MFD_CORE
861861
select REGMAP_I2C
862862
help
@@ -1013,7 +1013,7 @@ config EZX_PCAP
10131013
config MFD_CPCAP
10141014
tristate "Support for Motorola CPCAP"
10151015
depends on SPI
1016-
depends on OF || COMPILE_TEST
1016+
depends on OF
10171017
select MFD_CORE
10181018
select REGMAP_SPI
10191019
select REGMAP_IRQ
@@ -1038,7 +1038,7 @@ config MFD_VIPERBOARD
10381038

10391039
config MFD_NTXEC
10401040
tristate "Netronix embedded controller (EC)"
1041-
depends on OF || COMPILE_TEST
1041+
depends on OF
10421042
depends on I2C
10431043
select REGMAP_I2C
10441044
select MFD_CORE
@@ -1234,7 +1234,7 @@ config MFD_RN5T618
12341234
config MFD_SEC_CORE
12351235
tristate "Samsung Electronics PMIC Series Support"
12361236
depends on I2C=y
1237-
depends on OF || COMPILE_TEST
1237+
depends on OF
12381238
select MFD_CORE
12391239
select REGMAP_I2C
12401240
select REGMAP_IRQ
@@ -2082,7 +2082,7 @@ config MFD_STPMIC1
20822082
config MFD_STMFX
20832083
tristate "Support for STMicroelectronics Multi-Function eXpander (STMFX)"
20842084
depends on I2C
2085-
depends on OF || COMPILE_TEST
2085+
depends on OF
20862086
select MFD_CORE
20872087
select REGMAP_I2C
20882088
help

drivers/mfd/motorola-cpcap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ static int cpcap_probe(struct spi_device *spi)
294294
struct cpcap_ddata *cpcap;
295295
int ret;
296296

297-
match = of_match_device(of_match_ptr(cpcap_of_match), &spi->dev);
297+
match = of_match_device(cpcap_of_match, &spi->dev);
298298
if (!match)
299299
return -ENODEV;
300300

0 commit comments

Comments
 (0)