[merged mm-nonmm-stable] rdma-cxgb4-remove-dead-null-checks-after-gfp_nofail-allocations.patch removed from -mm tree

Andrew Morton <[email protected]> Mon, 03 Aug 2026 21:06:09 -0700
Newsgroups org.kernel.vger.mm-commits
Message-ID <[email protected]>
The quilt patch titled
     Subject: RDMA/cxgb4: remove dead NULL checks after GFP_NOFAIL allocations
has been removed from the -mm tree.  Its filename was
     rdma-cxgb4-remove-dead-null-checks-after-gfp_nofail-allocations.patch

This patch was dropped because it was merged into the mm-nonmm-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Gou Hao <[email protected]>
Subject: RDMA/cxgb4: remove dead NULL checks after GFP_NOFAIL allocations
Date: Fri, 24 Jul 2026 10:28:51 +0800

alloc_skb() with the __GFP_NOFAIL flag will never return NULL, so the
subsequent NULL checks and error handling are unreachable dead code. 
Remove them.

Link: https://lore.kernel.org/[email protected]
Signed-off-by: Gou Hao <[email protected]>
Cc: Bharat Potnuri <[email protected]>
Cc: Cédric Le Goater <[email protected]>
Cc: Dave Airlie <[email protected]>
Cc: Jason Gunthorpe <[email protected]>
Cc: jiazhenyuan <[email protected]>
Cc: Leon Romanovsky <[email protected]>
Cc: Maarten Lankhorst <[email protected]>
Cc: Madhavan Srinivasan <[email protected]>
Cc: Maxime Ripard <[email protected]>
Cc: Michael Ellerman <[email protected]>
Cc: Nam Cao <[email protected]>
Cc: Nicholas Piggin <[email protected]>
Cc: Nilay Shroff <[email protected]>
Cc: Shrikanth Hegde <[email protected]>
Cc: Thomas Zimemrmann <[email protected]>
Cc: Wentao Guan <[email protected]>
Cc: Alistair Popple <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
---

 drivers/infiniband/hw/cxgb4/mem.c |   10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

--- a/drivers/infiniband/hw/cxgb4/mem.c~rdma-cxgb4-remove-dead-null-checks-after-gfp_nofail-allocations
+++ a/drivers/infiniband/hw/cxgb4/mem.c
@@ -74,11 +74,8 @@ static int _c4iw_write_mem_dma_aligned(s
 		c4iw_init_wr_wait(wr_waitp);
 	wr_len = roundup(sizeof(*req) + sizeof(*sgl), 16);
 
-	if (!skb) {
+	if (!skb)
 		skb = alloc_skb(wr_len, GFP_KERNEL | __GFP_NOFAIL);
-		if (!skb)
-			return -ENOMEM;
-	}
 	set_wr_txq(skb, CPL_PRIORITY_CONTROL, 0);
 
 	req = __skb_put_zero(skb, wr_len);
@@ -134,11 +131,8 @@ static int _c4iw_write_mem_inline(struct
 					 roundup(copy_len, T4_ULPTX_MIN_IO),
 				 16);
 
-		if (!skb) {
+		if (!skb)
 			skb = alloc_skb(wr_len, GFP_KERNEL | __GFP_NOFAIL);
-			if (!skb)
-				return -ENOMEM;
-		}
 		set_wr_txq(skb, CPL_PRIORITY_CONTROL, 0);
 
 		req = __skb_put_zero(skb, wr_len);
_

Patches currently in -mm which might be from [email protected] are