aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2014-09-24 06:36:39 -0400
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2014-10-21 06:56:52 -0400
commit9f93c52783faa24c5c6fca216acf0765ad5d8dd6 (patch)
treed7b712a08a22e2d5cb42f736e079cf041263414e /drivers/media
parent143800a5778e577ada53441a42ed1437b3b2b11b (diff)
[media] hackrf: harmless off by one in debug code
My static checker complains that "i" could be one element beyond the end of the array. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/usb/hackrf/hackrf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/usb/hackrf/hackrf.c b/drivers/media/usb/hackrf/hackrf.c
index 328b5ba47a0a..fd1fa412e094 100644
--- a/drivers/media/usb/hackrf/hackrf.c
+++ b/drivers/media/usb/hackrf/hackrf.c
@@ -932,7 +932,7 @@ static int hackrf_set_bandwidth(struct hackrf_dev *dev)
932 dev->bandwidth->val = bandwidth; 932 dev->bandwidth->val = bandwidth;
933 dev->bandwidth->cur.val = bandwidth; 933 dev->bandwidth->cur.val = bandwidth;
934 934
935 dev_dbg(dev->dev, "bandwidth selected=%d\n", bandwidth_lut[i].freq); 935 dev_dbg(dev->dev, "bandwidth selected=%d\n", bandwidth);
936 936
937 u16tmp = 0; 937 u16tmp = 0;
938 u16tmp |= ((bandwidth >> 0) & 0xff) << 0; 938 u16tmp |= ((bandwidth >> 0) & 0xff) << 0;