[alsa-devel] [PATCH V3 3/4] Support for AC97 on Phytec pmc030 base board.

Mark Brown broonie at opensource.wolfsonmicro.com
Mon May 25 11:46:24 CEST 2009

On Mon, May 25, 2009 at 12:34:57AM -0600, Grant Likely wrote:

> This is ugly.  I'd really rather have a generic mechanism for creating
> a fabric driver based on the OF data.  But failing that, it seems to
> me that this platform device registration should be done in the
> platform code (arch/powerpc/platforms/52xx).  Doing it in a module
> init looks wrong.

It's ugly but it's idiomatic for ASoC until someone has time to
implement multiple card support.

> I was trying to do a sort of generic matching mechanism with the of
> simple stuff; but admittedly it was hacky and half-assed.  However, I

It's adequate for the cases it tries to cover, it just needs to be
merged into the core.  The problem here is AC97 since it can't be probed
until the platform comes up.

> do still think it is viable to have OF hooks that kick in when codec
> and machine drivers are registered.  If linkage data is encoded in the
> device tree, then generic code should be able to hook them up; pulling
> additional data out of the device tree as needed to configure the
> coded.

As I explained in response to Jon's original posting AC97 is a
particular problem here since it can only be probed using the CPU DAI
and may require machine-specific work to set it up prior to use.
There's problems fixing this due to AC97 not having fully developed bus
infrastructure in the kernel at the minute.

More information about the Alsa-devel mailing list