aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python
diff options
context:
space:
mode:
authorKangjie Lu <[email protected]>2018-12-20 23:54:03 -0500
committerMauro Carvalho Chehab <[email protected]>2019-03-19 16:47:20 -0400
commit0ab34a08812a3334350dbaf69a018ee0ab3d2ddd (patch)
treebc758e0bb675e0a991ed0ffcaea6e589d607000b /tools/perf/scripts/python
parent56cd26b618855c9af48c8301aa6754ced8dd0beb (diff)
media: si2165: fix a missing check of return value
si2165_readreg8() may fail. Looking into si2165_readreg8(), we will find that "val_tmp" will be an uninitialized value when regmap_read() fails. "val_tmp" is then assigned to "val". So if si2165_readreg8() fails, "val" will be a random value. Further use will lead to undefined behaviors. The fix checks if si2165_readreg8() fails, and if so, returns its error code upstream. Signed-off-by: Kangjie Lu <[email protected]> Reviewed-by: Matthias Schwarzott <[email protected]> Tested-by: Matthias Schwarzott <[email protected]> Signed-off-by: Sean Young <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions