aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/export-to-postgresql.py
diff options
context:
space:
mode:
authorYuan Can <[email protected]>2022-11-11 06:08:53 +0000
committerHans Verkuil <[email protected]>2022-11-18 15:48:17 +0100
commitb434422c45282a0573d8123239abc41fa72665d4 (patch)
treee923e34b107590bc13bb62e0de692babf0cfaf69 /tools/perf/scripts/python/export-to-postgresql.py
parent9b358183b405651bc917c70975c17754da574c03 (diff)
media: platform: exynos4-is: Fix error handling in fimc_md_init()
A problem about modprobe s5p_fimc failed is triggered with the following log given: [ 272.075275] Error: Driver 'exynos4-fimc' is already registered, aborting... modprobe: ERROR: could not insert 's5p_fimc': Device or resource busy The reason is that fimc_md_init() returns platform_driver_register() directly without checking its return value, if platform_driver_register() failed, it returns without unregister fimc_driver, resulting the s5p_fimc can never be installed later. A simple call graph is shown as below: fimc_md_init() fimc_register_driver() # register fimc_driver platform_driver_register() platform_driver_register() driver_register() bus_add_driver() dev = kzalloc(...) # OOM happened # return without unregister fimc_driver Fix by unregister fimc_driver when platform_driver_register() returns error. Fixes: d3953223b090 ("[media] s5p-fimc: Add the media device driver") Signed-off-by: Yuan Can <[email protected]> Signed-off-by: Hans Verkuil <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions