public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/5] [media] xc4000: shut up a bogus smatch message
@ 2016-02-22 14:16 Mauro Carvalho Chehab
  2016-02-22 14:16 ` [PATCH 2/5] [media] v4l2-mc: fix hardware version for PCI devices Mauro Carvalho Chehab
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Mauro Carvalho Chehab @ 2016-02-22 14:16 UTC (permalink / raw)
  Cc: Mauro Carvalho Chehab, Linux Media Mailing List,
	Mauro Carvalho Chehab

smatch complains about:
	drivers/media/tuners/xc4000.c:1511 xc4000_get_signal() warn: '~value << 3' 524280 can't fit into 65535 'value'

Remove the bogus complain.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
---
 drivers/media/tuners/xc4000.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/tuners/xc4000.c b/drivers/media/tuners/xc4000.c
index 219ebafae70f..d95c7e082ccf 100644
--- a/drivers/media/tuners/xc4000.c
+++ b/drivers/media/tuners/xc4000.c
@@ -1508,7 +1508,7 @@ static int xc4000_get_signal(struct dvb_frontend *fe, u16 *strength)
 	if (value >= 0x2000) {
 		value = 0;
 	} else {
-		value = ~value << 3;
+		value = (~value << 3) & 0xffff;
 	}
 
 	goto ret;
-- 
2.5.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2016-02-22 14:21 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-22 14:16 [PATCH 1/5] [media] xc4000: shut up a bogus smatch message Mauro Carvalho Chehab
2016-02-22 14:16 ` [PATCH 2/5] [media] v4l2-mc: fix hardware version for PCI devices Mauro Carvalho Chehab
2016-02-22 14:16 ` [PATCH 3/5] [media] tvp5150: don't go past decoder->input_ent array Mauro Carvalho Chehab
2016-02-22 14:21   ` Javier Martinez Canillas
2016-02-22 14:16 ` [PATCH 4/5] [media] saa7134: fix detection of external decoders Mauro Carvalho Chehab
2016-02-22 14:16 ` [PATCH 5/5] [media] dib0090: do the right thing if rf_ramp is NULL Mauro Carvalho Chehab

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox