linux/drivers/media/usb/em28xx
Colin Ian King 801e3659bf media: em28xx: calculate left volume level correctly
The calculation of the left volume looks suspect, the value of
0x1f - ((val << 8) & 0x1f) is always 0x1f. The debug prior to the
assignment of value[1] prints the left volume setting using the
calculation 0x1f - (val >> 8) & 0x1f which looks correct to me.
Fix the left volume by using the correct expression as used in
the debug.

Detected by CoverityScan, CID#146140 ("Wrong operator used")

Fixes: 850d24a5a8 ("[media] em28xx-alsa: add mixer support for AC97 volume controls")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Hans Verkuil <hansverk@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-08-26 14:31:49 -04:00
..
em28xx-audio.c media: em28xx: calculate left volume level correctly 2017-08-26 14:31:49 -04:00
em28xx-camera.c [media] em28xx: shed some light on video input formats 2017-04-17 17:32:44 -03:00
em28xx-cards.c media: em28xx: add support for new of Terratec H6 2017-06-24 15:45:28 -03:00
em28xx-core.c [media] em28xx: fix+improve the register (usb control message) debugging 2017-06-06 07:31:40 -03:00
em28xx-dvb.c media: em28xx: add support for new of Terratec H6 2017-06-24 15:45:28 -03:00
em28xx-i2c.c media: usb: make i2c_adapter const 2017-08-26 08:41:58 -04:00
em28xx-input.c media: rc: rename RC_TYPE_* to RC_PROTO_* and RC_BIT_* to RC_PROTO_BIT_* 2017-08-20 10:02:48 -04:00
em28xx-reg.h [media] em28xx: shed some light on video input formats 2017-04-17 17:32:44 -03:00
em28xx-v4l.h [media] em28xx: checkpatch cleanup: whitespaces/new lines cleanups 2014-12-04 14:13:14 -02:00
em28xx-vbi.c [media] em28xx: use usb_interface for dev_foo() calls 2016-12-12 07:29:08 -02:00
em28xx-video.c [media] em28xx: add support for V4L2_PIX_FMT_SRGGB8 2017-04-17 17:33:53 -03:00
em28xx.h media: em28xx: add support for new of Terratec H6 2017-06-24 15:45:28 -03:00
Kconfig [media] em28xx: add missing auto-selections for build 2017-04-17 17:31:46 -03:00
Makefile [media] em28xx: make em28xx-video to be a separate module 2014-01-07 05:09:26 -02:00