From: Greg Kroah-Hartman Date: Tue, 3 Feb 2026 12:51:25 +0000 (+0100) Subject: 5.10-stable patches X-Git-Tag: v5.10.249~46 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3f3f59b2aa4e52bf0de7f4339e28f22e6a842a0f;p=thirdparty%2Fkernel%2Fstable-queue.git 5.10-stable patches added patches: scsi-be2iscsi-fix-a-memory-leak-in-beiscsi_boot_get_sinfo.patch --- diff --git a/queue-5.10/dma-pool-distinguish-between-missing-and-exhausted-a.patch b/queue-5.10/dma-pool-distinguish-between-missing-and-exhausted-a.patch index c6d965b320..0416b65b15 100644 --- a/queue-5.10/dma-pool-distinguish-between-missing-and-exhausted-a.patch +++ b/queue-5.10/dma-pool-distinguish-between-missing-and-exhausted-a.patch @@ -34,14 +34,12 @@ Signed-off-by: Marek Szyprowski Link: https://lore.kernel.org/r/20260128133554.3056582-1-s-adivi@ti.com Signed-off-by: Sasha Levin --- - kernel/dma/pool.c | 7 ++++++- + kernel/dma/pool.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) -diff --git a/kernel/dma/pool.c b/kernel/dma/pool.c -index 32efef1660096..484050de72fd4 100644 --- a/kernel/dma/pool.c +++ b/kernel/dma/pool.c -@@ -271,15 +271,20 @@ struct page *dma_alloc_from_pool(struct device *dev, size_t size, +@@ -271,15 +271,20 @@ struct page *dma_alloc_from_pool(struct { struct gen_pool *pool = NULL; struct page *page; @@ -63,6 +61,3 @@ index 32efef1660096..484050de72fd4 100644 return NULL; } --- -2.51.0 - diff --git a/queue-5.10/scsi-be2iscsi-fix-a-memory-leak-in-beiscsi_boot_get_sinfo.patch b/queue-5.10/scsi-be2iscsi-fix-a-memory-leak-in-beiscsi_boot_get_sinfo.patch new file mode 100644 index 0000000000..73226b16a6 --- /dev/null +++ b/queue-5.10/scsi-be2iscsi-fix-a-memory-leak-in-beiscsi_boot_get_sinfo.patch @@ -0,0 +1,32 @@ +From 4747bafaa50115d9667ece446b1d2d4aba83dc7f Mon Sep 17 00:00:00 2001 +From: Haoxiang Li +Date: Sat, 13 Dec 2025 16:36:43 +0800 +Subject: scsi: be2iscsi: Fix a memory leak in beiscsi_boot_get_sinfo() + +From: Haoxiang Li + +commit 4747bafaa50115d9667ece446b1d2d4aba83dc7f upstream. + +If nonemb_cmd->va fails to be allocated, free the allocation previously +made by alloc_mcc_wrb(). + +Fixes: 50a4b824be9e ("scsi: be2iscsi: Fix to make boot discovery non-blocking") +Cc: stable@vger.kernel.org +Signed-off-by: Haoxiang Li +Link: https://patch.msgid.link/20251213083643.301240-1-lihaoxiang@isrc.iscas.ac.cn +Signed-off-by: Martin K. Petersen +Signed-off-by: Greg Kroah-Hartman +--- + drivers/scsi/be2iscsi/be_mgmt.c | 1 + + 1 file changed, 1 insertion(+) + +--- a/drivers/scsi/be2iscsi/be_mgmt.c ++++ b/drivers/scsi/be2iscsi/be_mgmt.c +@@ -1019,6 +1019,7 @@ unsigned int beiscsi_boot_get_sinfo(stru + &nonemb_cmd->dma, + GFP_KERNEL); + if (!nonemb_cmd->va) { ++ free_mcc_wrb(ctrl, tag); + mutex_unlock(&ctrl->mbox_lock); + return 0; + } diff --git a/queue-5.10/series b/queue-5.10/series index 3343f40960..8365cc8a45 100644 --- a/queue-5.10/series +++ b/queue-5.10/series @@ -132,3 +132,4 @@ nfc-nci-fix-race-between-rfkill-and-nci_unregister_d.patch net-bridge-fix-static-key-check.patch scsi-firewire-sbp-target-fix-overflow-in-sbp_make_tp.patch dma-pool-distinguish-between-missing-and-exhausted-a.patch +scsi-be2iscsi-fix-a-memory-leak-in-beiscsi_boot_get_sinfo.patch