linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] power: Fix unmet dependency on POWER_SUPPLY by POWER_RESET by uncoupling them
@ 2015-12-07  3:45 Krzysztof Kozlowski
  2015-12-08 13:39 ` Sebastian Reichel
  0 siblings, 1 reply; 2+ messages in thread
From: Krzysztof Kozlowski @ 2015-12-07  3:45 UTC (permalink / raw)
  To: Sebastian Reichel, Dmitry Eremin-Solenikov, David Woodhouse,
	Greg Kroah-Hartman, linux-kernel, linux-pm
  Cc: p.fedin, linux-samsung-soc, arnd, olof, Krzysztof Kozlowski

Currently the reset/power off handlers (POWER_RESET) and Adaptive Voltage
Scaling class (POWER_AVS) are not built when POWER_SUPPLY is disabled.
The POWER_RESET is also not visible in drivers main section of config.

However they do not really depend on power supply so they can be built
always. The objects for power supply drivers already depend on
particular Kconfig symbols so there is no need for any changes in
drivers/power/Makefile.

This allows selecting POWER_RESET from main drivers config section and
fixes following build warning (encountered on ARM exynos defconfig when
POWER_SUPPLY is disabled manually):

warning: (ARCH_HISI && ARCH_INTEGRATOR && ARCH_EXYNOS && ARCH_VEXPRESS && REALVIEW_DT) selects POWER_RESET which has unmet direct dependencies (POWER_SUPPLY)
warning: (ARCH_EXYNOS) selects POWER_RESET_SYSCON which has unmet direct dependencies (POWER_SUPPLY && POWER_RESET && OF)
warning: (ARCH_EXYNOS) selects POWER_RESET_SYSCON_POWEROFF which has unmet direct dependencies (POWER_SUPPLY && POWER_RESET && OF)

Reported-by: Pavel Fedin <p.fedin@samsung.com>
Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

---

Changes since v1:
1. Follow Sebastian's suggestion of changing drivers/power to obj-y.
   This makes patch 2/2 obsolete and everything (POWER_RESET +
   POWER_AVS) is fixed here.
---
 drivers/Makefile      | 2 +-
 drivers/power/Kconfig | 3 +--
 2 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/Makefile b/drivers/Makefile
index 795d0ca714bf..8f5d076baeb0 100644
--- a/drivers/Makefile
+++ b/drivers/Makefile
@@ -106,7 +106,7 @@ obj-y				+= i2c/ media/
 obj-$(CONFIG_PPS)		+= pps/
 obj-$(CONFIG_PTP_1588_CLOCK)	+= ptp/
 obj-$(CONFIG_W1)		+= w1/
-obj-$(CONFIG_POWER_SUPPLY)	+= power/
+obj-y				+= power/
 obj-$(CONFIG_HWMON)		+= hwmon/
 obj-$(CONFIG_THERMAL)		+= thermal/
 obj-$(CONFIG_WATCHDOG)		+= watchdog/
diff --git a/drivers/power/Kconfig b/drivers/power/Kconfig
index 2f944d742ed4..c031f901b497 100644
--- a/drivers/power/Kconfig
+++ b/drivers/power/Kconfig
@@ -509,8 +509,7 @@ config AXP20X_POWER
 	  This driver provides support for the power supply features of
 	  AXP20x PMIC.
 
-source "drivers/power/reset/Kconfig"
-
 endif # POWER_SUPPLY
 
+source "drivers/power/reset/Kconfig"
 source "drivers/power/avs/Kconfig"
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH v2] power: Fix unmet dependency on POWER_SUPPLY by POWER_RESET by uncoupling them
  2015-12-07  3:45 [PATCH v2] power: Fix unmet dependency on POWER_SUPPLY by POWER_RESET by uncoupling them Krzysztof Kozlowski
@ 2015-12-08 13:39 ` Sebastian Reichel
  0 siblings, 0 replies; 2+ messages in thread
From: Sebastian Reichel @ 2015-12-08 13:39 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Dmitry Eremin-Solenikov, David Woodhouse, Greg Kroah-Hartman,
	linux-kernel, linux-pm, p.fedin, linux-samsung-soc, arnd, olof

[-- Attachment #1: Type: text/plain, Size: 1311 bytes --]

Hi,

On Mon, Dec 07, 2015 at 12:45:12PM +0900, Krzysztof Kozlowski wrote:
> Currently the reset/power off handlers (POWER_RESET) and Adaptive Voltage
> Scaling class (POWER_AVS) are not built when POWER_SUPPLY is disabled.
> The POWER_RESET is also not visible in drivers main section of config.
> 
> However they do not really depend on power supply so they can be built
> always. The objects for power supply drivers already depend on
> particular Kconfig symbols so there is no need for any changes in
> drivers/power/Makefile.
> 
> This allows selecting POWER_RESET from main drivers config section and
> fixes following build warning (encountered on ARM exynos defconfig when
> POWER_SUPPLY is disabled manually):
> 
> warning: (ARCH_HISI && ARCH_INTEGRATOR && ARCH_EXYNOS && ARCH_VEXPRESS && REALVIEW_DT) selects POWER_RESET which has unmet direct dependencies (POWER_SUPPLY)
> warning: (ARCH_EXYNOS) selects POWER_RESET_SYSCON which has unmet direct dependencies (POWER_SUPPLY && POWER_RESET && OF)
> warning: (ARCH_EXYNOS) selects POWER_RESET_SYSCON_POWEROFF which has unmet direct dependencies (POWER_SUPPLY && POWER_RESET && OF)
> 
> Reported-by: Pavel Fedin <p.fedin@samsung.com>
> Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

Thanks, queued.

-- Sebastian

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-12-08 13:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-07  3:45 [PATCH v2] power: Fix unmet dependency on POWER_SUPPLY by POWER_RESET by uncoupling them Krzysztof Kozlowski
2015-12-08 13:39 ` Sebastian Reichel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).