summaryrefslogtreecommitdiff
path: root/rust/helpers/xarray.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2025-08-13 00:45:53 +0300
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2025-09-09 15:59:19 +0200
commitdd235b07b65e123c0fdadc2883b9c16aa4749164 (patch)
treedff7a01e51c672a9e7cc8f1383bb4500f2903183 /rust/helpers/xarray.c
parentbfa626306cf7be5868a24b86cc358879f4d21dc1 (diff)
media: v4l2-common: Add legacy camera sensor clock helper
The recently introduced devm_v4l2_sensor_clk_get() helper aims at simplifying sensor drivers by centralizing clock handling code, as well as reducing cargo-cult and deprecated behaviour. A set of drivers implement external clock handling in a non-standard way. This can't be changed as there is a high risk of breaking existing platforms, but keeping the code as-is creates a risk of new drivers copying deprecated behaviour. To fix this, introduce a new devm_v4l2_sensor_clk_get_legacy() helper and use it in those driver. Compared to devm_v4l2_sensor_clk_get(), the new helper takes the "clock-frequency" property into account and sets the external clock rate on OF platforms, and adds the ability to specify a fixed default or fallback clock rate in case the "clock-frequency" property is not present. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Reviewed-by: Mehdi Djait <mehdi.djait@linux.intel.com> Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
Diffstat (limited to 'rust/helpers/xarray.c')
0 files changed, 0 insertions, 0 deletions