]> www.infradead.org Git - linux.git/commit
media: meson: vdec_1: Refactor vdec_1_stop()
authorRicardo Ribalda <ribalda@chromium.org>
Fri, 16 Aug 2024 12:32:03 +0000 (12:32 +0000)
committerHans Verkuil <hverkuil-cisco@xs4all.nl>
Sat, 31 Aug 2024 07:40:43 +0000 (09:40 +0200)
commitbc24a85d41272c6fac77c07da46882df7cd81799
tree447d5ac44b5d51a1128b1f4231a138b1053e631e
parent157c73682dc0d0913b2f4543d5589151587a81d7
media: meson: vdec_1: Refactor vdec_1_stop()

Factor out all the power off logic, except the clk_disable_unprepare(),
to a new function __vdec_1_stop().

This allows vdec_1_start() to explicitly clean-out the clock during the
error-path.

The following smatch warning is fixed:
drivers/staging/media/meson/vdec/vdec_1.c:239 vdec_1_start() warn: 'core->vdec_1_clk' from clk_prepare_enable() not released on lines: 239.

Signed-off-by: Ricardo Ribalda <ribalda@chromium.org>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
drivers/staging/media/meson/vdec/vdec_1.c