[alsa-devel] snd_soc_dai_link.init()
Liam,
Why does the init() function pointer in the snd_soc_dai_link structure take a snd_soc_codec pointer? Wouldn't it make more sense for it to take a snd_soc_dai_link pointer? That way, I could use the init() function to initialize the structure.
I'm trying to write a function that will initialize the codec_dai pointer. I thought I could use snd_soc_dai_link.init(), but I don't know how to get the pointer to the snd_soc_dai_link structure from a snd_soc_codec structure.
/* SoC machine DAI configuration, glues a codec and cpu DAI together */ struct snd_soc_dai_link { char *name; /* Codec name */ char *stream_name; /* Stream name */
/* DAI */ struct snd_soc_codec_dai *codec_dai; struct snd_soc_cpu_dai *cpu_dai;
/* machine stream operations */ struct snd_soc_ops *ops;
/* codec/machine specific init - e.g. add machine controls */ int (*init)(struct snd_soc_codec *codec); };
On Wed, 2007-05-30 at 17:34 -0500, Timur Tabi wrote:
Liam,
Why does the init() function pointer in the snd_soc_dai_link structure take a snd_soc_codec pointer? Wouldn't it make more sense for it to take a snd_soc_dai_link pointer? That way, I could use the init() function to initialize the structure.
Your right, I've logged a bug.
https://bugtrack.alsa-project.org/alsa-bug/view.php?id=3135
I should have some time to look at the bugs tomorrow.
Liam
Liam Girdwood wrote:
On Wed, 2007-05-30 at 17:34 -0500, Timur Tabi wrote:
Liam,
Why does the init() function pointer in the snd_soc_dai_link structure take a snd_soc_codec pointer? Wouldn't it make more sense for it to take a snd_soc_dai_link pointer? That way, I could use the init() function to initialize the structure.
Your right, I've logged a bug.
https://bugtrack.alsa-project.org/alsa-bug/view.php?id=3135
I should have some time to look at the bugs tomorrow.
I'd be happy to create a patch that fixes it today, if you like. I just need to know the URL of the git tree to use as a starting point.
On Thu, 2007-05-31 at 12:04 -0500, Timur Tabi wrote:
Liam Girdwood wrote:
On Wed, 2007-05-30 at 17:34 -0500, Timur Tabi wrote:
Liam,
Why does the init() function pointer in the snd_soc_dai_link structure take a snd_soc_codec pointer? Wouldn't it make more sense for it to take a snd_soc_dai_link pointer? That way, I could use the init() function to initialize the structure.
Your right, I've logged a bug.
https://bugtrack.alsa-project.org/alsa-bug/view.php?id=3135
I should have some time to look at the bugs tomorrow.
I'd be happy to create a patch that fixes it today, if you like. I just need to know the URL of the git tree to use as a starting point.
http://opensource.wolfsonmicro.com/cgi-bin/gitweb/gitweb.cgi?p=linux-2.6-aso...
Master branch should be up to date with mainline, for-alsa-kernel branch should be close to alsa-kernel Hg.
Liam
Liam Girdwood wrote:
http://opensource.wolfsonmicro.com/cgi-bin/gitweb/gitweb.cgi?p=linux-2.6-aso...
Master branch should be up to date with mainline, for-alsa-kernel branch should be close to alsa-kernel Hg.
Does the http:// protocol work with your git repo? Our corporate firewall doesn't allow the git:// protocol.
On Thu, 2007-05-31 at 18:14 -0500, Timur Tabi wrote:
Liam Girdwood wrote:
http://opensource.wolfsonmicro.com/cgi-bin/gitweb/gitweb.cgi?p=linux-2.6-aso...
Master branch should be up to date with mainline, for-alsa-kernel branch should be close to alsa-kernel Hg.
Does the http:// protocol work with your git repo? Our corporate firewall doesn't allow the git:// protocol.
Sorry, we've just added http support now.
I'm going to create a new branch off dev called ppc-dev (will be visible in a few hours). This will be the best place for ppc dev.
Liam
On Fri, 2007-06-01 at 14:38 +0100, Liam Girdwood wrote:
On Thu, 2007-05-31 at 18:14 -0500, Timur Tabi wrote:
Liam Girdwood wrote:
http://opensource.wolfsonmicro.com/cgi-bin/gitweb/gitweb.cgi?p=linux-2.6-aso...
Master branch should be up to date with mainline, for-alsa-kernel branch should be close to alsa-kernel Hg.
Does the http:// protocol work with your git repo? Our corporate firewall doesn't allow the git:// protocol.
Sorry, we've just added http support now.
I'm going to create a new branch off dev called ppc-dev (will be visible in a few hours). This will be the best place for ppc dev.
http:// URL is :-
git-clone http://opensource.wolfsonmicro.com/~git/linux-2.6-asoc/
This will be pull/clone access only. I've created a separate ppc-dev (will show up in a few hours) branch as it will be easier to merge changes in without affecting any of the current working dev tree for other platforms.
I'm going to move the I2C probing out of a codec driver tonight.
Liam
Liam Girdwood wrote:
This will be pull/clone access only. I've created a separate ppc-dev (will show up in a few hours) branch as it will be easier to merge changes in without affecting any of the current working dev tree for other platforms.
Thanks. It looks like fixing bug 3135 isn't as trivial as I thought, so it'll take me longer than expected. Even though it makes more sense to pass a snd_soc_dai_link pointer, all the current code expects a snd_soc_codec pointer.
participants (2)
-
Liam Girdwood
-
Timur Tabi