All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nirmoy Das <nirmoy.das@amd.com>
To: <dri-devel@lists.freedesktop.org>
Cc: intel-gfx@lists.freedesktop.org,
	"Nirmoy Das" <nirmoy.das@amd.com>,
	"Alex Deucher" <alexander.deucher@amd.com>,
	"Christian König" <christian.koenig@amd.com>,
	"Pan, Xinhui" <Xinhui.Pan@amd.com>
Subject: [PATCH 3/5] drm/radeon: check dri root before debugfs init
Date: Fri, 8 Oct 2021 11:17:02 +0200	[thread overview]
Message-ID: <20211008091704.27094-3-nirmoy.das@amd.com> (raw)
In-Reply-To: <20211008091704.27094-1-nirmoy.das@amd.com>

Return early if dri minor root dentry is NULL.

CC: Alex Deucher <alexander.deucher@amd.com>
CC: "Christian König" <christian.koenig@amd.com>
CC: "Pan, Xinhui" <Xinhui.Pan@amd.com>

Signed-off-by: Nirmoy Das <nirmoy.das@amd.com>
---
 drivers/gpu/drm/radeon/r100.c          | 9 +++++++++
 drivers/gpu/drm/radeon/r300.c          | 3 +++
 drivers/gpu/drm/radeon/r420.c          | 3 +++
 drivers/gpu/drm/radeon/r600.c          | 3 +++
 drivers/gpu/drm/radeon/radeon_dp_mst.c | 3 +++
 drivers/gpu/drm/radeon/radeon_fence.c  | 3 +++
 drivers/gpu/drm/radeon/radeon_gem.c    | 3 +++
 drivers/gpu/drm/radeon/radeon_ib.c     | 3 +++
 drivers/gpu/drm/radeon/radeon_pm.c     | 5 ++++-
 drivers/gpu/drm/radeon/radeon_ring.c   | 3 +++
 drivers/gpu/drm/radeon/radeon_ttm.c    | 3 +++
 drivers/gpu/drm/radeon/rs400.c         | 3 +++
 drivers/gpu/drm/radeon/rv515.c         | 3 +++
 13 files changed, 46 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/r100.c b/drivers/gpu/drm/radeon/r100.c
index 2dd85ba1faa2..ae6c95b34013 100644
--- a/drivers/gpu/drm/radeon/r100.c
+++ b/drivers/gpu/drm/radeon/r100.c
@@ -3059,6 +3059,9 @@ void  r100_debugfs_rbbm_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r100_rbbm_info", 0444, root, rdev,
 			    &r100_debugfs_rbbm_info_fops);
 #endif
