[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>
This commit is contained in:
Thomas Jarosch 2011-10-15 18:38:40 -03:00 committed by Mauro Carvalho Chehab
parent 5eefb4f09b
commit a32390d808

View File

@ -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);