linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 01/12] usb: mtu3: fix error return code in ssusb_gadget_init()
@ 2017-09-27 10:58 Chunfeng Yun
  2017-09-27 10:58 ` [PATCH 02/12] usb: mtu3: support option to disable usb3 ports Chunfeng Yun
                   ` (11 more replies)
  0 siblings, 12 replies; 19+ messages in thread
From: Chunfeng Yun @ 2017-09-27 10:58 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Felipe Balbi, Rob Herring
  Cc: Mathias Nyman, Matthias Brugger, Mark Rutland, Ian Campbell,
	Chunfeng Yun, linux-kernel, linux-arm-kernel, linux-usb,
	linux-mediatek, devicetree

When fail to get irq number, platform_get_irq() may return
-EPROBE_DEFER, but we ignore it and always return -ENODEV,
so fix it.

Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
---
 drivers/usb/mtu3/mtu3_core.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/mtu3/mtu3_core.c b/drivers/usb/mtu3/mtu3_core.c
index 99c65b0..9475798 100644
--- a/drivers/usb/mtu3/mtu3_core.c
+++ b/drivers/usb/mtu3/mtu3_core.c
@@ -774,9 +774,9 @@ int ssusb_gadget_init(struct ssusb_mtk *ssusb)
 		return -ENOMEM;
 
 	mtu->irq = platform_get_irq(pdev, 0);
-	if (mtu->irq <= 0) {
+	if (mtu->irq < 0) {
 		dev_err(dev, "fail to get irq number\n");
-		return -ENODEV;
+		return mtu->irq;
 	}
 	dev_info(dev, "irq %d\n", mtu->irq);
 
-- 
1.7.9.5

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

end of thread, other threads:[~2017-10-09  3:26 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-27 10:58 [PATCH 01/12] usb: mtu3: fix error return code in ssusb_gadget_init() Chunfeng Yun
2017-09-27 10:58 ` [PATCH 02/12] usb: mtu3: support option to disable usb3 ports Chunfeng Yun
2017-09-27 10:58 ` [PATCH 03/12] usb: mtu3: remove dummy wakeup debounce clocks Chunfeng Yun
2017-09-27 10:58 ` [PATCH 04/12] usb: mtu3: add optional mcu and dma bus clocks Chunfeng Yun
2017-09-27 10:58 ` [PATCH 05/12] usb: mtu3: support 36-bit DMA address Chunfeng Yun
2017-09-27 10:58 ` [PATCH 06/12] usb: mtu3: use FORCE/RG_IDDIG to implement manual DRD switch Chunfeng Yun
2017-09-27 10:58 ` [PATCH 07/12] usb: mtu3: add support for usb3.1 IP Chunfeng Yun
2017-09-29 14:11   ` Chunfeng Yun
2017-09-27 10:58 ` [PATCH 08/12] usb: mtu3: get optional vbus for host only mode Chunfeng Yun
2017-09-27 10:58 ` [PATCH 09/12] usb: mtu3: set invalid dr_mode as dual-role mode Chunfeng Yun
2017-09-28  0:17 ` [PATCH 10/12] dt-bindings: usb: mtu3: add a optional property to disable u3ports Chunfeng Yun
2017-10-05 22:31   ` Rob Herring
2017-10-09  2:43     ` Chunfeng Yun
2017-09-28  0:17 ` [PATCH 11/12] dt-bindings: usb: mtu3: remove dummy clocks and add optional ones Chunfeng Yun
2017-09-28  0:17 ` [PATCH 12/12] dt-bindings: usb: mtu3: remove optional pinctrls Chunfeng Yun
2017-10-05 22:33   ` Rob Herring
2017-10-09  3:25     ` Chunfeng Yun
2017-09-30 13:00 ` [PATCH 01/12] usb: mtu3: fix error return code in ssusb_gadget_init() Sergei Shtylyov
2017-10-09  1:18   ` Chunfeng Yun

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).