Skip to content
Snippets Groups Projects
Commit 6914968a authored by Dmitry Baryshkov's avatar Dmitry Baryshkov
Browse files

drm/bridge: properly refcount DT nodes in aux bridge drivers


The aux-bridge and aux-hpd-bridge drivers didn't call of_node_get() on
the device nodes further used for dev->of_node and platform data. When
bridge devices are released, the reference counts are decreased,
resulting in refcount underflow / use-after-free warnings. Get
corresponding refcounts during AUX bridge allocation.

Reported-by: default avatarLuca Weiss <luca.weiss@fairphone.com>
Fixes: 2a047391 ("drm/bridge: add transparent bridge helper")
Fixes: 26f4bac3 ("drm/bridge: aux-hpd: Replace of_device.h with explicit include")
Reviewed-by: default avatarNeil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: default avatarDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20231216235910.911958-1-dmitry.baryshkov@linaro.org


Signed-off-by: default avatarDmitry Baryshkov <dmitry.baryshkov@linaro.org>
parent 8a53e29f
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment