2016-10-02 20:58:35

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH 0/4] clk/mfd/regulator/rtc: Enable compile testing for some Maxim/Samsung drivers

Hi,

Some of the Maxim and Samsung PMIC/MUIC drivers can be safely
compile tested to increase build-test coverage.

Rebased on next-20160930.
Patches do not depend on each-other, please pick up as you wish.

I compile-tested it on ~10 architectures, but not on all of possibilities.
Please wait few days before applying so the 0-day robots could parse
it and find possible non-compilable issues.

Best regards,
Krzysztof


Krzysztof Kozlowski (4):
clk: Enable compile testing for s2mps11 and max77686
regulator: Enable compile testing for Maxim and Samsung PMIC drivers
rtc: Enable compile testing for Maxim and Samsung drivers
mfd: Enable compile testing for max77620 and max77686

drivers/clk/Kconfig | 4 ++--
drivers/mfd/Kconfig | 4 ++--
drivers/regulator/Kconfig | 14 +++++++-------
drivers/rtc/Kconfig | 7 ++++---
4 files changed, 15 insertions(+), 14 deletions(-)

--
2.7.4


2016-10-02 20:58:51

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH 3/4] rtc: Enable compile testing for Maxim and Samsung drivers

max8907, max77686 and s5m RTC drivers can be compile tested to increase
build coverage. The s5m-rtc uses REGMAP_IRQ so add this as explicit
dependency.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
drivers/rtc/Kconfig | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/rtc/Kconfig b/drivers/rtc/Kconfig
index e859d148aba9..988053664125 100644
--- a/drivers/rtc/Kconfig
+++ b/drivers/rtc/Kconfig
@@ -303,7 +303,7 @@ config RTC_DRV_MAX6900

config RTC_DRV_MAX8907
tristate "Maxim MAX8907"
- depends on MFD_MAX8907
+ depends on MFD_MAX8907 || COMPILE_TEST
help
If you say yes here you will get support for the
RTC of Maxim MAX8907 PMIC.
@@ -343,7 +343,7 @@ config RTC_DRV_MAX8997

config RTC_DRV_MAX77686
tristate "Maxim MAX77686"
- depends on MFD_MAX77686 || MFD_MAX77620
+ depends on MFD_MAX77686 || MFD_MAX77620 || COMPILE_TEST
help
If you say yes here you will get support for the
RTC of Maxim MAX77686/MAX77620/MAX77802 PMIC.
@@ -602,7 +602,8 @@ config RTC_DRV_RV8803

config RTC_DRV_S5M
tristate "Samsung S2M/S5M series"
- depends on MFD_SEC_CORE
+ depends on MFD_SEC_CORE || COMPILE_TEST
+ select REGMAP_IRQ
help
If you say yes here you will get support for the
RTC of Samsung S2MPS14 and S5M PMIC series.
--
2.7.4

2016-10-02 20:58:47

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH 1/4] clk: Enable compile testing for s2mps11 and max77686

s2mps11 and max77686 clock drivers can be compile tested to increase
build coverage.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
drivers/clk/Kconfig | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/Kconfig b/drivers/clk/Kconfig
index 6a8ac04bedeb..56c1998ced3e 100644
--- a/drivers/clk/Kconfig
+++ b/drivers/clk/Kconfig
@@ -33,7 +33,7 @@ source "drivers/clk/versatile/Kconfig"

config COMMON_CLK_MAX77686
tristate "Clock driver for Maxim 77620/77686/77802 MFD"
- depends on MFD_MAX77686 || MFD_MAX77620
+ depends on MFD_MAX77686 || MFD_MAX77620 || COMPILE_TEST
---help---
This driver supports Maxim 77620/77686/77802 crystal oscillator
clock.
@@ -119,7 +119,7 @@ config COMMON_CLK_CS2000_CP

config COMMON_CLK_S2MPS11
tristate "Clock driver for S2MPS1X/S5M8767 MFD"
- depends on MFD_SEC_CORE
+ depends on MFD_SEC_CORE || COMPILE_TEST
---help---
This driver supports S2MPS11/S2MPS14/S5M8767 crystal oscillator
clock. These multi-function devices have two (S2MPS14) or three
--
2.7.4

2016-10-02 20:58:49

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH 2/4] regulator: Enable compile testing for Maxim and Samsung PMIC drivers

