lkml.org 
[lkml]   [2010]   [Dec]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRE: [PATCH v5] ppc44x:PHY fixup for USB on canyonlands board
>This can fail if you boot a new kernel on a board with an old FDT that
lacks the gpio node. Calling of_iomap with a NULL np seems like it would
work without crashing anything, so maybe that's not a huge issue.

>>+ vaddr = of_iomap(np, 0);
>>+ if (!vaddr) {
>>+ printk(KERN_CRIT "Could not get gpio node address\n");
>>+ ret = -ENODEV;
>>+ goto err_bcsr;
>>+ }

>A reference count is leaked for the node in this error case because
of_node_put isn't called for the gpio node. Also, iounmap is never called
on vaddr.

>>+ /* Disable USB, through the BCSR7 bits */


Thanks for your inputs. I will fix and resubmit.

Regards,
Rup


\
 
 \ /
  Last update: 2010-12-13 08:19    [W:0.040 / U:0.044 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site