[PATCH] bcm63xx: use platform_get_irq in ohci-bcm63xx.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



As requested by USB maintainer, use platform_get_irq instead of
platform_get_resource.

Signed-off-by: Maxime Bizon <mbizon@xxxxxxxxxx>
---
 drivers/usb/host/ohci-bcm63xx.c |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/usb/host/ohci-bcm63xx.c b/drivers/usb/host/ohci-bcm63xx.c
index 74f432f..f0e4639 100644
--- a/drivers/usb/host/ohci-bcm63xx.c
+++ b/drivers/usb/host/ohci-bcm63xx.c
@@ -58,15 +58,15 @@ static const struct hc_driver ohci_bcm63xx_hc_driver = {
 
 static int __devinit ohci_hcd_bcm63xx_drv_probe(struct platform_device *pdev)
 {
-	struct resource *res_mem, *res_irq;
+	struct resource *res_mem;
 	struct usb_hcd *hcd;
 	struct ohci_hcd *ohci;
 	u32 reg;
-	int ret;
+	int ret, irq;
 
 	res_mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	res_irq = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
-	if (!res_mem || !res_irq)
+	irq = platform_get_irq(pdev, 0);
+	if (!res_mem || irq < 0)
 		return -ENODEV;
 
 	if (BCMCPU_IS_6348()) {
@@ -114,7 +114,7 @@ static int __devinit ohci_hcd_bcm63xx_drv_probe(struct platform_device *pdev)
 		OHCI_QUIRK_FRAME_NO;
 	ohci_hcd_init(ohci);
 
-	ret = usb_add_hcd(hcd, res_irq->start, IRQF_DISABLED);
+	ret = usb_add_hcd(hcd, irq, IRQF_DISABLED);
 	if (ret)
 		goto out2;
 
-- 
1.6.0.4



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux