Re: [PATCH v1 4/7] usb: chipidea: add imx driver binding

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

Hi,

On Wed, May 16, 2012 at 02:38:44PM +0300, Alexander Shishkin wrote:
> > +	plat_ci = platform_device_alloc("ci_hdrc", (int)res->start);
> 
> Regarding the instance id here: you probably want to use something more
> meaningful than the starting address. I was thinking about stealing id
> allocator from Felipe's dwc3 (dwc3_get_device_id()), but decided to
> first deal with more important things.
> 
> I was considering using idr for this, but it kind of feels like an
> overkill for this purpose. So I'm wondering if it makes sense to
> generalize dwc3_get_device_id() so that other drivers can make use of
> it?

Yeah, I once considered a situation were the platform_bus implementation
would handle that for us. never got to implement it though.

I would be cool to see though. Not sure how Greg would feel about it.

-- 
balbi

Attachment: signature.asc
Description: Digital signature

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

[Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [PDAs]     [Linux]     [Linux MIPS]     [Yosemite Campsites]     [Photos]

Add to Google Follow linuxarm on Twitter