android_kernel_xiaomi_sm8450/drivers/gpu
Bjorn Andersson c67a55f7cc drm/msm/dp: Free resources after unregistering them
[ Upstream commit fa0048a4b1fa7a50c8b0e514f5b428abdf69a6f8 ]

The DP component's unbind operation walks through the submodules to
unregister and clean things up. But if the unbind happens because the DP
controller itself is being removed, all the memory for those submodules
has just been freed.

Change the order of these operations to avoid the many use-after-free
that otherwise happens in this code path.

Fixes: c943b4948b ("drm/msm/dp: add displayPort driver support")
Signed-off-by: Bjorn Andersson <quic_bjorande@quicinc.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Patchwork: https://patchwork.freedesktop.org/patch/542166/
Link: https://lore.kernel.org/r/20230612220259.1884381-1-quic_bjorande@quicinc.com
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-07-27 08:43:54 +02:00
..
drm drm/msm/dp: Free resources after unregistering them 2023-07-27 08:43:54 +02:00
host1x gpu: host1x: Don't skip assigning syncpoints to channels 2023-03-11 16:39:34 +01:00
ipu-v3 gpu: ipu-v3: common: Add of_node_put() for reference returned by of_graph_get_port_by_id() 2023-03-11 16:39:30 +01:00
trace
vga vgaarb: mark vga_tryget static 2020-08-01 11:28:17 +02:00
Makefile