drm/debugfs: disallow debugfs access when device isn't registered
authorChristian König <ckoenig.leichtzumerken@gmail.com>
Tue, 29 Aug 2023 11:01:12 +0000 (13:01 +0200)
committerChristian König <christian.koenig@amd.com>
Thu, 31 Aug 2023 15:00:37 +0000 (17:00 +0200)
commit7a0f217899a1005c8788c768a766dd435ce1c413
tree0506b9f545eb7cf5ded33cf4c3bf00528b0de6e1
parente76e7ec8f16259ff9167ab665eaee0d0fe20f805
drm/debugfs: disallow debugfs access when device isn't registered

During device bringup it might be that we can't access the debugfs files.
Return -ENODEV until the registration is completed on access.

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230829110115.3442-3-christian.koenig@amd.com
drivers/gpu/drm/drm_debugfs.c