diff options
author | Michael Büsch <m@bues.ch> | 2013-02-07 10:13:13 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-02-08 14:39:37 -0500 |
commit | 0917a60430cdd4b5d3505c240a04bb0f5927c74b (patch) | |
tree | 6a4f3997d3a3d8c3d9186306b7a7125ebe26d0e4 /drivers/media | |
parent | 82f0efbcd3c4e6bf7cdfeed5c901b812e6d30f92 (diff) |
[media] fc0011: fp/fa value overflow fix
Assign the maximum instead of masking with the maximum on value overflow.
Signed-off-by: Michael Buesch <m@bues.ch>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r-- | drivers/media/tuners/fc0011.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/tuners/fc0011.c b/drivers/media/tuners/fc0011.c index e4882546c283..3089f2ebcbfe 100644 --- a/drivers/media/tuners/fc0011.c +++ b/drivers/media/tuners/fc0011.c | |||
@@ -247,8 +247,8 @@ static int fc0011_set_params(struct dvb_frontend *fe) | |||
247 | fa += 8; | 247 | fa += 8; |
248 | } | 248 | } |
249 | if (fp > 0x1F) { | 249 | if (fp > 0x1F) { |
250 | fp &= 0x1F; | 250 | fp = 0x1F; |
251 | fa &= 0xF; | 251 | fa = 0xF; |
252 | } | 252 | } |
253 | if (fa >= fp) { | 253 | if (fa >= fp) { |
254 | dev_warn(&priv->i2c->dev, | 254 | dev_warn(&priv->i2c->dev, |