[PATCH v3 5/6] ARM: mxs: add usb phy operations

Russell King - ARM Linux linux at arm.linux.org.uk
Thu Jul 28 07:27:02 EDT 2011


On Wed, Jul 27, 2011 at 10:03:15AM +0200, Sascha Hauer wrote:
> On Wed, Jul 27, 2011 at 01:29:33PM +0800, Tony Lin wrote:
> > +	if (!ppriv->phy_regs || !ppriv->ctrl_regs) {
> > +		iounmap(ppriv->phy_regs);
> > +		iounmap(ppriv->ctrl_regs);
> > +		return -ENOMEM;
> > +	}
> 
> So you call iounmap(0) here.

That is not a problem.  iounmap() is like kfree().  It's designed to cope
with NULL.



More information about the linux-arm-kernel mailing list