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

usb: uhci: Use platform_get_irq() to get the interrupt

Accessing platform device resources directly has long been deprecated for
DT as IRQ resources may not be available at device creation time. Drivers
continuing to use static IRQ resources is blocking removing the static setup
from the DT core code.

Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20211215225203.1991003-1-robh@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Rob Herring and committed by
Greg Kroah-Hartman
e1ffd5f0 b6886c78

+5 -1
+5 -1
drivers/usb/host/uhci-platform.c
··· 133 133 goto err_rmr; 134 134 } 135 135 136 - ret = usb_add_hcd(hcd, pdev->resource[1].start, IRQF_SHARED); 136 + ret = platform_get_irq(pdev, 0); 137 + if (ret < 0) 138 + goto err_clk; 139 + 140 + ret = usb_add_hcd(hcd, ret, IRQF_SHARED); 137 141 if (ret) 138 142 goto err_clk; 139 143