Most of Maxim and Samsung PMIC/MUIC regulator drivers can be compile
tested to increase build coverage.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
drivers/regulator/Kconfig | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/drivers/regulator/Kconfig b/drivers/regulator/Kconfig
index 936f7ccc9736..1ce7e3633b63 100644
--- a/drivers/regulator/Kconfig
+++ b/drivers/regulator/Kconfig
@@ -379,7 +379,7 @@ config REGULATOR_MAX1586

config REGULATOR_MAX77620
tristate "Maxim 77620/MAX20024 voltage regulator"
- depends on MFD_MAX77620
+ depends on MFD_MAX77620 || COMPILE_TEST
help
This driver controls Maxim MAX77620 voltage output regulator
via I2C bus. The provided regulator is suitable for Tegra
@@ -453,7 +453,7 @@ config REGULATOR_MAX8998

config REGULATOR_MAX77686
tristate "Maxim 77686 regulator"
- depends on MFD_MAX77686
+ depends on MFD_MAX77686 || COMPILE_TEST
help
This driver controls a Maxim 77686 regulator
via I2C bus. The provided regulator is suitable for
@@ -461,7 +461,7 @@ config REGULATOR_MAX77686

config REGULATOR_MAX77693
tristate "Maxim 77693/77843 regulator"
- depends on (MFD_MAX77693 || MFD_MAX77843)
+ depends on MFD_MAX77693 || MFD_MAX77843 || COMPILE_TEST
help
This driver controls a Maxim 77693/77843 regulators via I2C bus.
The regulators include two LDOs, 'SAFEOUT1', 'SAFEOUT2'
@@ -470,7 +470,7 @@ config REGULATOR_MAX77693

config REGULATOR_MAX77802
tristate "Maxim 77802 regulator"
- depends on MFD_MAX77686
+ depends on MFD_MAX77686 || COMPILE_TEST
help
This driver controls a Maxim 77802 regulator
via I2C bus. The provided regulator is suitable for
@@ -669,14 +669,14 @@ config REGULATOR_RT5033

config REGULATOR_S2MPA01
tristate "Samsung S2MPA01 voltage regulator"
- depends on MFD_SEC_CORE
+ depends on MFD_SEC_CORE || COMPILE_TEST
help
This driver controls Samsung S2MPA01 voltage output regulator
via I2C bus. S2MPA01 has 10 Bucks and 26 LDO outputs.

config REGULATOR_S2MPS11
tristate "Samsung S2MPS11/13/14/15/S2MPU02 voltage regulator"
- depends on MFD_SEC_CORE
+ depends on MFD_SEC_CORE || COMPILE_TEST
help
This driver supports a Samsung S2MPS11/13/14/15/S2MPU02 voltage
output regulator via I2C bus. The chip is comprised of high efficient
@@ -685,7 +685,7 @@ config REGULATOR_S2MPS11

config REGULATOR_S5M8767
tristate "Samsung S5M8767A voltage regulator"
- depends on MFD_SEC_CORE
+ depends on MFD_SEC_CORE || COMPILE_TEST
help
This driver supports a Samsung S5M8767A voltage output regulator
via I2C bus. S5M8767A have 9 Bucks and 28 LDOs output and
--
2.7.4

2016-10-02 20:59:22

by Krzysztof Kozlowski

[permalink] [raw]
Subject: [PATCH 4/4] mfd: Enable compile testing for max77620 and max77686

The OF is not a strict build-time dependency so max77620 and max77686
can be compile tested to increase build coverage.

Signed-off-by: Krzysztof Kozlowski <[email protected]>
---
drivers/mfd/Kconfig | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
index c6df6442ba2b..ccea26943746 100644
--- a/drivers/mfd/Kconfig
+++ b/drivers/mfd/Kconfig
@@ -563,7 +563,7 @@ config MFD_MAX14577
config MFD_MAX77620
bool "Maxim Semiconductor MAX77620 and MAX20024 PMIC Support"
depends on I2C=y
- depends on OF
+ depends on OF || COMPILE_TEST
select MFD_CORE
select REGMAP_I2C
select REGMAP_IRQ
@@ -578,7 +578,7 @@ config MFD_MAX77620
config MFD_MAX77686
tristate "Maxim Semiconductor MAX77686/802 PMIC Support"
depends on I2C
- depends on OF
+ depends on OF || COMPILE_TEST
select MFD_CORE
select REGMAP_I2C
select REGMAP_IRQ
--
2.7.4

