USB: USB_OTG does not depend on PM
PATCH 1/1 USB: USB_OTG does not depend on PM
USB_OTG initially depended on USB_SUSPEND, which was later turned into PM_RUNTIME and finally into PM. I don't know at what point the dependency became unnecessary but it appears to work fine without CONFIG_PM now.
However, we get lots of warnings in randconfig kernels like:
warning: (USB_OTG_FSM && FSL_USB2_OTG && USB_MV_OTG) selects USB_OTG which has unmet direct dependencies (USB_SUPPORT && USB && PM)
whenever CONFIG_PM is disabled and something else selects USB_OTG. Let's just drop the dependency to avoid the warnings.
---
I keep seeing this one in my ARM randconfig test
drivers/usb/core/Kconfig +0 -1
@@ -43,7 +43,6 @@ config USB_DYNAMIC_MINORS config USB_OTG bool "OTG support" - depends on PM default n help The most notable feature of USB OTG is support for a
Hi,
Quoted 6 lines · Arnd Bergmann
USB_OTGinitially depended onUSB_SUSPEND, which was later turned intoPM_RUNTIMEand finally into PM. I don't know at what point the dependency became unnecessary but it appears to work fine withoutCONFIG_PMnow.However, we get lots of warnings in randconfig kernels like:
Quoted 8 lines
warning: (
USB_OTG_FSM&&FSL_USB2_OTG&&USB_MV_OTG) selectsUSB_OTGwhich has unmet direct dependencies (USB_SUPPORT&& USB && PM)whenever
CONFIG_PMis disabled and something else selectsUSB_OTG. Let's just drop the dependency to avoid the warnings.Signed-off-by Arnd Bergmann <[email protected]>---
I keep seeing this one in my ARM randconfig test
and how did you test this ? Did you make sure you're not breaking HNP ? For HNP to happen we depend on a bus_suspend and bus_suspend is only available on CONFIG_PM, unless that has changed.
Seems like you've only compile tested this patch, is that correct ?
Signature · 8 lines
balbi -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 818 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20151117/f383883d/attachment.sig>
Quoted 17 lines · On Tuesday 17 November 2015 15:38:33 Felipe Balbi wrote:
Quoted 6 lines · Arnd Bergmann
USB_OTGinitially depended onUSB_SUSPEND, which was later turned intoPM_RUNTIMEand finally into PM. I don't know at what point the dependency became unnecessary but it appears to work fine withoutCONFIG_PMnow.However, we get lots of warnings in randconfig kernels like:
Quoted 8 lines
warning: (
USB_OTG_FSM&&FSL_USB2_OTG&&USB_MV_OTG) selectsUSB_OTGwhich has unmet direct dependencies (USB_SUPPORT&& USB && PM)whenever
CONFIG_PMis disabled and something else selectsUSB_OTG. Let's just drop the dependency to avoid the warnings.Signed-off-by Arnd Bergmann <[email protected]>---
I keep seeing this one in my ARM randconfig test
Quoted 5 lines
and how did you test this ? Did you make sure you're not breaking HNP ? For HNP to happen we depend on a
bus_suspendandbus_suspendis only available onCONFIG_PM, unless that has changed.Seems like you've only compile tested this patch, is that correct ?
Yes, I compile-tested only and inspected the code briefly without finding anything that contradicted this. It seems I missed the important part as you say, so we should instead add 'depends on PM' for the other symbols.
Arnd
Hi,
Quoted 22 lines · Arnd Bergmann
Quoted 21 lines · On Tuesday 17 November 2015 15:38:33 Felipe Balbi wrote:
Quoted 6 lines · Arnd Bergmann
USB_OTGinitially depended onUSB_SUSPEND, which was later turned intoPM_RUNTIMEand finally into PM. I don't know at what point the dependency became unnecessary but it appears to work fine withoutCONFIG_PMnow.However, we get lots of warnings in randconfig kernels like:
Quoted 8 lines
warning: (
USB_OTG_FSM&&FSL_USB2_OTG&&USB_MV_OTG) selectsUSB_OTGwhich has unmet direct dependencies (USB_SUPPORT&& USB && PM)whenever
CONFIG_PMis disabled and something else selectsUSB_OTG. Let's just drop the dependency to avoid the warnings.Signed-off-by Arnd Bergmann <[email protected]>---
I keep seeing this one in my ARM randconfig testand how did you test this ? Did you make sure you're not breaking HNP ? For HNP to happen we depend on a
bus_suspendandbus_suspendis only available onCONFIG_PM, unless that has changed.
Quoted 6 lines
Quoted 1 line
Seems like you've only compile tested this patch, is that correct ?
Yes, I compile-tested only and inspected the code briefly without finding anything that contradicted this. It seems I missed the important part as you say, so we should instead add 'depends on PM' for the other symbols.
right, that might be better. I'll still read that code again, it has been a few years since I looked at hnp at all.
Signature · 8 lines
balbi -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 818 bytes Desc: not available URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20151117/df06115e/attachment.sig>
Quoted 22 lines · Arnd Bergmann
Quoted 21 lines · On Tuesday 17 November 2015 15:38:33 Felipe Balbi wrote:
Quoted 6 lines · Arnd Bergmann
USB_OTGinitially depended onUSB_SUSPEND, which was later turned intoPM_RUNTIMEand finally into PM. I don't know at what point the dependency became unnecessary but it appears to work fine withoutCONFIG_PMnow.However, we get lots of warnings in randconfig kernels like:
Quoted 8 lines
warning: (
USB_OTG_FSM&&FSL_USB2_OTG&&USB_MV_OTG) selectsUSB_OTGwhich has unmet direct dependencies (USB_SUPPORT&& USB && PM)whenever
CONFIG_PMis disabled and something else selectsUSB_OTG. Let's just drop the dependency to avoid the warnings.Signed-off-by Arnd Bergmann <[email protected]>---
I keep seeing this one in my ARM randconfig testand how did you test this ? Did you make sure you're not breaking HNP ? For HNP to happen we depend on a
bus_suspendandbus_suspendis only available onCONFIG_PM, unless that has changed.
Quoted 8 lines
Quoted 1 line
Seems like you've only compile tested this patch, is that correct ?
Yes, I compile-tested only and inspected the code briefly without finding anything that contradicted this. It seems I missed the important part as you say, so we should instead add 'depends on PM' for the other symbols.
Arnd
Hi Arnd, would you kindly try if below patch can fix your problem
Quoted 1 line
From
3a6918dae038aadc200dcf0263f4440acc2353d4Mon Sep 17 00:00:00 2001
From: Peter Chen <[email protected]>
Date: Wed, 18 Nov 2015 11:06:34 +0800
Subject: [PATCH 1/1] usb: kconfig: fix warning of select USB_OTG
When choose randconfig for kernel build, it reports below warning:
"warning: (USB_OTG_FSM && FSL_USB2_OTG && USB_MV_OTG) selects USB_OTG which has unmet direct dependencies (USB_SUPPORT && USB && PM)"
In fact, USB_OTG is visual symbol and depends on PM, so the driver needs to depend on it to reduce dependency problem.
--- drivers/usb/core/Kconfig | 3 +-- drivers/usb/phy/Kconfig | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-)
drivers/usb/core/Kconfig +1 -2
@@ -77,8 +77,7 @@ config USB_OTG_BLACKLIST_HUB config USB_OTG_FSM tristate "USB 2.0 OTG FSM implementation" - depends on USB - select USB_OTG + depends on USB && USB_OTG select USB_PHY help Implements OTG Finite State Machine as specified in On-The-Go
drivers/usb/phy/Kconfig +1 -3
@@ -21,7 +21,6 @@ config AB8500_USB config FSL_USB2_OTG bool "Freescale USB OTG Transceiver Driver" depends on USB_EHCI_FSL && USB_FSL_USB2 && USB_OTG_FSM && PM - select USB_OTG select USB_PHY help Enable this to support Freescale USB OTG transceiver.
@@ -168,8 +167,7 @@ config USB_QCOM_8X16_PHY config USB_MV_OTG tristate "Marvell USB OTG support" - depends on USB_EHCI_MV && USB_MV_UDC && PM - select USB_OTG + depends on USB_EHCI_MV && USB_MV_UDC && PM && USB_OTG select USB_PHY help Say Y here if you want to build Marvell USB OTG transciever
Signature · 6 lines
1.9.1 -- Best Regards, Peter Chen
Arnd Bergmann
Acked-byQuoted 10 lines · On Wednesday 18 November 2015 11:17:50 Peter Chen wrote:
From
3a6918dae038aadc200dcf0263f4440acc2353d4Mon Sep 17 00:00:00 2001
From: Peter Chen <[email protected]>
Date: Wed, 18 Nov 2015 11:06:34 +0800
Subject: [PATCH 1/1] usb: kconfig: fix warning of selectUSB_OTGWhen choose randconfig for kernel build, it reports below warning:
"warning: (USB_OTG_FSM&&FSL_USB2_OTG&&USB_MV_OTG) selectsUSB_OTGwhich has unmet direct dependencies (USB_SUPPORT&& USB && PM)"In fact,
USB_OTGis visual symbol and depends on PM, so the driver
visible ?
Quoted 5 lines
needs to depend on it to reduce dependency problem.
Signed-off-by Peter Chen <[email protected]>Reported-by Arnd Bergmann <[email protected]>Cc Felipe Balbi <[email protected]>
I was a bit worried that this might break defconfig files that now no longer automatically get OSB_OTG enabled, but I have checked all defconfig files we have in the kernel and none of them uses USB_OTG_FSM, FSL_USB2_OTG or USB_MV_OTG, so we are fine.
Thanks!
Arnd
Quoted 6 lines · Arnd Bergmann
Quoted 5 lines · On Wednesday 18 November 2015 11:17:50 Peter Chen wrote:
From
3a6918dae038aadc200dcf0263f4440acc2353d4Mon Sep 17 00:00:00 2001
From: Peter Chen <[email protected]>
Date: Wed, 18 Nov 2015 11:06:34 +0800
Subject: [PATCH 1/1] usb: kconfig: fix warning of selectUSB_OTG
Quoted 7 lines
Quoted 5 lines
When choose randconfig for kernel build, it reports below warning:
"warning: (USB_OTG_FSM&&FSL_USB2_OTG&&USB_MV_OTG) selectsUSB_OTGwhich has unmet direct dependencies (USB_SUPPORT&& USB && PM)"In fact,
USB_OTGis visual symbol and depends on PM, so the drivervisible ?
Yes, will change this typo
Quoted 7 lines
Quoted 6 lines
needs to depend on it to reduce dependency problem.
Signed-off-by Peter Chen <[email protected]>Reported-by Arnd Bergmann <[email protected]>Cc Felipe Balbi <[email protected]>
Quoted 6 lines
Acked-by Arnd Bergmann <[email protected]>I was a bit worried that this might break defconfig files that now no longer automatically get
OSB_OTGenabled, but I have checked all defconfig files we have in the kernel and none of them usesUSB_OTG_FSM,FSL_USB2_OTGorUSB_MV_OTG, so we are fine.
Thanks.
Quoted 4 lines
Thanks!
Arnd
Signature · 2 lines
Best Regards, Peter Chen