[PATCH] drm/amdgpu: save the funcs of gfx software rings

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

 



From: Trigger Huang <Trigger.Huang@xxxxxxx>

Currently the funcs variable of a gfx software ring is not set. So
if it is visited somewhere, it will lead to error logic being
executed. For example, if we want to call some callbacks in funcs of
a gfx software ring, like per ring reset, it will be failed due to
funcs is NULL.

Signed-off-by: Trigger Huang <Trigger.Huang@xxxxxxx>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ring_mux.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring_mux.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring_mux.c
index d234b7ccfaaf..4dad03a07492 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring_mux.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring_mux.c
@@ -202,6 +202,7 @@ int amdgpu_ring_mux_add_sw_ring(struct amdgpu_ring_mux *mux, struct amdgpu_ring
 
 	e = &mux->ring_entry[mux->num_ring_entries];
 	ring->entry_index = mux->num_ring_entries;
+	ring->funcs = mux->real_ring->funcs;
 	e->ring = ring;
 
 	INIT_LIST_HEAD(&e->list);
-- 
2.34.1




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux