[PATCH RFT 2/2] drm/bridge: ti-sn65dsi86: Use per-client debugfs entry
Wolfram Sang
wsa+renesas at sang-engineering.com
Sat Jan 25 12:53:22 UTC 2025
The I2C core now offers a debugfs-directory per client. Use it and
remove the custom handling.
Signed-off-by: Wolfram Sang <wsa+renesas at sang-engineering.com>
---
drivers/gpu/drm/bridge/ti-sn65dsi86.c | 29 +--------------------------
1 file changed, 1 insertion(+), 28 deletions(-)
diff --git a/drivers/gpu/drm/bridge/ti-sn65dsi86.c b/drivers/gpu/drm/bridge/ti-sn65dsi86.c
index e4d9006b59f1..57a3f592c057 100644
--- a/drivers/gpu/drm/bridge/ti-sn65dsi86.c
+++ b/drivers/gpu/drm/bridge/ti-sn65dsi86.c
@@ -427,33 +427,6 @@ static int status_show(struct seq_file *s, void *data)
DEFINE_SHOW_ATTRIBUTE(status);
-static void ti_sn65dsi86_debugfs_remove(void *data)
-{
- debugfs_remove_recursive(data);
-}
-
-static void ti_sn65dsi86_debugfs_init(struct ti_sn65dsi86 *pdata)
-{
- struct device *dev = pdata->dev;
- struct dentry *debugfs;
- int ret;
-
- debugfs = debugfs_create_dir(dev_name(dev), NULL);
-
- /*
- * We might get an error back if debugfs wasn't enabled in the kernel
- * so let's just silently return upon failure.
- */
- if (IS_ERR_OR_NULL(debugfs))
- return;
-
- ret = devm_add_action_or_reset(dev, ti_sn65dsi86_debugfs_remove, debugfs);
- if (ret)
- return;
-
- debugfs_create_file("status", 0600, debugfs, pdata, &status_fops);
-}
-
/* -----------------------------------------------------------------------------
* Auxiliary Devices (*not* AUX)
*/
@@ -1936,7 +1909,7 @@ static int ti_sn65dsi86_probe(struct i2c_client *client)
if (ret)
return ret;
- ti_sn65dsi86_debugfs_init(pdata);
+ debugfs_create_file("status", 0600, client->debugfs, pdata, &status_fops);
/*
* Break ourselves up into a collection of aux devices. The only real
--
2.45.2
More information about the dri-devel
mailing list