diff options
| author | Luca Ceresoli <luca.ceresoli@bootlin.com> | 2025-07-09 17:59:38 +0200 |
|---|---|---|
| committer | Luca Ceresoli <luca.ceresoli@bootlin.com> | 2025-07-23 13:03:53 +0200 |
| commit | d4eecb4c24dc160f4a003c804602c746fb8fec58 (patch) | |
| tree | add06a77318d79ac482d683a3e9f0af4d37b068b /rust/helpers/task.c | |
| parent | 9b75346e3c2b8ecb5b90b132c2fc185ddd30ecf3 (diff) | |
drm/bridge: select_bus_fmt_recursive(): put the bridge obtained by drm_bridge_get_prev_bridge()
The bridge returned by drm_bridge_get_prev_bridge() is refcounted. Put it
when done.
select_bus_fmt_recursive() has several return points, and ensuring
drm_bridge_put() is always called in the right place would be error-prone
(especially with future changes to the select_bus_fmt_recursive() code) and
make code uglier. Instead use a scope-based free, which is future-proof and
a lot cleaner.
Reviewed-by: Maxime Ripard <mripard@kernel.org>
Link: https://lore.kernel.org/r/20250709-drm-bridge-alloc-getput-drm_bridge_get_prev_bridge-v1-2-34ba6f395aaa@bootlin.com
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Diffstat (limited to 'rust/helpers/task.c')
0 files changed, 0 insertions, 0 deletions
