[alsa-devel] Oxygen Possible Bug in FCM
nick
xerofoify at gmail.com
Thu Sep 22 06:17:56 CEST 2016
On 2016-09-21 02:47 AM, Clemens Ladisch wrote:
> xerofoify wrote:
>> Do anyone known of the best way to test this function,
>> ac97_fp_rec_volume_put. Seems there may be a bug in
>> it.
>
> What bug?
>
>> I do have the hardware so that's not a issue just wondering what
>> the different between fp_rec and the standard
>> get functions are in terms of testing.
>
> The other functions use five bits, this one uses three bits.
>
That's not what I am getting at seems ac97_fp_rec_volume_get is similar in
logic to ac97_fp_rec_volume_put and therefore in ac97_fp_rec_volume_get:
value->value.integer.value[1] = (reg >> 8) & 7;
is different then ac97_fp_rec_volume_put:
newreg = newreg | ((value->value.integer.value[0] & 7) << 8);
which is is probably accessing an incorrect value in the sound card register
array, at least from my understanding of reading this driver. It seems it
should be accessing the value in index 1 of this particular array of sound card
registers.
> (The AC'97 spec says the REC_GAIN register has four bits for the volume;
> I don't know where the difference comes from.)
>
> And the REC_GAIN register should affect all recorded signals going
> through the AC'97 mixer (all except line in).
>
>> Further more I am assuming this
>> has to do with the fp headphones switch
>> but I don't have headphones that are fp so is there another way to
>> test this particular function without checking
>> sound levels.
>
> You could connect any microphone to the front panel connector.
>
> Or check the AC'97 registers in /proc/asound/cardX/oxygen.
>
OK that seems the easy way to test that the incorrect access I stated above is
actually a issue. Probably best to test it as dealing with registers on hardware
as this can easily lead to regressions and that's why I am asking.
Thanks,
Nick
>
> Regards,
> Clemens
>
More information about the Alsa-devel
mailing list