Gianfar ethernet device

Benjamin Herrenschmidt benh at
Mon Nov 12 11:04:36 EST 2007

On Sun, 2007-11-11 at 18:30 -0500, Jon Smirl wrote:
> Does this patch add the right ifdefs in fsl_soc.c to make these
> drivers build on their proper platforms? As an experiment I have
> disabled platform bus on the mpc5200 and I'm only using of_platform
> bus. Turning off platform bus is exposing a lot of code that is
> getting built into my mpc5200 kernel that is supporting devices not
> available on the platform.
> A few more fixups in some other drivers and I should have mpc5200
> working without platform bus.

That sort of per-platform ifdefs is just WRONG.

On the other hand, if you feel that such common code deserves not being
built on all platforms, then what you can do is define a Kconfig option,
such as CONFIG_PPC_CAN_HAVE_GIANFAR, that gets select'ed by the
platforms that can have a Gianfar and use -that- for the ifdef.


More information about the Linuxppc-dev mailing list