Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

phy: renesas: rcar-gen3-usb2: exit if request_irq() failed

To avoid unexpected behaviors, it's better to exit if request_irq()
failed.

Suggested-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Link: https://lore.kernel.org/r/1594986297-12434-3-git-send-email-yoshihiro.shimoda.uh@renesas.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Yoshihiro Shimoda and committed by
Vinod Koul
b59aeb1a 08b0ad37

+3 -1
+3 -1
drivers/phy/renesas/phy-rcar-gen3-usb2.c
··· 419 419 INIT_WORK(&channel->work, rcar_gen3_phy_usb2_work); 420 420 ret = request_irq(channel->irq, rcar_gen3_phy_usb2_irq, 421 421 IRQF_SHARED, dev_name(channel->dev), channel); 422 - if (ret < 0) 422 + if (ret < 0) { 423 423 dev_err(channel->dev, "No irq handler (%d)\n", channel->irq); 424 + return ret; 425 + } 424 426 } 425 427 426 428 /* Initialize USB2 part */