Skip to content
Commit 36e49ffb authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Mauro Carvalho Chehab
Browse files

media: i2c: ov9650: fix potential integer overflow in __ov965x_set_frame_interval



Cast fi->interval.numerator to u64 in order to avoid a potential integer
overflow. This variable is being used in a context that expects an
expression of type u64.

Addresses-Coverity-ID: 1324146 ("Unintentional integer overflow")
[Sakari Ailus: use do_div() to make this work on 32-bit systems]

Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: default avatarSakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent b1f5d0ae
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment