Re: powerpc_flash_init(), wtf!?

David Gibson
2007-05-03T23:49:19Z

On Thu, May 03, 2007 at 06:21:35PM +0200, Segher Boessenkool wrote:
> > BTW, is it legal/appropriate to specify device (not bus) types for
> > of_platform_bus_probe()?
>
> In almost all cases you should probe on "name"/"compatible",
> and not use "device_type" at all.

I don't think that's what he's getting at. "compatible" is what we
should use for the device <-> driver matching, but
of_platform_bus_probe() is earlier than that, creating the devices in
the first place.

And no, I don't think it is appropriate to specify device types rather
than bus types there. Probing devices independent of the bus type
they sit on will always run the risk of conflicting with the bus
type's specific probe logic.

--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!