Re: [PATCH] [V1] USB: Add support for Xilinx USB host controller

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Sep 22, 2009 at 06:49:40AM +1000, Benjamin Herrenschmidt wrote:
> On Mon, 2009-09-21 at 13:38 -0600, Julie Zhu wrote:
> 
> > +	iounmap(hcd->regs);
> > +err_ioremap:
> > +	irq_dispose_mapping(irq);
> 
> You missed that one too :-)
> 
> I'm actually considering making irq_dispose_mapping() a private
> API and rename it to something like __irq_dispose_mapping() :-)

I.e. turning irq_dispose_mapping() into nop, and __-prefixed
(private) variant would actually dispose irq mapping?

The nop part is important, because otherwise having no cleanup
variant of an allocation/mapping routine feels odd and might raise
questions by non-ppc people (e.g. subsystem maintainers when they
see no cleanup path for such a call).

And if we'll want to refcount irq mappings in the future, some
drivers will be ready without modifications, i.e. the ones that
got irq_dispose_mapping() wrong:

$ git grep irq_dispose drivers/ | wc -l
42

Thanks,

-- 
Anton Vorontsov
email: cbouatmailru@xxxxxxxxx
irc://irc.freenode.net/bd2
--
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

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux