* [PATCH] usb: phy: Quiet unable to find transceiver message
@ 2014-01-25 15:05 Josh Boyer
2014-01-25 15:37 ` Alan Stern
0 siblings, 1 reply; 7+ messages in thread
From: Josh Boyer @ 2014-01-25 15:05 UTC (permalink / raw)
To: Felipe Balbi, Greg Kroah-Hartman
Cc: linux-usb, linux-kernel, valentine.barshak
commit 1ae5799ef6317 ("usb: hcd: Initialize USB phy if needed") allows
the USB layer to initialize external PHYs if needed. However, a PHY is
not needed in all cases. The usb_get_phy_device function will print
an error message, "unable to find transceiver" but everything still
functions normally.
Drop the severity of this message to pr_debug.
Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org>
---
drivers/usb/phy/phy.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/phy/phy.c b/drivers/usb/phy/phy.c
index e6f61e4..c7fe880 100644
--- a/drivers/usb/phy/phy.c
+++ b/drivers/usb/phy/phy.c
@@ -228,7 +228,7 @@ struct usb_phy *usb_get_phy_dev(struct device *dev, u8 index)
phy = __usb_find_phy_dev(dev, &phy_bind_list, index);
if (IS_ERR(phy) || !try_module_get(phy->dev->driver->owner)) {
- pr_err("unable to find transceiver\n");
+ pr_debug("unable to find transceiver\n");
goto err0;
}
--
1.8.5.3
^ permalink raw reply related [flat|nested] 7+ messages in thread* Re: [PATCH] usb: phy: Quiet unable to find transceiver message 2014-01-25 15:05 [PATCH] usb: phy: Quiet unable to find transceiver message Josh Boyer @ 2014-01-25 15:37 ` Alan Stern 2014-01-25 20:24 ` Josh Boyer 0 siblings, 1 reply; 7+ messages in thread From: Alan Stern @ 2014-01-25 15:37 UTC (permalink / raw) To: Josh Boyer Cc: Felipe Balbi, Greg Kroah-Hartman, linux-usb, linux-kernel, valentine.barshak On Sat, 25 Jan 2014, Josh Boyer wrote: > commit 1ae5799ef6317 ("usb: hcd: Initialize USB phy if needed") allows > the USB layer to initialize external PHYs if needed. However, a PHY is > not needed in all cases. The usb_get_phy_device function will print > an error message, "unable to find transceiver" but everything still > functions normally. > > Drop the severity of this message to pr_debug. > > Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org> > --- > drivers/usb/phy/phy.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/usb/phy/phy.c b/drivers/usb/phy/phy.c > index e6f61e4..c7fe880 100644 > --- a/drivers/usb/phy/phy.c > +++ b/drivers/usb/phy/phy.c > @@ -228,7 +228,7 @@ struct usb_phy *usb_get_phy_dev(struct device *dev, u8 index) > > phy = __usb_find_phy_dev(dev, &phy_bind_list, index); > if (IS_ERR(phy) || !try_module_get(phy->dev->driver->owner)) { > - pr_err("unable to find transceiver\n"); > + pr_debug("unable to find transceiver\n"); > goto err0; > } Wouldn't it make more sense to change this to dev_debug? As it stands, the user has no idea which device is lacking a transceiver. (The same is probably true for other log messages in this source file.) Alan Stern ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] usb: phy: Quiet unable to find transceiver message 2014-01-25 15:37 ` Alan Stern @ 2014-01-25 20:24 ` Josh Boyer 2014-01-27 15:30 ` Felipe Balbi 0 siblings, 1 reply; 7+ messages in thread From: Josh Boyer @ 2014-01-25 20:24 UTC (permalink / raw) To: Alan Stern Cc: Felipe Balbi, Greg Kroah-Hartman, linux-usb, Linux-Kernel@Vger. Kernel. Org, valentine.barshak On Sat, Jan 25, 2014 at 10:37 AM, Alan Stern <stern@rowland.harvard.edu> wrote: > On Sat, 25 Jan 2014, Josh Boyer wrote: > >> commit 1ae5799ef6317 ("usb: hcd: Initialize USB phy if needed") allows >> the USB layer to initialize external PHYs if needed. However, a PHY is >> not needed in all cases. The usb_get_phy_device function will print >> an error message, "unable to find transceiver" but everything still >> functions normally. >> >> Drop the severity of this message to pr_debug. >> >> Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org> >> --- >> drivers/usb/phy/phy.c | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/drivers/usb/phy/phy.c b/drivers/usb/phy/phy.c >> index e6f61e4..c7fe880 100644 >> --- a/drivers/usb/phy/phy.c >> +++ b/drivers/usb/phy/phy.c >> @@ -228,7 +228,7 @@ struct usb_phy *usb_get_phy_dev(struct device *dev, u8 index) >> >> phy = __usb_find_phy_dev(dev, &phy_bind_list, index); >> if (IS_ERR(phy) || !try_module_get(phy->dev->driver->owner)) { >> - pr_err("unable to find transceiver\n"); >> + pr_debug("unable to find transceiver\n"); >> goto err0; >> } > > Wouldn't it make more sense to change this to dev_debug? As it stands, > the user has no idea which device is lacking a transceiver. Quite possibly, yes. I'm not overly familiar with the subsystem and was just writing up what Felipe suggested. > (The same is probably true for other log messages in this source file.) I don't disagree, but I'd rather someone with more experience in the USB subsystem do that kind of broader audit/change. I'd be happy to test. josh ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] usb: phy: Quiet unable to find transceiver message 2014-01-25 20:24 ` Josh Boyer @ 2014-01-27 15:30 ` Felipe Balbi 2014-02-03 15:29 ` Paul Bolle 0 siblings, 1 reply; 7+ messages in thread From: Felipe Balbi @ 2014-01-27 15:30 UTC (permalink / raw) To: Josh Boyer Cc: Alan Stern, Felipe Balbi, Greg Kroah-Hartman, linux-usb, Linux-Kernel@Vger. Kernel. Org, valentine.barshak [-- Attachment #1: Type: text/plain, Size: 2053 bytes --] On Sat, Jan 25, 2014 at 03:24:55PM -0500, Josh Boyer wrote: > On Sat, Jan 25, 2014 at 10:37 AM, Alan Stern <stern@rowland.harvard.edu> wrote: > > On Sat, 25 Jan 2014, Josh Boyer wrote: > > > >> commit 1ae5799ef6317 ("usb: hcd: Initialize USB phy if needed") allows > >> the USB layer to initialize external PHYs if needed. However, a PHY is > >> not needed in all cases. The usb_get_phy_device function will print > >> an error message, "unable to find transceiver" but everything still > >> functions normally. > >> > >> Drop the severity of this message to pr_debug. > >> > >> Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org> > >> --- > >> drivers/usb/phy/phy.c | 2 +- > >> 1 file changed, 1 insertion(+), 1 deletion(-) > >> > >> diff --git a/drivers/usb/phy/phy.c b/drivers/usb/phy/phy.c > >> index e6f61e4..c7fe880 100644 > >> --- a/drivers/usb/phy/phy.c > >> +++ b/drivers/usb/phy/phy.c > >> @@ -228,7 +228,7 @@ struct usb_phy *usb_get_phy_dev(struct device *dev, u8 index) > >> > >> phy = __usb_find_phy_dev(dev, &phy_bind_list, index); > >> if (IS_ERR(phy) || !try_module_get(phy->dev->driver->owner)) { > >> - pr_err("unable to find transceiver\n"); > >> + pr_debug("unable to find transceiver\n"); > >> goto err0; > >> } > > > > Wouldn't it make more sense to change this to dev_debug? As it stands, > > the user has no idea which device is lacking a transceiver. > > Quite possibly, yes. I'm not overly familiar with the subsystem and > was just writing up what Felipe suggested. > > > (The same is probably true for other log messages in this source file.) > > I don't disagree, but I'd rather someone with more experience in the > USB subsystem do that kind of broader audit/change. I'd be happy to > test. yeah, I just sent a patch where I forgot to switch over to dev_dbg(), if you can do that for both messages and remove the out of memory message, I'd be glad to take your patch instead of mine. cheers -- balbi [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 819 bytes --] ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] usb: phy: Quiet unable to find transceiver message 2014-01-27 15:30 ` Felipe Balbi @ 2014-02-03 15:29 ` Paul Bolle 2014-02-03 16:04 ` Alan Stern 0 siblings, 1 reply; 7+ messages in thread From: Paul Bolle @ 2014-02-03 15:29 UTC (permalink / raw) To: balbi Cc: Josh Boyer, Alan Stern, Greg Kroah-Hartman, linux-usb, Linux-Kernel@Vger. Kernel. Org, valentine.barshak Felipe Balbi schreef op ma 27-01-2014 om 09:30 [-0600]: > On Sat, Jan 25, 2014 at 03:24:55PM -0500, Josh Boyer wrote: > > On Sat, Jan 25, 2014 at 10:37 AM, Alan Stern <stern@rowland.harvard.edu> wrote: > > > On Sat, 25 Jan 2014, Josh Boyer wrote: > > > > > >> commit 1ae5799ef6317 ("usb: hcd: Initialize USB phy if needed") allows > > >> the USB layer to initialize external PHYs if needed. However, a PHY is > > >> not needed in all cases. The usb_get_phy_device function will print (Minor nit: that should have been "usb_get_phy_dev".) > > >> an error message, "unable to find transceiver" but everything still > > >> functions normally. > > >> > > >> Drop the severity of this message to pr_debug. > > >> > > >> Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org> > > >> --- > > >> drivers/usb/phy/phy.c | 2 +- > > >> 1 file changed, 1 insertion(+), 1 deletion(-) > > >> > > >> diff --git a/drivers/usb/phy/phy.c b/drivers/usb/phy/phy.c > > >> index e6f61e4..c7fe880 100644 > > >> --- a/drivers/usb/phy/phy.c > > >> +++ b/drivers/usb/phy/phy.c > > >> @@ -228,7 +228,7 @@ struct usb_phy *usb_get_phy_dev(struct device *dev, u8 index) > > >> > > >> phy = __usb_find_phy_dev(dev, &phy_bind_list, index); > > >> if (IS_ERR(phy) || !try_module_get(phy->dev->driver->owner)) { > > >> - pr_err("unable to find transceiver\n"); > > >> + pr_debug("unable to find transceiver\n"); > > >> goto err0; > > >> } > > > > > > Wouldn't it make more sense to change this to dev_debug? As it stands, > > > the user has no idea which device is lacking a transceiver. > > > > Quite possibly, yes. I'm not overly familiar with the subsystem and > > was just writing up what Felipe suggested. > > > > > (The same is probably true for other log messages in this source file.) > > > > I don't disagree, but I'd rather someone with more experience in the > > USB subsystem do that kind of broader audit/change. I'd be happy to > > test. > > yeah, I just sent a patch where I forgot to switch over to dev_dbg(), if > you can do that for both messages and remove the out of memory message, > I'd be glad to take your patch instead of mine. This message cab still be seen when booting v3.14-rc1. Is a patch to downgrade this message to dev_dbg() - from Josh, Felipe or someone else - queued somewhere? Paul Bolle ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] usb: phy: Quiet unable to find transceiver message 2014-02-03 15:29 ` Paul Bolle @ 2014-02-03 16:04 ` Alan Stern 2014-02-03 18:37 ` Paul Bolle 0 siblings, 1 reply; 7+ messages in thread From: Alan Stern @ 2014-02-03 16:04 UTC (permalink / raw) To: Paul Bolle Cc: balbi, Josh Boyer, Greg Kroah-Hartman, linux-usb, Linux-Kernel@Vger. Kernel. Org, valentine.barshak On Mon, 3 Feb 2014, Paul Bolle wrote: > > > >> --- a/drivers/usb/phy/phy.c > > > >> +++ b/drivers/usb/phy/phy.c > > > >> @@ -228,7 +228,7 @@ struct usb_phy *usb_get_phy_dev(struct device *dev, u8 index) > > > >> > > > >> phy = __usb_find_phy_dev(dev, &phy_bind_list, index); > > > >> if (IS_ERR(phy) || !try_module_get(phy->dev->driver->owner)) { > > > >> - pr_err("unable to find transceiver\n"); > > > >> + pr_debug("unable to find transceiver\n"); > > > >> goto err0; > > > >> } > > > > > > > > Wouldn't it make more sense to change this to dev_debug? As it stands, > > > > the user has no idea which device is lacking a transceiver. > > > > > > Quite possibly, yes. I'm not overly familiar with the subsystem and > > > was just writing up what Felipe suggested. > > > > > > > (The same is probably true for other log messages in this source file.) > > > > > > I don't disagree, but I'd rather someone with more experience in the > > > USB subsystem do that kind of broader audit/change. I'd be happy to > > > test. > > > > yeah, I just sent a patch where I forgot to switch over to dev_dbg(), if > > you can do that for both messages and remove the out of memory message, > > I'd be glad to take your patch instead of mine. > > This message cab still be seen when booting v3.14-rc1. Is a patch to > downgrade this message to dev_dbg() - from Josh, Felipe or someone else > - queued somewhere? http://marc.info/?l=linux-usb&m=139092084714232&w=2 As far as I know, this hasn't been merged into anybody's tree yet. And Felipe is on vacation for a few weeks. Still, it should get in before 3.14 is released. Alan Stern ^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] usb: phy: Quiet unable to find transceiver message 2014-02-03 16:04 ` Alan Stern @ 2014-02-03 18:37 ` Paul Bolle 0 siblings, 0 replies; 7+ messages in thread From: Paul Bolle @ 2014-02-03 18:37 UTC (permalink / raw) To: Alan Stern Cc: balbi, Josh Boyer, Greg Kroah-Hartman, linux-usb, Linux-Kernel@Vger. Kernel. Org, valentine.barshak On Mon, 2014-02-03 at 11:04 -0500, Alan Stern wrote: > On Mon, 3 Feb 2014, Paul Bolle wrote: > > This message cab still be seen when booting v3.14-rc1. Is a patch to > > downgrade this message to dev_dbg() - from Josh, Felipe or someone else > > - queued somewhere? > > http://marc.info/?l=linux-usb&m=139092084714232&w=2 > > As far as I know, this hasn't been merged into anybody's tree yet. And > Felipe is on vacation for a few weeks. Still, it should get in before > 3.14 is released. Thanks. I'll add it to my local stack of patches, and if nothing is merged in a few weeks I might send a short reminder. Paul Bolle ^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2014-02-03 18:37 UTC | newest] Thread overview: 7+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2014-01-25 15:05 [PATCH] usb: phy: Quiet unable to find transceiver message Josh Boyer 2014-01-25 15:37 ` Alan Stern 2014-01-25 20:24 ` Josh Boyer 2014-01-27 15:30 ` Felipe Balbi 2014-02-03 15:29 ` Paul Bolle 2014-02-03 16:04 ` Alan Stern 2014-02-03 18:37 ` Paul Bolle
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox