Re: [PATCH 04/19] drm/amd/amdgpu: Remove drm_debugfs_remove_files() call

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am 26.01.2017 um 23:56 schrieb Noralf Trønnes:
drm_debugfs_cleanup() now removes all minor->debugfs_list entries
automatically, so no need to call drm_debugfs_remove_files().
Also remove empty drm_driver.debugfs_cleanup callback.

Cc: alexander.deucher@xxxxxxx
Cc: christian.koenig@xxxxxxx
Signed-off-by: Noralf Trønnes <noralf@xxxxxxxxxxx>

Everything said for Radeon applies here as well.

Just let me know if you want to do the additional cleanup patches or if we should be taking care of that.

This patch is Reviewed-by: Christian König <christian.koenig@xxxxxxx> for now.

Regards,
Christian.

---
  drivers/gpu/drm/amd/amdgpu/amdgpu.h        |  1 -
  drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 20 --------------------
  drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c    |  1 -
  3 files changed, 22 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
index f4f371f..73863d4 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
@@ -1133,7 +1133,6 @@ int amdgpu_debugfs_fence_init(struct amdgpu_device *adev);
#if defined(CONFIG_DEBUG_FS)
  int amdgpu_debugfs_init(struct drm_minor *minor);
-void amdgpu_debugfs_cleanup(struct drm_minor *minor);
  #endif
int amdgpu_debugfs_firmware_init(struct amdgpu_device *adev);
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
index fe3bb94..2201303 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
@@ -1852,8 +1852,6 @@ int amdgpu_device_init(struct amdgpu_device *adev,
  	return r;
  }
-static void amdgpu_debugfs_remove_files(struct amdgpu_device *adev);
-
  /**
   * amdgpu_device_fini - tear down the driver
   *
@@ -1893,7 +1891,6 @@ void amdgpu_device_fini(struct amdgpu_device *adev)
  	if (adev->asic_type >= CHIP_BONAIRE)
  		amdgpu_doorbell_fini(adev);
  	amdgpu_debugfs_regs_cleanup(adev);
-	amdgpu_debugfs_remove_files(adev);
  }
@@ -2507,19 +2504,6 @@ int amdgpu_debugfs_add_files(struct amdgpu_device *adev,
  	return 0;
  }
-static void amdgpu_debugfs_remove_files(struct amdgpu_device *adev)
-{
-#if defined(CONFIG_DEBUG_FS)
-	unsigned i;
-
-	for (i = 0; i < adev->debugfs_count; i++) {
-		drm_debugfs_remove_files(adev->debugfs[i].files,
-					 adev->debugfs[i].num_files,
-					 adev->ddev->primary);
-	}
-#endif
-}
-
  #if defined(CONFIG_DEBUG_FS)
static ssize_t amdgpu_debugfs_regs_read(struct file *f, char __user *buf,
@@ -3153,10 +3137,6 @@ int amdgpu_debugfs_init(struct drm_minor *minor)
  {
  	return 0;
  }
-
-void amdgpu_debugfs_cleanup(struct drm_minor *minor)
-{
-}
  #else
  static int amdgpu_debugfs_regs_init(struct amdgpu_device *adev)
  {
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
index 2534ada..51cfea7 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c
@@ -701,7 +701,6 @@ static struct drm_driver kms_driver = {
  	.get_scanout_position = amdgpu_get_crtc_scanoutpos,
  #if defined(CONFIG_DEBUG_FS)
  	.debugfs_init = amdgpu_debugfs_init,
-	.debugfs_cleanup = amdgpu_debugfs_cleanup,
  #endif
  	.irq_preinstall = amdgpu_irq_preinstall,
  	.irq_postinstall = amdgpu_irq_postinstall,


_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux