Skip to contentSkip to conversation

drm/amdgpu: Correct the parameter name of amdgpu_ring_init

PATCH In review Ma Jun 5 participants 6 messages Mar 22, 2022 – Mar 23, 2022

Subsystems (2)
lore
Share & tools
lore

Ma Jun

author
#0 lore raw

PATCH 1/1 drm/amdgpu: Correct the parameter name of amdgpu_ring_init

Correct the parameter name of amdgpu_ring_init() in header file.

Change-Id I202d76ba04b137926b456b1c8a4c05a5b1a01bff
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h +2 -2
index 5320bb0883d8..317d80209e95 100644
@@ -300,8 +300,8 @@ void amdgpu_ring_generic_pad_ib(struct amdgpu_ring *ring, struct amdgpu_ib *ib);
 void amdgpu_ring_commit(struct amdgpu_ring *ring);
 void amdgpu_ring_undo(struct amdgpu_ring *ring);
 int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
-		     unsigned int ring_size, struct amdgpu_irq_src *irq_src,
-		     unsigned int irq_type, unsigned int prio,
+		     unsigned int max_dw, struct amdgpu_irq_src *irq_src,
+		     unsigned int irq_type, unsigned int hw_prio,
 		     atomic_t *sched_score);
 void amdgpu_ring_fini(struct amdgpu_ring *ring);
 void amdgpu_ring_emit_reg_write_reg_wait_helper(struct amdgpu_ring *ring,
Signature · 1 line
2.25.1
Reviewed-by on v1 1/1
#1 lore raw

Regards,
Guchun

-----Original Message-----
From: amd-gfx <[email protected]> On Behalf Of Ma Jun
Sent: Tuesday, March 22, 2022 8:53 PM
To: [email protected]
Cc: Deucher, Alexander <[email protected]>; Koenig, Christian <[email protected]>; Zhang, Hawking <[email protected]>
Subject: [PATCH] drm/amdgpu: Correct the parameter name of amdgpu_ring_init

Correct the parameter name of amdgpu_ring_init() in header file.

Change-Id I202d76ba04b137926b456b1c8a4c05a5b1a01bff
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h +2 -3
index 5320bb0883d8..317d80209e95 100644
@@ -300,8 +300,8 @@ void amdgpu_ring_generic_pad_ib(struct amdgpu_ring *ring, struct amdgpu_ib *ib);  void amdgpu_ring_commit(struct amdgpu_ring *ring);  void amdgpu_ring_undo(struct amdgpu_ring *ring);  int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
-		     unsigned int ring_size, struct amdgpu_irq_src *irq_src,
-		     unsigned int irq_type, unsigned int prio,
+		     unsigned int max_dw, struct amdgpu_irq_src *irq_src,
+		     unsigned int irq_type, unsigned int hw_prio,
 		     atomic_t *sched_score);
 void amdgpu_ring_fini(struct amdgpu_ring *ring);  void amdgpu_ring_emit_reg_write_reg_wait_helper(struct amdgpu_ring *ring,
--

2.25.1

maintainer
#2 lore raw
In reply to Ma Jun

Am 22.03.22 um 13:53 schrieb Ma Jun:

Quoted 1 line

Correct the parameter name of amdgpu_ring_init() in header file.

Maybe write "Sync up header and implementation to use the same parameter names", otherwise somebody could think that this is a real functional bug fix and backport it.

Quoted 2 lines

With the commit message and subject adjusted the patch is Reviewed-by: Christian König <[email protected]>

Quoted 20 lines

Change-Id: I202d76ba04b137926b456b1c8a4c05a5b1a01bff

---
  drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h +2 -2
index 5320bb0883d8..317d80209e95 100644
@@ -300,8 +300,8 @@ void amdgpu_ring_generic_pad_ib(struct amdgpu_ring *ring, struct amdgpu_ib *ib);
  void amdgpu_ring_commit(struct amdgpu_ring *ring);
  void amdgpu_ring_undo(struct amdgpu_ring *ring);
  int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
-		     unsigned int ring_size, struct amdgpu_irq_src *irq_src,
-		     unsigned int irq_type, unsigned int prio,
+		     unsigned int max_dw, struct amdgpu_irq_src *irq_src,
+		     unsigned int irq_type, unsigned int hw_prio,
  		     atomic_t *sched_score);
  void amdgpu_ring_fini(struct amdgpu_ring *ring);
  void amdgpu_ring_emit_reg_write_reg_wait_helper(struct amdgpu_ring *ring,
#3 lore raw
Quoted 7 lines · Christian König

Am 22.03.22 um 13:53 schrieb Ma Jun:

Quoted 1 line

Correct the parameter name of amdgpu_ring_init() in header file.

Maybe write "Sync up header and implementation to use the same parameter names", otherwise somebody could think that this is a real functional bug fix and backport it.
ok, will fix this in v2

Regards,
Ma Jun

Quoted 27 lines
Quoted 2 lines

With the commit message and subject adjusted the patch is Reviewed-by:
Christian König <[email protected]>

Quoted 20 lines

Change-Id: I202d76ba04b137926b456b1c8a4c05a5b1a01bff

---
  drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h +2 -2
index 5320bb0883d8..317d80209e95 100644
@@ -300,8 +300,8 @@ void amdgpu_ring_generic_pad_ib(struct amdgpu_ring *ring, struct amdgpu_ib *ib);
  void amdgpu_ring_commit(struct amdgpu_ring *ring);
  void amdgpu_ring_undo(struct amdgpu_ring *ring);
  int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
-		     unsigned int ring_size, struct amdgpu_irq_src *irq_src,
-		     unsigned int irq_type, unsigned int prio,
+		     unsigned int max_dw, struct amdgpu_irq_src *irq_src,
+		     unsigned int irq_type, unsigned int hw_prio,
  		     atomic_t *sched_score);
  void amdgpu_ring_fini(struct amdgpu_ring *ring);
  void amdgpu_ring_emit_reg_write_reg_wait_helper(struct amdgpu_ring *ring,
#4 lore raw

Dear Jun,

Thank you for your patch.

Am 23.03.22 um 04:02 schrieb Ma, Jun:

Quoted 8 lines · Christian König
Quoted 7 lines

Am 22.03.22 um 13:53 schrieb Ma Jun:

Quoted 1 line

Correct the parameter name of amdgpu_ring_init() in header file.

Maybe write "Sync up header and implementation to use the same parameter names", otherwise somebody could think that this is a real functional bug fix and backport it.
ok, will fix this in v2

(Your mailer incorrectly quoted your reply sentence, making it look like it was written by Christian.)

If you re-roll the patch, please also mention both parameter names in the commit message, so people do not have to search in the diff for them, and can verify the changes match your intention. (The summary uses singular *name* adding a little confusion.)

Kind regards,

Paul

Quoted 26 lines
Quoted 26 lines
Quoted 1 line

With the commit message and subject adjusted the patch is Reviewed-by:
Christian König <[email protected]>

Quoted 20 lines

Change-Id: I202d76ba04b137926b456b1c8a4c05a5b1a01bff

---
   drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++--
   1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h +2 -2
index 5320bb0883d8..317d80209e95 100644
@@ -300,8 +300,8 @@ void amdgpu_ring_generic_pad_ib(struct amdgpu_ring *ring, struct amdgpu_ib *ib);
   void amdgpu_ring_commit(struct amdgpu_ring *ring);
   void amdgpu_ring_undo(struct amdgpu_ring *ring);
   int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
-		     unsigned int ring_size, struct amdgpu_irq_src *irq_src,
-		     unsigned int irq_type, unsigned int prio,
+		     unsigned int max_dw, struct amdgpu_irq_src *irq_src,
+		     unsigned int irq_type, unsigned int hw_prio,
   		     atomic_t *sched_score);
   void amdgpu_ring_fini(struct amdgpu_ring *ring);
   void amdgpu_ring_emit_reg_write_reg_wait_helper(struct amdgpu_ring *ring,
#5 lore raw
Quoted 16 lines · Paul Menzel

Dear Jun,

Thank you for your patch.

Am 23.03.22 um 04:02 schrieb Ma, Jun:

Quoted 8 lines · Christian König
Quoted 7 lines

Am 22.03.22 um 13:53 schrieb Ma Jun:

Quoted 1 line

Correct the parameter name of amdgpu_ring_init() in header file.

Maybe write "Sync up header and implementation to use the same parameter names", otherwise somebody could think that this is a real functional bug fix and backport it.
ok, will fix this in v2

Quoted 8 lines

(Your mailer incorrectly quoted your reply sentence, making it look like it was written by Christian.)

If you re-roll the patch, please also mention both parameter names in the commit message, so people do not have to search in the diff for them, and can verify the changes match your intention. (The summary uses singular *name* adding a little confusion.)

Good suggestion, thank you.

Regards,
Ma Jun

Quoted 32 lines

Kind regards,

Paul

Quoted 26 lines
Quoted 26 lines
Quoted 1 line

With the commit message and subject adjusted the patch is Reviewed-by:
Christian König <[email protected]>

Quoted 20 lines

Change-Id: I202d76ba04b137926b456b1c8a4c05a5b1a01bff

---
   drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 4 ++--
   1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h +2 -2
index 5320bb0883d8..317d80209e95 100644
@@ -300,8 +300,8 @@ void amdgpu_ring_generic_pad_ib(struct amdgpu_ring *ring, struct amdgpu_ib *ib);
   void amdgpu_ring_commit(struct amdgpu_ring *ring);
   void amdgpu_ring_undo(struct amdgpu_ring *ring);
   int amdgpu_ring_init(struct amdgpu_device *adev, struct amdgpu_ring *ring,
-		     unsigned int ring_size, struct amdgpu_irq_src *irq_src,
-		     unsigned int irq_type, unsigned int prio,
+		     unsigned int max_dw, struct amdgpu_irq_src *irq_src,
+		     unsigned int irq_type, unsigned int hw_prio,
   		     atomic_t *sched_score);
   void amdgpu_ring_fini(struct amdgpu_ring *ring);
   void amdgpu_ring_emit_reg_write_reg_wait_helper(struct amdgpu_ring *ring,