diff mbox

Fixed typo on ac97_fc_rec_volume_put.

Message ID 20180524160537.1312-1-guylovesbritt@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Guy Chronister May 24, 2018, 4:05 p.m. UTC
Signed-off-by: Guy Chronister <guylovesbritt@gmail.com>
---
 sound/pci/oxygen/oxygen_mixer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Takashi Iwai May 28, 2018, 3:28 p.m. UTC | #1
On Thu, 24 May 2018 18:05:37 +0200,
Guy Chronister wrote:
> 
> Signed-off-by: Guy Chronister <guylovesbritt@gmail.com>

Actually this is not about fixing typo, but fixing a real bug that
ignores the right channel for the recording volume.
Could you refresh the change log text to referring that?


thanks,

Takashi

> ---
>  sound/pci/oxygen/oxygen_mixer.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/sound/pci/oxygen/oxygen_mixer.c b/sound/pci/oxygen/oxygen_mixer.c
> index 4ca12665ff73..64a82688d7fb 100644
> --- a/sound/pci/oxygen/oxygen_mixer.c
> +++ b/sound/pci/oxygen/oxygen_mixer.c
> @@ -730,7 +730,7 @@ static int ac97_fp_rec_volume_put(struct snd_kcontrol *ctl,
>  	oldreg = oxygen_read_ac97(chip, 1, AC97_REC_GAIN);
>  	newreg = oldreg & ~0x0707;
>  	newreg = newreg | (value->value.integer.value[0] & 7);
> -	newreg = newreg | ((value->value.integer.value[0] & 7) << 8);
> +	newreg = newreg | ((value->value.integer.value[1] & 7) << 8);
>  	change = newreg != oldreg;
>  	if (change)
>  		oxygen_write_ac97(chip, 1, AC97_REC_GAIN, newreg);
> -- 
> 2.17.0
> 
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
>
diff mbox

Patch

diff --git a/sound/pci/oxygen/oxygen_mixer.c b/sound/pci/oxygen/oxygen_mixer.c
index 4ca12665ff73..64a82688d7fb 100644
--- a/sound/pci/oxygen/oxygen_mixer.c
+++ b/sound/pci/oxygen/oxygen_mixer.c
@@ -730,7 +730,7 @@  static int ac97_fp_rec_volume_put(struct snd_kcontrol *ctl,
 	oldreg = oxygen_read_ac97(chip, 1, AC97_REC_GAIN);
 	newreg = oldreg & ~0x0707;
 	newreg = newreg | (value->value.integer.value[0] & 7);
-	newreg = newreg | ((value->value.integer.value[0] & 7) << 8);
+	newreg = newreg | ((value->value.integer.value[1] & 7) << 8);
 	change = newreg != oldreg;
 	if (change)
 		oxygen_write_ac97(chip, 1, AC97_REC_GAIN, newreg);