[PATCH 11/78] staging: media: rkvdec: fix pm_runtime_get_sync() usage count

2021-04-23 Thread Mauro Carvalho Chehab
The pm_runtime_get_sync() internally increments the dev->power.usage_count without decrementing it, even on errors. replace it by the new pm_runtime_resume_and_get(), introduced by: commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") in order to properly d

[PATCH 13/78] staging: media: hantro_drv: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 14/78] staging: media: imx7-mipi-csis: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 15/78] staging: media: ipu3: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 17/78] staging: media: vde: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 16/78] staging: media: cedrus_video: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 12/78] staging: media: atomisp_fops: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 18/78] staging: media: csi: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 19/78] staging: media: vi: use pm_runtime_resume_and_get()

2021-04-23 Thread Mauro Carvalho Chehab
Commit dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") added pm_runtime_resume_and_get() in order to automatically handle dev->power.usage_count decrement on errors. Use the new API, in order to cleanup the error check logic. Signed-off-by: Mauro Carvalho C

[PATCH 00/78] media: use pm_runtime_resume_and_get() instead of pm_runtime_get_sync()

2021-04-23 Thread Mauro Carvalho Chehab
During the review of the patches from unm.edu, one of the patterns I noticed is the amount of patches trying to fix pm_runtime_get_sync() calls. On contrary of the common sense that a foo_get() function will only increment the usage on success, pm_runtime_get_sync() increments it unconditionally.