USB: isp1760: Assign resource fields before adding hcd

This fixes the bogus "io mem 0x00000000" message printed
during driver init due to hcd->rsrc_start being assigned after
the call to usb_add_hcd().

Signed-off-by: Nate Case <[email protected]>
Acked-by: Sebastian Siewior <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
Nate Case 2008-05-21 16:28:20 -05:00 • committed by Greg Kroah-Hartman
commit e6942d633b

View file

@ -2207,14 +2207,14 @@ struct usb_hcd *isp1760_register(u64 res_start, u64 res_len, int irq,
goto err_put;
}
ret = usb_add_hcd(hcd, irq, irqflags);
if (ret)
goto err_unmap;
hcd->irq = irq;
hcd->rsrc_start = res_start;
hcd->rsrc_len = res_len;
ret = usb_add_hcd(hcd, irq, irqflags);
if (ret)
goto err_unmap;
return hcd;
err_unmap: