]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
Staging: bcm2835-audio: && vs & typo
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 14 Feb 2017 23:10:44 +0000 (02:10 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 16 Feb 2017 18:19:44 +0000 (10:19 -0800)
We intended to mask away the upper bits but there is a "&&" vs "&" typo
so it's broken.

Fixes: 23b028c871e1 ("staging: bcm2835-audio: initial staging submission")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/bcm2835-audio/bcm2835-ctl.c

index bfb7e9f74176b5191aa74a38ca8d80fad1f6cb34..a4ffa1bf53e5d6f6520c34ce9f434f9f3dad38a0 100644 (file)
@@ -209,7 +209,7 @@ static int snd_bcm2835_spdif_default_get(struct snd_kcontrol *kcontrol,
 
        for (i = 0; i < 4; i++)
                ucontrol->value.iec958.status[i] =
-               (chip->spdif_status >> (i * 8)) && 0xff;
+                       (chip->spdif_status >> (i * 8)) & 0xff;
 
        mutex_unlock(&chip->audio_mutex);
        return 0;