Use platform helper to obtain irq & mem region instead OF helper. We get a complete platform device out of every OF node so there is no need to use OF helper for the standarf stuff. Signed-off-by: Sebastian Andrzej Siewior <sebastian@xxxxxxxxxxxxx> --- drivers/usb/host/ehci-xilinx-of.c | 16 ++++++++-------- 1 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/usb/host/ehci-xilinx-of.c b/drivers/usb/host/ehci-xilinx-of.c index 8deebb8..2241935 100644 --- a/drivers/usb/host/ehci-xilinx-of.c +++ b/drivers/usb/host/ehci-xilinx-of.c @@ -157,7 +157,7 @@ static int __devinit ehci_hcd_xilinx_of_probe(struct platform_device *op) struct device_node *dn = op->dev.of_node; struct usb_hcd *hcd; struct ehci_hcd *ehci; - struct resource res; + struct resource *res; int irq; int rv; int *value; @@ -167,17 +167,17 @@ static int __devinit ehci_hcd_xilinx_of_probe(struct platform_device *op) dev_dbg(&op->dev, "initializing XILINX-OF USB Controller\n"); - rv = of_address_to_resource(dn, 0, &res); - if (rv) - return rv; + res = platform_get_resource(op, IORESOURCE_MEM, 0); + if (!res) + return -ENODEV; hcd = usb_create_hcd(&ehci_xilinx_of_hc_driver, &op->dev, "XILINX-OF USB"); if (!hcd) return -ENOMEM; - hcd->rsrc_start = res.start; - hcd->rsrc_len = resource_size(&res); + hcd->rsrc_start = res->start; + hcd->rsrc_len = resource_size(res); if (!request_mem_region(hcd->rsrc_start, hcd->rsrc_len, "ehci_hcd")) { printk(KERN_ERR "%s: request_mem_region failed\n", __FILE__); @@ -185,9 +185,9 @@ static int __devinit ehci_hcd_xilinx_of_probe(struct platform_device *op) goto err_rmr; } - irq = irq_of_parse_and_map(dn, 0); + irq = platform_get_irq(op, 0); if (irq == NO_IRQ) { - printk(KERN_ERR "%s: irq_of_parse_and_map failed\n", __FILE__); + printk(KERN_ERR "%s: platform_get_irq failed\n", __FILE__); rv = -EBUSY; goto err_irq; } -- 1.7.5.4 -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html