diff options
| author | Mark Brown <broonie@kernel.org> | 2025-05-07 09:47:05 +0900 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2025-05-07 09:47:05 +0900 |
| commit | 9fbae052f6f68056fd84e8ba096a7e9ab3464f3d (patch) | |
| tree | 9761fe612792d8c4e67c5da66fa5258e7c0c13fe /drivers/gpu/drm/drm_file.c | |
| parent | 222a87f6b94f6f177e896d6fcdc7881480344e34 (diff) | |
| parent | 9f7cd1bcb6363368abc954ff4e727b579813c697 (diff) | |
This patch set did some clean up and add runtime pm
Merge series from Haibo Chen <haibo.chen@nxp.com>:
PATCH1/3/4 to clean up the code, make the code more readable
PATCH2 add the runtime pm support
PATCH5 use devm_add_action_or_reset() to replace remove() callback, this can avoid
oops when do bind/unbind test
Diffstat (limited to 'drivers/gpu/drm/drm_file.c')
| -rw-r--r-- | drivers/gpu/drm/drm_file.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpu/drm/drm_file.c b/drivers/gpu/drm/drm_file.c index c299cd94d3f7..cf2463090d3a 100644 --- a/drivers/gpu/drm/drm_file.c +++ b/drivers/gpu/drm/drm_file.c @@ -964,6 +964,10 @@ void drm_show_fdinfo(struct seq_file *m, struct file *f) struct drm_file *file = f->private_data; struct drm_device *dev = file->minor->dev; struct drm_printer p = drm_seq_file_printer(m); + int idx; + + if (!drm_dev_enter(dev, &idx)) + return; drm_printf(&p, "drm-driver:\t%s\n", dev->driver->name); drm_printf(&p, "drm-client-id:\t%llu\n", file->client_id); @@ -983,6 +987,8 @@ void drm_show_fdinfo(struct seq_file *m, struct file *f) if (dev->driver->show_fdinfo) dev->driver->show_fdinfo(&p, file); + + drm_dev_exit(idx); } EXPORT_SYMBOL(drm_show_fdinfo); |