2016-10-04 02:41:27

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH 2/4] regulator: Enable compile testing for Maxim and Samsung PMIC drivers

On Sun, Oct 02, 2016 at 10:58:15PM +0200, Krzysztof Kozlowski wrote:
> Most of Maxim and Samsung PMIC/MUIC regulator drivers can be compile
> tested to increase build coverage.

All these drivers already just depend on the MFDs which don't have any
weird architecture dependencies - the main goal with COMPILE_TEST is
usually to eliminate dependencies which just can't be selected so they
can be built at all. Given that there's no easy way to select
everything in a subsystem otherwise does this buy us a lot?


Attachments:
(No filename) (512.00 B)
signature.asc (455.00 B)
Download all attachments

2016-10-04 09:31:03

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 2/4] regulator: Enable compile testing for Maxim and Samsung PMIC drivers

On Tue, Oct 04, 2016 at 04:40:55AM +0200, Mark Brown wrote:
> On Sun, Oct 02, 2016 at 10:58:15PM +0200, Krzysztof Kozlowski wrote:
> > Most of Maxim and Samsung PMIC/MUIC regulator drivers can be compile
> > tested to increase build coverage.
>
> All these drivers already just depend on the MFDs which don't have any
> weird architecture dependencies - the main goal with COMPILE_TEST is
> usually to eliminate dependencies which just can't be selected so they
> can be built at all. Given that there's no easy way to select
> everything in a subsystem otherwise does this buy us a lot?

Initially I thought similar - if parent MFD driver can be
compile-tested, then these children do not need that flag...

However the MFD drivers depend on I2C which (currently) cannot be
removed for compile testing. On the other hand, regulator drivers do not
need that dependency so you can compile-test them with I2C=n. That is
the main benefit. If you wish, I can add this information to the commit
msg.

Best regards,
Krzysztof

2016-10-26 12:16:35

by Lee Jones

[permalink] [raw]
Subject: Re: [PATCH 4/4] mfd: Enable compile testing for max77620 and max77686

On Sun, 02 Oct 2016, Krzysztof Kozlowski wrote:

> The OF is not a strict build-time dependency so max77620 and max77686
> can be compile tested to increase build coverage.
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> ---
> drivers/mfd/Kconfig | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)

Applied, thanks.

> diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
> index c6df6442ba2b..ccea26943746 100644
> --- a/drivers/mfd/Kconfig
> +++ b/drivers/mfd/Kconfig
> @@ -563,7 +563,7 @@ config MFD_MAX14577
> config MFD_MAX77620
> bool "Maxim Semiconductor MAX77620 and MAX20024 PMIC Support"
> depends on I2C=y
> - depends on OF
> + depends on OF || COMPILE_TEST
> select MFD_CORE
> select REGMAP_I2C
> select REGMAP_IRQ
> @@ -578,7 +578,7 @@ config MFD_MAX77620
> config MFD_MAX77686
> tristate "Maxim Semiconductor MAX77686/802 PMIC Support"
> depends on I2C
> - depends on OF
> + depends on OF || COMPILE_TEST
> select MFD_CORE
> select REGMAP_I2C
> select REGMAP_IRQ

--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

2016-11-02 00:33:22

by Stephen Boyd

[permalink] [raw]
Subject: Re: [PATCH 1/4] clk: Enable compile testing for s2mps11 and max77686

On 10/02, Krzysztof Kozlowski wrote:
> s2mps11 and max77686 clock drivers can be compile tested to increase
> build coverage.
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> ---

Applied to clk-next

--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

2016-11-04 23:12:26

by Alexandre Belloni

[permalink] [raw]
Subject: Re: [PATCH 3/4] rtc: Enable compile testing for Maxim and Samsung drivers

On 02/10/2016 at 22:58:16 +0200, Krzysztof Kozlowski wrote :
> max8907, max77686 and s5m RTC drivers can be compile tested to increase
> build coverage. The s5m-rtc uses REGMAP_IRQ so add this as explicit
> dependency.
>
> Signed-off-by: Krzysztof Kozlowski <[email protected]>
> ---
> drivers/rtc/Kconfig | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
Applied, thanks.

--
Alexandre Belloni, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com