[alsa-devel] link between HDMI ELD and PCM devices
Pierre-Louis Bossart
pierre-louis.bossart at linux.intel.com
Wed Sep 21 20:59:12 CEST 2011
> GeForce 520 (1 codec, up to 4 pins per, but 2 pins disabled):
>
> [swarren at swarren-lx2 alsa-driver-build]$ sudo amixer -c1 controls | grep ELD
> numid=5,iface=PCM,name='ELD',device=3
> numid=10,iface=PCM,name='ELD',device=7
>
> GeForce 200 series (4 codecs, 1 pin per):
>
> [swarren at swarren-lx2 alsa-driver-build]$ sudo amixer -c2 controls | grep ELD
> numid=5,iface=PCM,name='ELD',device=3
> numid=10,iface=PCM,name='ELD',device=7
> numid=15,iface=PCM,name='ELD',device=8
> numid=20,iface=PCM,name='ELD',device=9
>
> That looks pretty sane to me.
Excellent. Thanks for your time!
> It doesn't apply to ToT; it conflicts slightly with Takashi's recent
> ELD bytes cleanup.
Ah, yes. Haven't updated since kernel.org went down.
> pin_idx = kcontrol->private_value;
> ...
> > + if (pin_idx < 0) {
> > + uinfo->count = 0;
>
> I don't think you need that conditional. I'd just assume that pin_idx
> was set correctly when the control was created, and not create the
> control if that wasn't the case. At most, BUG_ON here?
Agree. All this was copy/pasted debug code in case I modified things.
> One question: How do we know that ucontrol is large enough to accept
> eld->eld_size; are all BYTES controls always big enough, or do we need
> a check here on ucontrol->value.bytes.size or something like that?
The ELD is limited to 256 bytes. Same as the size of a BYTES control.
More information about the Alsa-devel
mailing list