@@ -3069,6 +3072,9 @@ void r100_debugfs_cp_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r100_cp_ring_info", 0444, root, rdev,
 			    &r100_debugfs_cp_ring_info_fops);
 	debugfs_create_file("r100_cp_csq_fifo", 0444, root, rdev,
@@ -3081,6 +3087,9 @@ void  r100_debugfs_mc_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r100_mc_info", 0444, root, rdev,
 			    &r100_debugfs_mc_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/r300.c b/drivers/gpu/drm/radeon/r300.c
index 621ff174dff3..b22969e2394f 100644
--- a/drivers/gpu/drm/radeon/r300.c
+++ b/drivers/gpu/drm/radeon/r300.c
@@ -618,6 +618,9 @@ static void rv370_debugfs_pcie_gart_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("rv370_pcie_gart_info", 0444, root, rdev,
 			    &rv370_debugfs_pcie_gart_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/r420.c b/drivers/gpu/drm/radeon/r420.c
index 7e6320e8c6a0..cdb4ac3e346b 100644
--- a/drivers/gpu/drm/radeon/r420.c
+++ b/drivers/gpu/drm/radeon/r420.c
@@ -494,6 +494,9 @@ void r420_debugfs_pipes_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r420_pipes_info", 0444, root, rdev,
 			    &r420_debugfs_pipes_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/r600.c b/drivers/gpu/drm/radeon/r600.c
index ca3fcae2adb5..d8f525cf0c3b 100644
--- a/drivers/gpu/drm/radeon/r600.c
+++ b/drivers/gpu/drm/radeon/r600.c
@@ -4360,6 +4360,9 @@ static void r600_debugfs_mc_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r600_mc_info", 0444, root, rdev,
 			    &r600_debugfs_mc_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_dp_mst.c b/drivers/gpu/drm/radeon/radeon_dp_mst.c
index ec867fa880a4..cf06da89bb7c 100644
--- a/drivers/gpu/drm/radeon/radeon_dp_mst.c
+++ b/drivers/gpu/drm/radeon/radeon_dp_mst.c
@@ -771,6 +771,9 @@ void radeon_mst_debugfs_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_mst_info", 0444, root, rdev,
 			    &radeon_debugfs_mst_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/radeon/radeon_fence.c
index 73e3117420bf..11f30349de46 100644
--- a/drivers/gpu/drm/radeon/radeon_fence.c
+++ b/drivers/gpu/drm/radeon/radeon_fence.c
@@ -1006,6 +1006,9 @@ void radeon_debugfs_fence_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_gpu_reset", 0444, root, rdev,
 			    &radeon_debugfs_gpu_reset_fops);
 	debugfs_create_file("radeon_fence_info", 0444, root, rdev,
diff --git a/drivers/gpu/drm/radeon/radeon_gem.c b/drivers/gpu/drm/radeon/radeon_gem.c
index 458f92a70887..e6df1451af37 100644
--- a/drivers/gpu/drm/radeon/radeon_gem.c
+++ b/drivers/gpu/drm/radeon/radeon_gem.c
@@ -890,6 +890,9 @@ void radeon_gem_debugfs_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_gem_info", 0444, root, rdev,
 			    &radeon_debugfs_gem_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_ib.c b/drivers/gpu/drm/radeon/radeon_ib.c
index 62b116727b4f..28316eb4fd49 100644
--- a/drivers/gpu/drm/radeon/radeon_ib.c
+++ b/drivers/gpu/drm/radeon/radeon_ib.c
@@ -311,6 +311,9 @@ static void radeon_debugfs_sa_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_sa_info", 0444, root, rdev,
 			    &radeon_debugfs_sa_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/radeon_pm.c b/drivers/gpu/drm/radeon/radeon_pm.c
index c67b6ddb29a4..c09e574d04f0 100644
--- a/drivers/gpu/drm/radeon/radeon_pm.c
+++ b/drivers/gpu/drm/radeon/radeon_pm.c
@@ -1958,6 +1958,9 @@ static void radeon_debugfs_pm_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_pm_info", 0444, root, rdev,
 			    &radeon_debugfs_pm_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_ring.c b/drivers/gpu/drm/radeon/radeon_ring.c
index 7e207276df37..31a5b1ebf7c9 100644
--- a/drivers/gpu/drm/radeon/radeon_ring.c
+++ b/drivers/gpu/drm/radeon/radeon_ring.c
@@ -550,6 +550,9 @@ static void radeon_debugfs_ring_init(struct radeon_device *rdev, struct radeon_r
 	const char *ring_name = radeon_debugfs_ring_idx_to_name(ring->idx);
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	if (ring_name)
 		debugfs_create_file(ring_name, 0444, root, ring,
 				    &radeon_debugfs_ring_info_fops);
diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c
index 11b21d605584..2e18ec93768d 100644
--- a/drivers/gpu/drm/radeon/radeon_ttm.c
+++ b/drivers/gpu/drm/radeon/radeon_ttm.c
@@ -942,6 +942,9 @@ static void radeon_ttm_debugfs_init(struct radeon_device *rdev)
 	struct drm_minor *minor = rdev->ddev->primary;
 	struct dentry *root = minor->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_vram", 0444, root, rdev,
 			    &radeon_ttm_vram_fops);

diff --git a/drivers/gpu/drm/radeon/rs400.c b/drivers/gpu/drm/radeon/rs400.c
index 6383f7a34bd8..b41a903a29c3 100644
--- a/drivers/gpu/drm/radeon/rs400.c
+++ b/drivers/gpu/drm/radeon/rs400.c
@@ -380,6 +380,9 @@ static void rs400_debugfs_pcie_gart_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("rs400_gart_info", 0444, root, rdev,
 			    &rs400_debugfs_gart_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/rv515.c b/drivers/gpu/drm/radeon/rv515.c
index 63fb06e8e2d7..f39b6ab554f2 100644
--- a/drivers/gpu/drm/radeon/rv515.c
+++ b/drivers/gpu/drm/radeon/rv515.c
@@ -257,6 +257,9 @@ void rv515_debugfs(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("rv515_pipes_info", 0444, root, rdev,
 			    &rv515_debugfs_pipes_info_fops);
 	debugfs_create_file("rv515_ga_info", 0444, root, rdev,
--
2.32.0


WARNING: multiple messages have this Message-ID (diff)
From: Nirmoy Das <nirmoy.das@amd.com>
To: <dri-devel@lists.freedesktop.org>
Cc: intel-gfx@lists.freedesktop.org,
	"Nirmoy Das" <nirmoy.das@amd.com>,
	"Alex Deucher" <alexander.deucher@amd.com>,
	"Christian König" <christian.koenig@amd.com>,
	"Pan, Xinhui" <Xinhui.Pan@amd.com>
Subject: [Intel-gfx] [PATCH 3/5] drm/radeon: check dri root before debugfs init
Date: Fri, 8 Oct 2021 11:17:02 +0200	[thread overview]
Message-ID: <20211008091704.27094-3-nirmoy.das@amd.com> (raw)
In-Reply-To: <20211008091704.27094-1-nirmoy.das@amd.com>

Return early if dri minor root dentry is NULL.

CC: Alex Deucher <alexander.deucher@amd.com>
CC: "Christian König" <christian.koenig@amd.com>
CC: "Pan, Xinhui" <Xinhui.Pan@amd.com>

Signed-off-by: Nirmoy Das <nirmoy.das@amd.com>
---
 drivers/gpu/drm/radeon/r100.c          | 9 +++++++++
 drivers/gpu/drm/radeon/r300.c          | 3 +++
 drivers/gpu/drm/radeon/r420.c          | 3 +++
 drivers/gpu/drm/radeon/r600.c          | 3 +++
 drivers/gpu/drm/radeon/radeon_dp_mst.c | 3 +++
 drivers/gpu/drm/radeon/radeon_fence.c  | 3 +++
 drivers/gpu/drm/radeon/radeon_gem.c    | 3 +++
 drivers/gpu/drm/radeon/radeon_ib.c     | 3 +++
 drivers/gpu/drm/radeon/radeon_pm.c     | 5 ++++-
 drivers/gpu/drm/radeon/radeon_ring.c   | 3 +++
 drivers/gpu/drm/radeon/radeon_ttm.c    | 3 +++
 drivers/gpu/drm/radeon/rs400.c         | 3 +++
 drivers/gpu/drm/radeon/rv515.c         | 3 +++
 13 files changed, 46 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/radeon/r100.c b/drivers/gpu/drm/radeon/r100.c
index 2dd85ba1faa2..ae6c95b34013 100644
--- a/drivers/gpu/drm/radeon/r100.c
+++ b/drivers/gpu/drm/radeon/r100.c
@@ -3059,6 +3059,9 @@ void  r100_debugfs_rbbm_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r100_rbbm_info", 0444, root, rdev,
 			    &r100_debugfs_rbbm_info_fops);
 #endif
@@ -3069,6 +3072,9 @@ void r100_debugfs_cp_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r100_cp_ring_info", 0444, root, rdev,
 			    &r100_debugfs_cp_ring_info_fops);
 	debugfs_create_file("r100_cp_csq_fifo", 0444, root, rdev,
@@ -3081,6 +3087,9 @@ void  r100_debugfs_mc_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r100_mc_info", 0444, root, rdev,
 			    &r100_debugfs_mc_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/r300.c b/drivers/gpu/drm/radeon/r300.c
index 621ff174dff3..b22969e2394f 100644
--- a/drivers/gpu/drm/radeon/r300.c
+++ b/drivers/gpu/drm/radeon/r300.c
@@ -618,6 +618,9 @@ static void rv370_debugfs_pcie_gart_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("rv370_pcie_gart_info", 0444, root, rdev,
 			    &rv370_debugfs_pcie_gart_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/r420.c b/drivers/gpu/drm/radeon/r420.c
index 7e6320e8c6a0..cdb4ac3e346b 100644
--- a/drivers/gpu/drm/radeon/r420.c
+++ b/drivers/gpu/drm/radeon/r420.c
@@ -494,6 +494,9 @@ void r420_debugfs_pipes_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r420_pipes_info", 0444, root, rdev,
 			    &r420_debugfs_pipes_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/r600.c b/drivers/gpu/drm/radeon/r600.c
index ca3fcae2adb5..d8f525cf0c3b 100644
--- a/drivers/gpu/drm/radeon/r600.c
+++ b/drivers/gpu/drm/radeon/r600.c
@@ -4360,6 +4360,9 @@ static void r600_debugfs_mc_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("r600_mc_info", 0444, root, rdev,
 			    &r600_debugfs_mc_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_dp_mst.c b/drivers/gpu/drm/radeon/radeon_dp_mst.c
index ec867fa880a4..cf06da89bb7c 100644
--- a/drivers/gpu/drm/radeon/radeon_dp_mst.c
+++ b/drivers/gpu/drm/radeon/radeon_dp_mst.c
@@ -771,6 +771,9 @@ void radeon_mst_debugfs_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_mst_info", 0444, root, rdev,
 			    &radeon_debugfs_mst_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/radeon/radeon_fence.c
index 73e3117420bf..11f30349de46 100644
--- a/drivers/gpu/drm/radeon/radeon_fence.c
+++ b/drivers/gpu/drm/radeon/radeon_fence.c
@@ -1006,6 +1006,9 @@ void radeon_debugfs_fence_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_gpu_reset", 0444, root, rdev,
 			    &radeon_debugfs_gpu_reset_fops);
 	debugfs_create_file("radeon_fence_info", 0444, root, rdev,
diff --git a/drivers/gpu/drm/radeon/radeon_gem.c b/drivers/gpu/drm/radeon/radeon_gem.c
index 458f92a70887..e6df1451af37 100644
--- a/drivers/gpu/drm/radeon/radeon_gem.c
+++ b/drivers/gpu/drm/radeon/radeon_gem.c
@@ -890,6 +890,9 @@ void radeon_gem_debugfs_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_gem_info", 0444, root, rdev,
 			    &radeon_debugfs_gem_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_ib.c b/drivers/gpu/drm/radeon/radeon_ib.c
index 62b116727b4f..28316eb4fd49 100644
--- a/drivers/gpu/drm/radeon/radeon_ib.c
+++ b/drivers/gpu/drm/radeon/radeon_ib.c
@@ -311,6 +311,9 @@ static void radeon_debugfs_sa_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_sa_info", 0444, root, rdev,
 			    &radeon_debugfs_sa_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/radeon_pm.c b/drivers/gpu/drm/radeon/radeon_pm.c
index c67b6ddb29a4..c09e574d04f0 100644
--- a/drivers/gpu/drm/radeon/radeon_pm.c
+++ b/drivers/gpu/drm/radeon/radeon_pm.c
@@ -1958,6 +1958,9 @@ static void radeon_debugfs_pm_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_pm_info", 0444, root, rdev,
 			    &radeon_debugfs_pm_info_fops);

diff --git a/drivers/gpu/drm/radeon/radeon_ring.c b/drivers/gpu/drm/radeon/radeon_ring.c
index 7e207276df37..31a5b1ebf7c9 100644
--- a/drivers/gpu/drm/radeon/radeon_ring.c
+++ b/drivers/gpu/drm/radeon/radeon_ring.c
@@ -550,6 +550,9 @@ static void radeon_debugfs_ring_init(struct radeon_device *rdev, struct radeon_r
 	const char *ring_name = radeon_debugfs_ring_idx_to_name(ring->idx);
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	if (ring_name)
 		debugfs_create_file(ring_name, 0444, root, ring,
 				    &radeon_debugfs_ring_info_fops);
diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c
index 11b21d605584..2e18ec93768d 100644
--- a/drivers/gpu/drm/radeon/radeon_ttm.c
+++ b/drivers/gpu/drm/radeon/radeon_ttm.c
@@ -942,6 +942,9 @@ static void radeon_ttm_debugfs_init(struct radeon_device *rdev)
 	struct drm_minor *minor = rdev->ddev->primary;
 	struct dentry *root = minor->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("radeon_vram", 0444, root, rdev,
 			    &radeon_ttm_vram_fops);

diff --git a/drivers/gpu/drm/radeon/rs400.c b/drivers/gpu/drm/radeon/rs400.c
index 6383f7a34bd8..b41a903a29c3 100644
--- a/drivers/gpu/drm/radeon/rs400.c
+++ b/drivers/gpu/drm/radeon/rs400.c
@@ -380,6 +380,9 @@ static void rs400_debugfs_pcie_gart_info_init(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("rs400_gart_info", 0444, root, rdev,
 			    &rs400_debugfs_gart_info_fops);
 #endif
diff --git a/drivers/gpu/drm/radeon/rv515.c b/drivers/gpu/drm/radeon/rv515.c
index 63fb06e8e2d7..f39b6ab554f2 100644
--- a/drivers/gpu/drm/radeon/rv515.c
+++ b/drivers/gpu/drm/radeon/rv515.c
@@ -257,6 +257,9 @@ void rv515_debugfs(struct radeon_device *rdev)
 #if defined(CONFIG_DEBUG_FS)
 	struct dentry *root = rdev->ddev->primary->debugfs_root;

+	if (!root)
+		return;
+
 	debugfs_create_file("rv515_pipes_info", 0444, root, rdev,
 			    &rv515_debugfs_pipes_info_fops);
 	debugfs_create_file("rv515_ga_info", 0444, root, rdev,
--
2.32.0


  parent reply	other threads:[~2021-10-08  9:17 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-08  9:17 [PATCH 1/5] dri: cleanup debugfs error handling Nirmoy Das
2021-10-08  9:17 ` [Intel-gfx] " Nirmoy Das
2021-10-08  9:17 ` [PATCH 2/5] drm/i915: check dri root before debugfs init Nirmoy Das
2021-10-08  9:17   ` [Intel-gfx] " Nirmoy Das
2021-10-12  9:59   ` Wang, Zhi A
2021-10-12  9:59     ` [Intel-gfx] " Wang, Zhi A
2021-10-12 10:19     ` Das, Nirmoy
2021-10-12 10:19       ` [Intel-gfx] " Das, Nirmoy
2021-10-08  9:17 ` Nirmoy Das [this message]
2021-10-08  9:17   ` [Intel-gfx] [PATCH 3/5] drm/radeon: " Nirmoy Das
2021-10-08 10:23   ` Christian König
2021-10-08 10:23     ` [Intel-gfx] " Christian König
2021-10-08 10:34     ` Das, Nirmoy
2021-10-08 10:34       ` [Intel-gfx] " Das, Nirmoy
2021-10-08  9:17 ` [PATCH 4/5] drm/armada: check dri/crtc " Nirmoy Das
2021-10-08  9:17   ` [Intel-gfx] " Nirmoy Das
2021-10-12 19:40   ` kernel test robot
2021-10-12 19:40     ` kernel test robot
2021-10-12 19:40     ` [Intel-gfx] " kernel test robot
2021-10-08  9:17 ` [PATCH 5/5] drm/tegra: check root dentry " Nirmoy Das
2021-10-08  9:17   ` [Intel-gfx] " Nirmoy Das
2021-11-08  6:35   ` kernel test robot
2021-11-08  6:35     ` kernel test robot
2021-11-08  6:35     ` [Intel-gfx] " kernel test robot
2021-10-08  9:35 ` [PATCH 1/5] dri: cleanup debugfs error handling Thomas Zimmermann
2021-10-08  9:35   ` [Intel-gfx] " Thomas Zimmermann
2021-10-08  9:40 ` Jani Nikula
2021-10-08 11:07   ` Greg KH
2021-10-08 12:08     ` Das, Nirmoy
     [not found]     ` <02fc9da3-ebac-2df1-3a54-d764b273f91b@amd.com>
2021-10-08 12:56       ` Fw: " Das, Nirmoy
     [not found]         ` <c4f1464d-19b6-04a3-e2d8-a153bfbb050a@amd.com>
     [not found]           ` <YWBfvILqkBQ8VSYc@kroah.com>
2021-10-11 14:19             ` Christian König
2021-10-11 14:53               ` Greg KH
2021-10-11 16:38                 ` Jani Nikula
2021-10-11 17:07                   ` Greg KH
2021-10-11 18:43                     ` Jani Nikula
2021-10-11 15:13               ` Das, Nirmoy
2021-10-08 14:09 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/5] " Patchwork
2021-10-08 14:10 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2021-10-08 19:18 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211008091704.27094-3-nirmoy.das@amd.com \
    --to=nirmoy.das@amd.com \
    --cc=Xinhui.Pan@amd.com \
    --cc=alexander.deucher@amd.com \
    --cc=christian.koenig@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.