On Sat, Mar 19, 2005 at 04:17:25PM +0100, Sylvain Munaut wrote:
> Hi all,
>
> Found the problem : dma_mask & coherent_dma_mask were not initialized
> properly in my struct device. The "old" OCP driver did force them to
> default values but adapting it to the new glue model I dropped that.
I was bitten by that before. It would be good to add a check in
for NULL dma_mask, to save some time for the next guy, but I haven't
looked for the best place to add such a test.
> Anyway now it works, sorry for the inconvenience.
>
> I included a few fixes for that bus glue. The first is a supplementary
> safety if the platform data is not set. The second is a typo fix for an
> error added in the last change set.
>
> Thanks for the help,
>
> Sylvain
Thank you Sylvain. Would you add a Signed-of-by line and resubmit?
-Dale
This patch avoids a null-pointer dereference and fixes a typo.
Acked-by: Dale Farnsworth <[EMAIL PROTECTED]>
===== ohci-ppc-soc.c 1.2 vs edited =====
--- 1.2/drivers/usb/host/ohci-ppc-soc.c 2005-03-08 05:43:18 +01:00
+++ edited/ohci-ppc-soc.c 2005-03-19 16:06:23 +01:00
@@ -73,7 +73,7 @@
goto err2;
}
- if (pd->start && (retval = pd->start(pdev)))
+ if (pd && pd->start && (retval = pd->start(pdev)))
goto err3;
ohci = hcd_to_ohci(hcd);
@@ -123,7 +123,7 @@
iounmap(hcd->regs);
release_mem_region(hcd->rsrc_start, hcd->rsrc_len);
- usb_hcd_put(hcd);
+ usb_put_hcd(hcd);
}
static int __devinit
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel