linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] accel/qaic: Remove redundant retry_count = 0 statement
@ 2025-10-07 16:11 Youssef Samir
  2025-10-07 16:53 ` Jeff Hugo
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Youssef Samir @ 2025-10-07 16:11 UTC (permalink / raw)
  To: jeff.hugo, carl.vanderlip, troy.hanson, zachary.mckevitt
  Cc: ogabbay, lizhi.hou, karol.wachowski, linux-arm-msm, dri-devel

From: Youssef Samir <quic_yabdulra@quicinc.com>

If msg_xfer() is called and the channel ring does not have enough room
to accommodate the whole message, the function sleeps and tries again.
It uses retry_count to keep track of the number of retrials done. This
variable is not used after the space check succeeds. So, remove the
retry_count = 0 statement used later in the function.

Signed-off-by: Youssef Samir <quic_yabdulra@quicinc.com>
Signed-off-by: Youssef Samir <youssef.abdulrahman@oss.qualcomm.com>
---
 drivers/accel/qaic/qaic_control.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/accel/qaic/qaic_control.c b/drivers/accel/qaic/qaic_control.c
index d8bdab69f800..5aa49e0e1869 100644
--- a/drivers/accel/qaic/qaic_control.c
+++ b/drivers/accel/qaic/qaic_control.c
@@ -1079,7 +1079,6 @@ static void *msg_xfer(struct qaic_device *qdev, struct wrapper_list *wrappers, u
 
 	list_for_each_entry(w, &wrappers->list, list) {
 		kref_get(&w->ref_count);
-		retry_count = 0;
 		ret = mhi_queue_buf(qdev->cntl_ch, DMA_TO_DEVICE, &w->msg, w->len,
 				    list_is_last(&w->list, &wrappers->list) ? MHI_EOT : MHI_CHAIN);
 		if (ret) {
-- 
2.43.0


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

* Re: [PATCH] accel/qaic: Remove redundant retry_count = 0 statement
  2025-10-07 16:11 [PATCH] accel/qaic: Remove redundant retry_count = 0 statement Youssef Samir
@ 2025-10-07 16:53 ` Jeff Hugo
  2025-10-13 23:17 ` Carl Vanderlip
  2025-10-14 15:11 ` Jeff Hugo
  2 siblings, 0 replies; 4+ messages in thread
From: Jeff Hugo @ 2025-10-07 16:53 UTC (permalink / raw)
  To: Youssef Samir, carl.vanderlip, troy.hanson, zachary.mckevitt
  Cc: ogabbay, lizhi.hou, karol.wachowski, linux-arm-msm, dri-devel

On 10/7/2025 10:11 AM, Youssef Samir wrote:
> From: Youssef Samir <quic_yabdulra@quicinc.com>
> 
> If msg_xfer() is called and the channel ring does not have enough room
> to accommodate the whole message, the function sleeps and tries again.
> It uses retry_count to keep track of the number of retrials done. This
> variable is not used after the space check succeeds. So, remove the
> retry_count = 0 statement used later in the function.
> 
> Signed-off-by: Youssef Samir <quic_yabdulra@quicinc.com>
> Signed-off-by: Youssef Samir <youssef.abdulrahman@oss.qualcomm.com>

Reviewed-by: Jeff Hugo <jeff.hugo@oss.qualcomm.com>

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

* Re: [PATCH] accel/qaic: Remove redundant retry_count = 0 statement
  2025-10-07 16:11 [PATCH] accel/qaic: Remove redundant retry_count = 0 statement Youssef Samir
  2025-10-07 16:53 ` Jeff Hugo
@ 2025-10-13 23:17 ` Carl Vanderlip
  2025-10-14 15:11 ` Jeff Hugo
  2 siblings, 0 replies; 4+ messages in thread
From: Carl Vanderlip @ 2025-10-13 23:17 UTC (permalink / raw)
  To: Youssef Samir, jeff.hugo, troy.hanson, zachary.mckevitt
  Cc: ogabbay, lizhi.hou, karol.wachowski, linux-arm-msm, dri-devel

On 10/7/2025 9:11 AM, Youssef Samir wrote:
> From: Youssef Samir <quic_yabdulra@quicinc.com>
> 
> If msg_xfer() is called and the channel ring does not have enough room
> to accommodate the whole message, the function sleeps and tries again.
> It uses retry_count to keep track of the number of retrials done. This
> variable is not used after the space check succeeds. So, remove the
> retry_count = 0 statement used later in the function.
> 
> Signed-off-by: Youssef Samir <quic_yabdulra@quicinc.com>
> Signed-off-by: Youssef Samir <youssef.abdulrahman@oss.qualcomm.com>
> ---

Reviewed-by: Carl Vanderlip <carl.vanderlip@oss.qualcomm.com>

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

* Re: [PATCH] accel/qaic: Remove redundant retry_count = 0 statement
  2025-10-07 16:11 [PATCH] accel/qaic: Remove redundant retry_count = 0 statement Youssef Samir
  2025-10-07 16:53 ` Jeff Hugo
  2025-10-13 23:17 ` Carl Vanderlip
@ 2025-10-14 15:11 ` Jeff Hugo
  2 siblings, 0 replies; 4+ messages in thread
From: Jeff Hugo @ 2025-10-14 15:11 UTC (permalink / raw)
  To: Youssef Samir, carl.vanderlip, troy.hanson, zachary.mckevitt
  Cc: ogabbay, lizhi.hou, karol.wachowski, linux-arm-msm, dri-devel

On 10/7/2025 10:11 AM, Youssef Samir wrote:
> From: Youssef Samir <quic_yabdulra@quicinc.com>
> 
> If msg_xfer() is called and the channel ring does not have enough room
> to accommodate the whole message, the function sleeps and tries again.
> It uses retry_count to keep track of the number of retrials done. This
> variable is not used after the space check succeeds. So, remove the
> retry_count = 0 statement used later in the function.
> 
> Signed-off-by: Youssef Samir <quic_yabdulra@quicinc.com>
> Signed-off-by: Youssef Samir <youssef.abdulrahman@oss.qualcomm.com>

Pushed to drm-misc-next.

-Jeff

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

end of thread, other threads:[~2025-10-14 15:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-07 16:11 [PATCH] accel/qaic: Remove redundant retry_count = 0 statement Youssef Samir
2025-10-07 16:53 ` Jeff Hugo
2025-10-13 23:17 ` Carl Vanderlip
2025-10-14 15:11 ` Jeff Hugo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).