summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorThomas Jarosch <thomas.jarosch@intra2net.com>2011-10-15 18:38:40 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-12-11 12:08:21 -0200
commita32390d808b5b7a6b1c7f9236673c917b4733f13 (patch)
treefdb29aab6f5a46f991222c753910f8d63a2da690 /drivers
parent5eefb4f09bd8b250421fbd055e67d136d57f4030 (diff)
[media] m5mols: Fix logic in sanity check
Detected by "cppcheck". Signed-off-by: Thomas Jarosch <thomas.jarosch@intra2net.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/video/m5mols/m5mols_core.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/video/m5mols/m5mols_core.c b/drivers/media/video/m5mols/m5mols_core.c
index 68497f8ddcd9..5da8d74df508 100644
--- a/drivers/media/video/m5mols/m5mols_core.c
+++ b/drivers/media/video/m5mols/m5mols_core.c
@@ -333,7 +333,7 @@ int m5mols_mode(struct m5mols_info *info, u8 mode)
int ret = -EINVAL;
u8 reg;
- if (mode < REG_PARAMETER && mode > REG_CAPTURE)
+ if (mode < REG_PARAMETER || mode > REG_CAPTURE)
return ret;
ret = m5mols_read_u8(sd, SYSTEM_SYSMODE, &reg);