Re: [RFC PATCH 1/4] PLATFORM: introduce structure to bind async platform data to a dev path name

From: Rafael J. Wysocki
Date: Sun Mar 13 2011 - 08:52:00 EST


On Sunday, March 13, 2011, Andy Green wrote:
> On 03/13/2011 01:03 AM, Somebody in the thread at some point said:
>
> >>> Using device paths for this purpose seems to be very fragile to me. Isn't
> >>> there any better solution?
> >>
> >> Given that this targets board definition files which commonly do the
> >> platform_add_device for the USB bus controller synchronously, and
> >> the bus-connected devices it is aimed at are soldered on to the
> >> board connected to specific bus controllers, the bus paths are
> >> completely deterministic.
> >
> > No they are not.
> >
> > The physical layout is deterministic, but the bus number, and device
> > number, is not. You are using the bus number here in this path, so that
> > is not going to work, sorry.
>
> Okay. This is not a PC we are talking about.
>
> If the platform / board definition file is registering the USB hosts
> synchronously at boot time, the driver is composed into the monolithic
> kernel, there are no PCI busses or whatever on the SoC, the bus indexing
> is totally deterministic. This is extremely common in the platform /
> SoC case and is the case the patchset is targeted at. Even further, the
> only time you'd use it is to reach a USB asset that is wired up the same
> board permanently as well.
>
> Anyway this seems moot by now.

However, if you add a new infrastructure like this, it should be at least
usable on systems that you description doesn't apply to.

Thanks,
Rafael
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/