]> git.baikalelectronics.ru Git - kernel.git/commit
drm/msm/dp: Move debugfs files into subdirectory
authorBjorn Andersson <bjorn.andersson@linaro.org>
Fri, 15 Oct 2021 23:17:02 +0000 (16:17 -0700)
committerDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Fri, 18 Feb 2022 15:32:57 +0000 (18:32 +0300)
commitf5deb96b12bf94c583f0ffc2c4e07e4a6dc341dd
tree8e5d2da866ca783529b466b99641ca795742f028
parent59e766ff6f8c2d0f016dfe97ff01198e0de898dc
drm/msm/dp: Move debugfs files into subdirectory

In the cleanup path of the MSM DP driver the DP driver's debugfs files
are destroyed by invoking debugfs_remove_recursive() on debug->root,
which during initialization has been set to minor->debugfs_root.

To allow cleaning up the DP driver's debugfs files either each dentry
needs to be kept track of or the files needs to be put in a subdirectory
which can be removed in one go.

By choosing to put the debugfs files in a subdirectory, based on the
name of the associated connector this also solves the problem that these
names would collide as support for multiple DP instances are introduced.

One alternative solution to the problem with colliding file names would
have been to put keep track of the individual files and put them under
the connector's debugfs directory. But while the drm_connector has been
allocated, its associated debugfs directory has not been created at the
time of initialization of the dp_debug.

Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Reviewed-by: Abhinav Kumar <quic_abhinavk@quicinc.com>
Link: https://lore.kernel.org/r/20211015231702.1784254-1-bjorn.andersson@linaro.org
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
drivers/gpu/drm/msm/dp/dp_debug.c