[alsa-devel] ASOC v2 driver structure
Jon Smirl
jonsmirl at gmail.com
Mon Jan 28 17:03:06 CET 2008
On 1/28/08, Liam Girdwood <liam.girdwood at wolfsonmicro.com> wrote:
> On Sun, 2008-01-27 at 14:15 -0500, Jon Smirl wrote:
> > On 1/27/08, Jon Smirl <jonsmirl at gmail.com> wrote:
> > > I'm trying to write an asoc v2 driver for my powerpc based SOC
> > > (mpc5200) hardware. We have two audio devices on the board, a WM8580
> > > and a TAS5504. How do you do this with asoc v2? The card is created
> > > in snd_soc_machine_create(); there seems to be an assumption of a
> > > single card per machine.
>
> This was the initial assumption in v1. To be honest we were only
> catering for single codec devices. In v2 we are allowing multiple cards
> - struct machine is being refactored atm to make this more obvious.
Another problem is how the drivers for the i2s/ac97 channels get
loaded. In the pxa270 the machine driver loads the i2s/ac97 driver and
it is hooked to the asoc bus. But in the powerpc world drivers for
these channels load via the device tree and they get hooked to the
of_platform_bus. Some of these assumptions in how machines are created
need to be changed to support these drivers on the of_platform_bus.
>
> > >
> > > Or are you supposed to mix the different devices into a single pcm
> > > driver? What would happen in pxa2xx-pcm.c if more than one of these
> > > were defined?
> >
> > I guess I'm supposed to have multiple platform drivers - one per
> > I2C/AC97/SSC channel?
> >
>
> You could do this or create two cards (machines). I've kept platform as
> the DMA + all the interfaces (as some devices have more than one
> interface in operation e.g. AC97 for HiFi and I2S/PCM for voice).
>
> Liam
>
>
> Privacy & Confidentiality Notice
> -------------------------------------------------
> This message and any attachments contain privileged and confidential information that is intended solely for the person(s) to whom it is addressed. If you are not an intended recipient you must not: read; copy; distribute; discuss; take any action in or make any reliance upon the contents of this message; nor open or read any attachment. If you have received this message in error, please notify us as soon as possible on the following telephone number and destroy this message including any attachments. Thank you.
> -------------------------------------------------
> Wolfson Microelectronics plc
> Tel: +44 (0)131 272 7000
> Fax: +44 (0)131 272 7001
> Web: www.wolfsonmicro.com
>
> Registered in Scotland
>
> Company number SC089839
>
> Registered office:
>
> Westfield House, 26 Westfield Road, Edinburgh, EH11 2QB, UK
>
>
--
Jon Smirl
jonsmirl at gmail.com
More information about the Alsa-devel
mailing list