Commit a32390d8 authored by Thomas Jarosch's avatar Thomas Jarosch Committed by Mauro Carvalho Chehab

[media] m5mols: Fix logic in sanity check

Detected by "cppcheck".
Signed-off-by: default avatarThomas Jarosch <thomas.jarosch@intra2net.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 5eefb4f0
......@@ -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);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment