public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] RDMA: update outdated references to hfi1_destroy_qp()
@ 2026-03-21 10:58 Kexin Sun
  2026-03-22 18:59 ` Leon Romanovsky
  0 siblings, 1 reply; 4+ messages in thread
From: Kexin Sun @ 2026-03-21 10:58 UTC (permalink / raw)
  To: dennis.dalessandro, jgg, leon, linux-rdma, linux-kernel
  Cc: julia.lawall, xutong.ma, kexinsun, yunbolyu, ratnadiraw

The function hfi1_destroy_qp() was removed in commit
75261cc6ab66 ("staging/rdma/hfi1: Remove destroy qp verb") in
favor of the rdmavt generic rvt_destroy_qp().  Two comments still
reference hfi1_destroy_qp() as the waiter that rvt_put_qp() will
wake up; the actual waiter is now rvt_destroy_qp().  Update both
references.

Assisted-by: unnamed:deepseek-v3.2 coccinelle
Signed-off-by: Kexin Sun <kexinsun@smail.nju.edu.cn>
---
 drivers/infiniband/hw/hfi1/qp.c      | 2 +-
 drivers/infiniband/sw/rdmavt/mcast.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/infiniband/hw/hfi1/qp.c b/drivers/infiniband/hw/hfi1/qp.c
index f3d8c0c193ac..bbb23c0386ee 100644
--- a/drivers/infiniband/hw/hfi1/qp.c
+++ b/drivers/infiniband/hw/hfi1/qp.c
@@ -404,7 +404,7 @@ void hfi1_qp_wakeup(struct rvt_qp *qp, u32 flag)
 		hfi1_qp_schedule(qp);
 	}
 	spin_unlock_irqrestore(&qp->s_lock, flags);
-	/* Notify hfi1_destroy_qp() if it is waiting. */
+	/* Notify rvt_destroy_qp() if it is waiting. */
 	rvt_put_qp(qp);
 }
 
diff --git a/drivers/infiniband/sw/rdmavt/mcast.c b/drivers/infiniband/sw/rdmavt/mcast.c
index 1fda344d2056..c75be2c53b2d 100644
--- a/drivers/infiniband/sw/rdmavt/mcast.c
+++ b/drivers/infiniband/sw/rdmavt/mcast.c
@@ -49,7 +49,7 @@ static void rvt_mcast_qp_free(struct rvt_mcast_qp *mqp)
 {
 	struct rvt_qp *qp = mqp->qp;
 
-	/* Notify hfi1_destroy_qp() if it is waiting. */
+	/* Notify rvt_destroy_qp() if it is waiting. */
 	rvt_put_qp(qp);
 
 	kfree(mqp);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] RDMA: update outdated references to hfi1_destroy_qp()
  2026-03-21 10:58 [PATCH] RDMA: update outdated references to hfi1_destroy_qp() Kexin Sun
@ 2026-03-22 18:59 ` Leon Romanovsky
  2026-03-23 13:44   ` [PATCH v2] RDMA: remove outdated comments referencing hfi1_destroy_qp() Kexin Sun
  0 siblings, 1 reply; 4+ messages in thread
From: Leon Romanovsky @ 2026-03-22 18:59 UTC (permalink / raw)
  To: Kexin Sun
  Cc: dennis.dalessandro, jgg, linux-rdma, linux-kernel, julia.lawall,
	xutong.ma, yunbolyu, ratnadiraw

On Sat, Mar 21, 2026 at 06:58:51PM +0800, Kexin Sun wrote:
> The function hfi1_destroy_qp() was removed in commit
> 75261cc6ab66 ("staging/rdma/hfi1: Remove destroy qp verb") in
> favor of the rdmavt generic rvt_destroy_qp().  Two comments still
> reference hfi1_destroy_qp() as the waiter that rvt_put_qp() will
> wake up; the actual waiter is now rvt_destroy_qp().  Update both
> references.
> 
> Assisted-by: unnamed:deepseek-v3.2 coccinelle
> Signed-off-by: Kexin Sun <kexinsun@smail.nju.edu.cn>
> ---
>  drivers/infiniband/hw/hfi1/qp.c      | 2 +-
>  drivers/infiniband/sw/rdmavt/mcast.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/infiniband/hw/hfi1/qp.c b/drivers/infiniband/hw/hfi1/qp.c
> index f3d8c0c193ac..bbb23c0386ee 100644
> --- a/drivers/infiniband/hw/hfi1/qp.c
> +++ b/drivers/infiniband/hw/hfi1/qp.c
> @@ -404,7 +404,7 @@ void hfi1_qp_wakeup(struct rvt_qp *qp, u32 flag)
>  		hfi1_qp_schedule(qp);
>  	}
>  	spin_unlock_irqrestore(&qp->s_lock, flags);
> -	/* Notify hfi1_destroy_qp() if it is waiting. */
> +	/* Notify rvt_destroy_qp() if it is waiting. */

Just remove these comments, they have no value.

Thanks

>  	rvt_put_qp(qp);
>  }
>  
> diff --git a/drivers/infiniband/sw/rdmavt/mcast.c b/drivers/infiniband/sw/rdmavt/mcast.c
> index 1fda344d2056..c75be2c53b2d 100644
> --- a/drivers/infiniband/sw/rdmavt/mcast.c
> +++ b/drivers/infiniband/sw/rdmavt/mcast.c
> @@ -49,7 +49,7 @@ static void rvt_mcast_qp_free(struct rvt_mcast_qp *mqp)
>  {
>  	struct rvt_qp *qp = mqp->qp;
>  
> -	/* Notify hfi1_destroy_qp() if it is waiting. */
> +	/* Notify rvt_destroy_qp() if it is waiting. */
>  	rvt_put_qp(qp);
>  
>  	kfree(mqp);
> -- 
> 2.25.1
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH v2] RDMA: remove outdated comments referencing hfi1_destroy_qp()
  2026-03-22 18:59 ` Leon Romanovsky
