mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/3] rpmsg: glink: smem: robustness and debuggability fixes
@ 2026-06-03 10:14 Chunkai Deng
  2026-06-03 10:14 ` [PATCH 1/3] rpmsg: glink: smem: Use device name as IRQ name Chunkai Deng
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Chunkai Deng @ 2026-06-03 10:14 UTC (permalink / raw)
  To: Bjorn Andersson, Mathieu Poirier
  Cc: linux-arm-msm, linux-remoteproc, linux-kernel, Chunkai Deng

This series makes three small improvements to the SMEM GLINK transport:

1. Use modulo instead of subtraction for FIFO tail wrap-around in
   rx_advance, so the index is always normalised back into [0, length)
   regardless of the advance count.

2. Add WARN_ON_ONCE checks in the FIFO read/write helpers to catch and
   report broken index invariants early, rather than proceeding with an
   out-of-bounds offset into the FIFO.

3. Pass dev_name(&smem->dev) as the IRQ name instead of the static string
   "glink-smem". On platforms with multiple remoteprocs each SMEM GLINK
   instance registers its own IRQ, and the unique device name makes each
   entry in /proc/interrupts identifiable without adding a new struct field.

Signed-off-by: Chunkai Deng <chunkai.deng@oss.qualcomm.com>
---
Chunkai Deng (3):
      rpmsg: glink: smem: Use device name as IRQ name
      rpmsg: glink: smem: Add WARN_ON_ONCE for FIFO index invariants
      rpmsg: glink: smem: Use modulo for FIFO tail wrap-around in rx_advance

 drivers/rpmsg/qcom_glink_smem.c | 22 ++++++++++++++++++----
 1 file changed, 18 insertions(+), 4 deletions(-)
---
base-commit: f7af91adc230aa99e23330ecf85bc9badd9780ad
change-id: 20260601-rpmsg-improvements-643a6e133f66

Best regards,
--  
Chunkai Deng <chunkai.deng@oss.qualcomm.com>


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

end of thread, other threads:[~2026-06-17 10:28 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-06-03 10:14 [PATCH 0/3] rpmsg: glink: smem: robustness and debuggability fixes Chunkai Deng
2026-06-03 10:14 ` [PATCH 1/3] rpmsg: glink: smem: Use device name as IRQ name Chunkai Deng
2026-06-03 11:59   ` Dmitry Baryshkov
2026-06-03 10:14 ` [PATCH 2/3] rpmsg: glink: smem: Add WARN_ON_ONCE for FIFO index invariants Chunkai Deng
2026-06-03 12:00   ` Dmitry Baryshkov
2026-06-03 10:14 ` [PATCH 3/3] rpmsg: glink: smem: Use modulo for FIFO tail wrap-around in rx_advance Chunkai Deng
2026-06-03 12:01   ` Dmitry Baryshkov
2026-06-17 10:28     ` Chunkai Deng
2026-06-14 22:54   ` Bjorn Andersson
2026-06-17 10:20     ` Chunkai Deng

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

all inboxes | Powered by JetHome®