Patch "RDMA/siw: Add sendpage_ok() check to disable MSG_SPLICE_PAGES" has been added to the 6.6-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    RDMA/siw: Add sendpage_ok() check to disable MSG_SPLICE_PAGES

to the 6.6-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     rdma-siw-add-sendpage_ok-check-to-disable-msg_splice.patch
and it can be found in the queue-6.6 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 0cd25eff2668797c78098187dd616b6e300701bf
Author: Showrya M N <showrya@xxxxxxxxxxx>
Date:   Mon Oct 7 18:28:36 2024 +0530

    RDMA/siw: Add sendpage_ok() check to disable MSG_SPLICE_PAGES
    
    [ Upstream commit 4e1e3dd88a4cedd5ccc1a3fc3d71e03b70a7a791 ]
    
    While running ISER over SIW, the initiator machine encounters a warning
    from skb_splice_from_iter() indicating that a slab page is being used in
    send_page. To address this, it is better to add a sendpage_ok() check
    within the driver itself, and if it returns 0, then MSG_SPLICE_PAGES flag
    should be disabled before entering the network stack.
    
    A similar issue has been discussed for NVMe in this thread:
    https://lore.kernel.org/all/20240530142417.146696-1-ofir.gal@xxxxxxxxxxx/
    
      WARNING: CPU: 0 PID: 5342 at net/core/skbuff.c:7140 skb_splice_from_iter+0x173/0x320
      Call Trace:
       tcp_sendmsg_locked+0x368/0xe40
       siw_tx_hdt+0x695/0xa40 [siw]
       siw_qp_sq_process+0x102/0xb00 [siw]
       siw_sq_resume+0x39/0x110 [siw]
       siw_run_sq+0x74/0x160 [siw]
       kthread+0xd2/0x100
       ret_from_fork+0x34/0x40
       ret_from_fork_asm+0x1a/0x30
    
    Link: https://patch.msgid.link/r/20241007125835.89942-1-showrya@xxxxxxxxxxx
    Signed-off-by: Showrya M N <showrya@xxxxxxxxxxx>
    Signed-off-by: Potnuri Bharat Teja <bharat@xxxxxxxxxxx>
    Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/infiniband/sw/siw/siw_qp_tx.c b/drivers/infiniband/sw/siw/siw_qp_tx.c
index 60b6a41359611..feae920784be8 100644
--- a/drivers/infiniband/sw/siw/siw_qp_tx.c
+++ b/drivers/infiniband/sw/siw/siw_qp_tx.c
@@ -337,6 +337,8 @@ static int siw_tcp_sendpages(struct socket *s, struct page **page, int offset,
 			msg.msg_flags &= ~MSG_MORE;
 
 		tcp_rate_check_app_limited(sk);
+		if (!sendpage_ok(page[i]))
+			msg.msg_flags &= ~MSG_SPLICE_PAGES;
 		bvec_set_page(&bvec, page[i], bytes, offset);
 		iov_iter_bvec(&msg.msg_iter, ITER_SOURCE, &bvec, 1, size);
 




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux