* [PATCH v2] raw/ntb: immediate return if no doorbells
@ 2025-07-31 18:31 Tofig Aliev
2025-09-24 14:34 ` Thomas Monjalon
0 siblings, 1 reply; 2+ messages in thread
From: Tofig Aliev @ 2025-07-31 18:31 UTC (permalink / raw)
To: jingjing.wu; +Cc: dev, Tofig Aliev
Added immediate return from ntb_dev_intr_handler()
if no doorbells.
Signed-off-by: Tofig Aliev <t.aliev.mnt@gmail.com>
---
Changes in v2:
Fixed incorrect patch file.
---
drivers/raw/ntb/ntb.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/raw/ntb/ntb.c b/drivers/raw/ntb/ntb.c
index 0ed4c14592..e298820e5f 100644
--- a/drivers/raw/ntb/ntb.c
+++ b/drivers/raw/ntb/ntb.c
@@ -158,8 +158,10 @@ ntb_dev_intr_handler(void *param)
}
db_bits = (*hw->ntb_ops->db_read)(dev);
- if (!db_bits)
+ if (!db_bits) {
NTB_LOG(ERR, "No doorbells");
+ return;
+ }
/* Doorbell 0 is for peer device ready. */
if (db_bits & 1) {
--
2.43.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH v2] raw/ntb: immediate return if no doorbells
2025-07-31 18:31 [PATCH v2] raw/ntb: immediate return if no doorbells Tofig Aliev
@ 2025-09-24 14:34 ` Thomas Monjalon
0 siblings, 0 replies; 2+ messages in thread
From: Thomas Monjalon @ 2025-09-24 14:34 UTC (permalink / raw)
To: Tofig Aliev; +Cc: jingjing.wu, dev, Bruce Richardson
31/07/2025 20:31, Tofig Aliev:
> Added immediate return from ntb_dev_intr_handler()
> if no doorbells.
Please could you explain the consequence of this bug?
Should it be backported?
[...
> @@ -158,8 +158,10 @@ ntb_dev_intr_handler(void *param)
> }
>
> db_bits = (*hw->ntb_ops->db_read)(dev);
> - if (!db_bits)
> + if (!db_bits) {
> NTB_LOG(ERR, "No doorbells");
> + return;
> + }
>
> /* Doorbell 0 is for peer device ready. */
> if (db_bits & 1) {
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-09-24 14:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-07-31 18:31 [PATCH v2] raw/ntb: immediate return if no doorbells Tofig Aliev
2025-09-24 14:34 ` Thomas Monjalon
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).