summaryrefslogtreecommitdiffstats
path: root/drivers/usb/phy/phy.c
Commit message (Collapse)AuthorAgeFilesLines
* usb: phy: return an error in usb_get_phy() if try_module_get() failsMathias Krause2014-04-161-0/+3
| | | | | | | | | In case we found a matching USB PHY in usb_get_phy() but the call to try_module_get() fails, we shouldn't return a (probably soon dangling) pointer but an ERR_PTR instead. Signed-off-by: Mathias Krause <minipli@googlemail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
* usb: phy: move some error messages to debugJosh Boyer2014-02-041-5/+3
| | | | | | | | | | | | | | | | | | | the PHY layer is supposed to be optional, considering some PHY have no control bus for SW to poke around. After commit 1ae5799 (usb: hcd: Initialize USB phy if needed) any HCD which didn't provide a PHY driver would emit annoying error messages. In this patch we're decreasing those messages to debugging only and we also add a PHY prefix or use dev_dbg so we know where they're coming from. Reported-by: Josh Boyer <jwboyer@fedoraproject.org> Signed-off-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Josh Boyer <jwboyer@fedoraproject.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* usb: phy: initialize the notifier when add a new phyNeil Zhang2013-12-121-0/+4
| | | | | | | | | | We need to initialize the notifer before use it. So lets initialize it when add a new phy device to reduce the code redundancy. Signed-off-by: Neil Zhang <zhangwm@marvell.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
* usb: phy: don't return with NULL from devm_usb_get_phy()Gabor Juhos2013-10-111-1/+1
| | | | | | | | | The callers are expecting an ERR_PTR value in case of an error. Change he code to return with an encoded -ENOMEM value in the case of a failed devres_alloc call. Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Signed-off-by: Felipe Balbi <balbi@ti.com>
* usb: phy: remove exported function from __init sectionDenis Efremov2013-04-231-1/+1
| | | | | | | | | | | The symbol usb_bind_phy is exported and annotated __init. It looks like section mismatch. Fix by removing the __init annotation of usb_bind_phy. Found by Linux Driver Verification project (linuxtesting.org). Signed-off-by: Denis Efremov <yefremov.denis@gmail.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
* usb: phy: convert EXPORT_SYMBOL to EXPORT_SYMBOL_GPLFelipe Balbi2013-03-181-10/+10
| | | | | | | we only want GPL users for our generic functions, so let's switch over to EXPORT_SYMBOL_GPL. Signed-off-by: Felipe Balbi <balbi@ti.com>
* usb: phy: move bulk of otg/otg.c to phy/phy.cSascha Hauer2013-03-181-0/+438
Most of otg/otg.c is not otg specific, but phy specific, so move it to the phy directory. Tested-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Reported-by: Kishon Vijay Abraham I <kishon@ti.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Felipe Balbi <balbi@ti.com>