diff options
author | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-06-20 12:11:15 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@s-opensource.com> | 2017-06-20 12:11:15 +0200 |
commit | 8ca00927d61eb4dafe823387f1fb23913ffed5f0 (patch) | |
tree | 2c1ceb002236719b318f5834e5cba97578065e92 /drivers/media/i2c/max2175.c | |
parent | [media] MAINTAINERS: Add entry for R-Car DRIF & MAX2175 drivers (diff) | |
download | linux-8ca00927d61eb4dafe823387f1fb23913ffed5f0.tar.xz linux-8ca00927d61eb4dafe823387f1fb23913ffed5f0.zip |
[media] max2175: remove an useless comparision
load is an unsigned integer. So, it is always bigger or equal
to zero, as reported by gcc:
drivers/media/i2c/max2175.c: In function 'max2175_refout_load_to_bits':
drivers/media/i2c/max2175.c:1272:11: warning: comparison of unsigned expression >= 0 is always true [-Wtype-limits]
if (load >= 0 && load <= 40)
^~
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/i2c/max2175.c')
-rw-r--r-- | drivers/media/i2c/max2175.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/i2c/max2175.c b/drivers/media/i2c/max2175.c index 0d28a80f8ed2..a4736a8a7792 100644 --- a/drivers/media/i2c/max2175.c +++ b/drivers/media/i2c/max2175.c @@ -1269,7 +1269,7 @@ static const struct v4l2_ctrl_config max2175_na_rx_mode = { static int max2175_refout_load_to_bits(struct i2c_client *client, u32 load, u32 *bits) { - if (load >= 0 && load <= 40) + if (load <= 40) *bits = load / 10; else if (load >= 60 && load <= 70) *bits = load / 10 - 1; |