From: Greg Kroah-Hartman Date: Tue, 22 Apr 2025 08:59:05 +0000 (+0200) Subject: 6.6-stable patches X-Git-Tag: v6.1.135~61 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=fe1e4adfb24cfa592732b57b7324fd223a249b52;p=thirdparty%2Fkernel%2Fstable-queue.git 6.6-stable patches added patches: nvmet-fc-remove-unused-functions.patch --- diff --git a/queue-6.6/nvmet-fc-remove-unused-functions.patch b/queue-6.6/nvmet-fc-remove-unused-functions.patch new file mode 100644 index 0000000000..5a957b17dc --- /dev/null +++ b/queue-6.6/nvmet-fc-remove-unused-functions.patch @@ -0,0 +1,64 @@ +From 1b304c006b0fb4f0517a8c4ba8c46e88f48a069c Mon Sep 17 00:00:00 2001 +From: WangYuli +Date: Wed, 12 Mar 2025 13:06:50 +0800 +Subject: nvmet-fc: Remove unused functions + +From: WangYuli + +commit 1b304c006b0fb4f0517a8c4ba8c46e88f48a069c upstream. + +The functions nvmet_fc_iodnum() and nvmet_fc_fodnum() are currently +unutilized. + +Following commit c53432030d86 ("nvme-fabrics: Add target support for FC +transport"), which introduced these two functions, they have not been +used at all in practice. + +Remove them to resolve the compiler warnings. + +Fix follow errors with clang-19 when W=1e: + drivers/nvme/target/fc.c:177:1: error: unused function 'nvmet_fc_iodnum' [-Werror,-Wunused-function] + 177 | nvmet_fc_iodnum(struct nvmet_fc_ls_iod *iodptr) + | ^~~~~~~~~~~~~~~ + drivers/nvme/target/fc.c:183:1: error: unused function 'nvmet_fc_fodnum' [-Werror,-Wunused-function] + 183 | nvmet_fc_fodnum(struct nvmet_fc_fcp_iod *fodptr) + | ^~~~~~~~~~~~~~~ + 2 errors generated. + make[8]: *** [scripts/Makefile.build:207: drivers/nvme/target/fc.o] Error 1 + make[7]: *** [scripts/Makefile.build:465: drivers/nvme/target] Error 2 + make[6]: *** [scripts/Makefile.build:465: drivers/nvme] Error 2 + make[6]: *** Waiting for unfinished jobs.... + +Fixes: c53432030d86 ("nvme-fabrics: Add target support for FC transport") +Signed-off-by: WangYuli +Reviewed-by: Chaitanya Kulkarni +Reviewed-by: Christoph Hellwig +Signed-off-by: Keith Busch +Signed-off-by: Greg Kroah-Hartman +--- + drivers/nvme/target/fc.c | 14 -------------- + 1 file changed, 14 deletions(-) + +--- a/drivers/nvme/target/fc.c ++++ b/drivers/nvme/target/fc.c +@@ -173,20 +173,6 @@ struct nvmet_fc_tgt_assoc { + struct rcu_head rcu; + }; + +- +-static inline int +-nvmet_fc_iodnum(struct nvmet_fc_ls_iod *iodptr) +-{ +- return (iodptr - iodptr->tgtport->iod); +-} +- +-static inline int +-nvmet_fc_fodnum(struct nvmet_fc_fcp_iod *fodptr) +-{ +- return (fodptr - fodptr->queue->fod); +-} +- +- + /* + * Association and Connection IDs: + * diff --git a/queue-6.6/series b/queue-6.6/series index edc252fb37..40fe91f18f 100644 --- a/queue-6.6/series +++ b/queue-6.6/series @@ -381,3 +381,4 @@ wifi-rtw89-pci-add-pre_deinit-to-be-called-after-probe-complete.patch wifi-rtw89-pci-disable-pcie-wake-bit-when-pcie-deinit.patch drm-amd-display-stop-amdgpu_dm-initialize-when-link-nums-greater-than-max_links.patch landlock-add-the-errata-interface.patch +nvmet-fc-remove-unused-functions.patch