@ 2026-03-23 13:44   ` Kexin Sun
  2026-03-24  5:08     ` Leon Romanovsky
  0 siblings, 1 reply; 4+ messages in thread
From: Kexin Sun @ 2026-03-23 13:44 UTC (permalink / raw)
  To: leon
  Cc: dennis.dalessandro, jgg, linux-rdma, linux-kernel, julia.lawall,
	xutong.ma, yunbolyu, ratnadiraw, Kexin Sun

The function hfi1_destroy_qp() was removed in commit
75261cc6ab66 ("staging/rdma/hfi1: Remove destroy qp verb") in
favor of the rdmavt generic rvt_destroy_qp().  Two comments
still reference hfi1_destroy_qp() as the waiter that
rvt_put_qp() will wake up.  As Leon Romanovsky noted, these
comments add no value.  Remove them.

Suggested-by: Leon Romanovsky <leon@kernel.org>
Assisted-by: unnamed:deepseek-v3.2 coccinelle
Signed-off-by: Kexin Sun <kexinsun@smail.nju.edu.cn>
---
 drivers/infiniband/hw/hfi1/qp.c      | 1 -
 drivers/infiniband/sw/rdmavt/mcast.c | 1 -
 2 files changed, 2 deletions(-)

diff --git a/drivers/infiniband/hw/hfi1/qp.c b/drivers/infiniband/hw/hfi1/qp.c
index f3d8c0c193ac..3a0caee95607 100644
--- a/drivers/infiniband/hw/hfi1/qp.c
+++ b/drivers/infiniband/hw/hfi1/qp.c
@@ -404,7 +404,6 @@ void hfi1_qp_wakeup(struct rvt_qp *qp, u32 flag)
 		hfi1_qp_schedule(qp);
 	}
 	spin_unlock_irqrestore(&qp->s_lock, flags);
-	/* Notify hfi1_destroy_qp() if it is waiting. */
 	rvt_put_qp(qp);
 }
 
diff --git a/drivers/infiniband/sw/rdmavt/mcast.c b/drivers/infiniband/sw/rdmavt/mcast.c
index 1fda344d2056..b41fe4c069dd 100644
--- a/drivers/infiniband/sw/rdmavt/mcast.c
+++ b/drivers/infiniband/sw/rdmavt/mcast.c
@@ -49,7 +49,6 @@ static void rvt_mcast_qp_free(struct rvt_mcast_qp *mqp)
 {
 	struct rvt_qp *qp = mqp->qp;
 
-	/* Notify hfi1_destroy_qp() if it is waiting. */
 	rvt_put_qp(qp);
 
 	kfree(mqp);
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] RDMA: remove outdated comments referencing hfi1_destroy_qp()
  2026-03-23 13:44   ` [PATCH v2] RDMA: remove outdated comments referencing hfi1_destroy_qp() Kexin Sun
@ 2026-03-24  5:08     ` Leon Romanovsky
  0 siblings, 0 replies; 4+ messages in thread
From: Leon Romanovsky @ 2026-03-24  5:08 UTC (permalink / raw)
  To: Kexin Sun
  Cc: dennis.dalessandro, jgg, linux-rdma, linux-kernel, julia.lawall,
	xutong.ma, yunbolyu, ratnadiraw


On Mon, 23 Mar 2026 21:44:50 +0800, Kexin Sun wrote:
> The function hfi1_destroy_qp() was removed in commit
> 75261cc6ab66 ("staging/rdma/hfi1: Remove destroy qp verb") in
> favor of the rdmavt generic rvt_destroy_qp().  Two comments
> still reference hfi1_destroy_qp() as the waiter that
> rvt_put_qp() will wake up.  As Leon Romanovsky noted, these
> comments add no value.  Remove them.
> 
> [...]

Applied, thanks!

[1/1] RDMA: remove outdated comments referencing hfi1_destroy_qp()
      https://git.kernel.org/rdma/rdma/c/05eec2a60c7909

Best regards,
-- 
Leon Romanovsky <leon@kernel.org>


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-03-24  5:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-21 10:58 [PATCH] RDMA: update outdated references to hfi1_destroy_qp() Kexin Sun
2026-03-22 18:59 ` Leon Romanovsky
2026-03-23 13:44   ` [PATCH v2] RDMA: remove outdated comments referencing hfi1_destroy_qp() Kexin Sun
2026-03-24  5:08     ` Leon Romanovsky

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox