--- /dev/null
+From 354c15139d807ae2555ea2f3fbf8060671845c51 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Tue, 13 Feb 2024 23:05:46 +0000
+Subject: bpf, scripts: Correct GPL license name
+
+From: Gianmarco Lusvardi <glusvardi@posteo.net>
+
+[ Upstream commit e37243b65d528a8a9f8b9a57a43885f8e8dfc15c ]
+
+The bpf_doc script refers to the GPL as the "GNU Privacy License".
+I strongly suspect that the author wanted to refer to the GNU General
+Public License, under which the Linux kernel is released, as, to the
+best of my knowledge, there is no license named "GNU Privacy License".
+This patch corrects the license name in the script accordingly.
+
+Fixes: 56a092c89505 ("bpf: add script and prepare bpf.h for new helpers documentation")
+Signed-off-by: Gianmarco Lusvardi <glusvardi@posteo.net>
+Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
+Reviewed-by: Quentin Monnet <quentin@isovalent.com>
+Link: https://lore.kernel.org/bpf/20240213230544.930018-3-glusvardi@posteo.net
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ scripts/bpf_helpers_doc.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/scripts/bpf_helpers_doc.py b/scripts/bpf_helpers_doc.py
+index dcddacc25dff3..cf0ee47bcbeeb 100755
+--- a/scripts/bpf_helpers_doc.py
++++ b/scripts/bpf_helpers_doc.py
+@@ -286,7 +286,7 @@ eBPF programs can have an associated license, passed along with the bytecode
+ instructions to the kernel when the programs are loaded. The format for that
+ string is identical to the one in use for kernel modules (Dual licenses, such
+ as "Dual BSD/GPL", may be used). Some helper functions are only accessible to
+-programs that are compatible with the GNU Privacy License (GPL).
++programs that are compatible with the GNU General Public License (GNU GPL).
+
+ In order to use such helpers, the eBPF program must be loaded with the correct
+ license string passed (via **attr**) to the **bpf**\ () system call, and this
+--
+2.43.0
+
--- /dev/null
+From 0e0b2b7cd1771999abd5be93c8d18ec6b8724e18 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Fri, 12 Jan 2024 16:55:23 +0800
+Subject: IB/hfi1: Fix a memleak in init_credit_return
+
+From: Zhipeng Lu <alexious@zju.edu.cn>
+
+[ Upstream commit 809aa64ebff51eb170ee31a95f83b2d21efa32e2 ]
+
+When dma_alloc_coherent fails to allocate dd->cr_base[i].va,
+init_credit_return should deallocate dd->cr_base and
+dd->cr_base[i] that allocated before. Or those resources
+would be never freed and a memleak is triggered.
+
+Fixes: 7724105686e7 ("IB/hfi1: add driver files")
+Signed-off-by: Zhipeng Lu <alexious@zju.edu.cn>
+Link: https://lore.kernel.org/r/20240112085523.3731720-1-alexious@zju.edu.cn
+Acked-by: Dennis Dalessandro <dennis.dalessandro@cornelisnetworks.com>
+Signed-off-by: Leon Romanovsky <leon@kernel.org>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/infiniband/hw/hfi1/pio.c | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/infiniband/hw/hfi1/pio.c b/drivers/infiniband/hw/hfi1/pio.c
+index 3fcbf56f8be23..c2a129ed17743 100644
+--- a/drivers/infiniband/hw/hfi1/pio.c
++++ b/drivers/infiniband/hw/hfi1/pio.c
+@@ -2118,7 +2118,7 @@ int init_credit_return(struct hfi1_devdata *dd)
+ "Unable to allocate credit return DMA range for NUMA %d\n",
+ i);
+ ret = -ENOMEM;
+- goto done;
++ goto free_cr_base;
+ }
+ }
+ set_dev_node(&dd->pcidev->dev, dd->node);
+@@ -2126,6 +2126,10 @@ int init_credit_return(struct hfi1_devdata *dd)
+ ret = 0;
+ done:
+ return ret;
++
++free_cr_base:
++ free_credit_return(dd);
++ goto done;
+ }
+
+ void free_credit_return(struct hfi1_devdata *dd)
+--
+2.43.0
+
--- /dev/null
+From dde5d62ac7e339e19b48741665fb64593eca9890 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Thu, 15 Feb 2024 23:27:17 +0300
+Subject: ipv6: sr: fix possible use-after-free and null-ptr-deref
+
+From: Vasiliy Kovalev <kovalev@altlinux.org>
+
+[ Upstream commit 5559cea2d5aa3018a5f00dd2aca3427ba09b386b ]
+
+The pernet operations structure for the subsystem must be registered
+before registering the generic netlink family.
+
+Fixes: 915d7e5e5930 ("ipv6: sr: add code base for control plane support of SR-IPv6")
+Signed-off-by: Vasiliy Kovalev <kovalev@altlinux.org>
+Link: https://lore.kernel.org/r/20240215202717.29815-1-kovalev@altlinux.org
+Signed-off-by: Paolo Abeni <pabeni@redhat.com>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ net/ipv6/seg6.c | 20 +++++++++++---------
+ 1 file changed, 11 insertions(+), 9 deletions(-)
+
+diff --git a/net/ipv6/seg6.c b/net/ipv6/seg6.c
+index 89d55770ac74b..4bd601c964343 100644
+--- a/net/ipv6/seg6.c
++++ b/net/ipv6/seg6.c
+@@ -445,22 +445,24 @@ int __init seg6_init(void)
+ {
+ int err = -ENOMEM;
+
+- err = genl_register_family(&seg6_genl_family);
++ err = register_pernet_subsys(&ip6_segments_ops);
+ if (err)
+ goto out;
+
+- err = register_pernet_subsys(&ip6_segments_ops);
++ err = genl_register_family(&seg6_genl_family);
+ if (err)
+- goto out_unregister_genl;
++ goto out_unregister_pernet;
+
+ #ifdef CONFIG_IPV6_SEG6_LWTUNNEL
+ err = seg6_iptunnel_init();
+ if (err)
+- goto out_unregister_pernet;
++ goto out_unregister_genl;
+
+ err = seg6_local_init();
+- if (err)
+- goto out_unregister_pernet;
++ if (err) {
++ seg6_iptunnel_exit();
++ goto out_unregister_genl;
++ }
+ #endif
+
+ #ifdef CONFIG_IPV6_SEG6_HMAC
+@@ -481,11 +483,11 @@ int __init seg6_init(void)
+ #endif
+ #endif
+ #ifdef CONFIG_IPV6_SEG6_LWTUNNEL
+-out_unregister_pernet:
+- unregister_pernet_subsys(&ip6_segments_ops);
+-#endif
+ out_unregister_genl:
+ genl_unregister_family(&seg6_genl_family);
++#endif
++out_unregister_pernet:
++ unregister_pernet_subsys(&ip6_segments_ops);
+ goto out;
+ }
+
+--
+2.43.0
+
--- /dev/null
+From b12b9d1856ef7e706a47db76ee8fc5b0eb45e030 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Tue, 13 Feb 2024 10:57:37 +0100
+Subject: nouveau: fix function cast warnings
+
+From: Arnd Bergmann <arnd@arndb.de>
+
+[ Upstream commit 0affdba22aca5573f9d989bcb1d71d32a6a03efe ]
+
+clang-16 warns about casting between incompatible function types:
+
+drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c:161:10: error: cast from 'void (*)(const struct firmware *)' to 'void (*)(void *)' converts to incompatible function type [-Werror,-Wcast-function-type-strict]
+ 161 | .fini = (void(*)(void *))release_firmware,
+
+This one was done to use the generic shadow_fw_release() function as a
+callback for struct nvbios_source. Change it to use the same prototype
+as the other five instances, with a trivial helper function that actually
+calls release_firmware.
+
+Fixes: 70c0f263cc2e ("drm/nouveau/bios: pull in basic vbios subdev, more to come later")
+Signed-off-by: Arnd Bergmann <arnd@arndb.de>
+Signed-off-by: Danilo Krummrich <dakr@redhat.com>
+Link: https://patchwork.freedesktop.org/patch/msgid/20240213095753.455062-1-arnd@kernel.org
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c b/drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c
+index 4b571cc6bc70f..6597def18627e 100644
+--- a/drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c
++++ b/drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadow.c
+@@ -154,11 +154,17 @@ shadow_fw_init(struct nvkm_bios *bios, const char *name)
+ return (void *)fw;
+ }
+
++static void
++shadow_fw_release(void *fw)
++{
++ release_firmware(fw);
++}
++
+ static const struct nvbios_source
+ shadow_fw = {
+ .name = "firmware",
+ .init = shadow_fw_init,
+- .fini = (void(*)(void *))release_firmware,
++ .fini = shadow_fw_release,
+ .read = shadow_fw_read,
+ .rw = false,
+ };
+--
+2.43.0
+
--- /dev/null
+From 3c2f0e9f5a22094c14795632208e59b67f507a95 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Thu, 18 Aug 2022 23:02:27 +0200
+Subject: packet: move from strlcpy with unused retval to strscpy
+
+From: Wolfram Sang <wsa+renesas@sang-engineering.com>
+
+[ Upstream commit 8fc9d51ea2d32a05f7d7cf86a25cc86ecc57eb45 ]
+
+Follow the advice of the below link and prefer 'strscpy' in this
+subsystem. Conversion is 1:1 because the return value is not used.
+Generated by a coccinelle script.
+
+Link: https://lore.kernel.org/r/CAHk-=wgfRnXz0W3D37d01q3JFkr_i_uTL=V6A6G1oUZcprmknw@mail.gmail.com/
+Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
+Link: https://lore.kernel.org/r/20220818210227.8611-1-wsa+renesas@sang-engineering.com
+Signed-off-by: Jakub Kicinski <kuba@kernel.org>
+Stable-dep-of: a7d6027790ac ("arp: Prevent overflow in arp_req_get().")
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ net/packet/af_packet.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c
+index 377832981178d..e8b05769d1c9a 100644
+--- a/net/packet/af_packet.c
++++ b/net/packet/af_packet.c
+@@ -1850,7 +1850,7 @@ static int packet_rcv_spkt(struct sk_buff *skb, struct net_device *dev,
+ */
+
+ spkt->spkt_family = dev->type;
+- strlcpy(spkt->spkt_device, dev->name, sizeof(spkt->spkt_device));
++ strscpy(spkt->spkt_device, dev->name, sizeof(spkt->spkt_device));
+ spkt->spkt_protocol = skb->protocol;
+
+ /*
+@@ -3501,7 +3501,7 @@ static int packet_getname_spkt(struct socket *sock, struct sockaddr *uaddr,
+ rcu_read_lock();
+ dev = dev_get_by_index_rcu(sock_net(sk), READ_ONCE(pkt_sk(sk)->ifindex));
+ if (dev)
+- strlcpy(uaddr->sa_data, dev->name, sizeof(uaddr->sa_data));
++ strscpy(uaddr->sa_data, dev->name, sizeof(uaddr->sa_data));
+ rcu_read_unlock();
+
+ return sizeof(*uaddr);
+--
+2.43.0
+
--- /dev/null
+From 0c32b90a964abd2c6601053c48f68e540c512b60 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Mon, 22 Jan 2024 20:54:36 -0800
+Subject: RDMA/bnxt_re: Return error for SRQ resize
+
+From: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
+
+[ Upstream commit 3687b450c5f32e80f179ce4b09e0454da1449eac ]
+
+SRQ resize is not supported in the driver. But driver is not
+returning error from bnxt_re_modify_srq() for SRQ resize.
+
+Fixes: 37cb11acf1f7 ("RDMA/bnxt_re: Add SRQ support for Broadcom adapters")
+Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
+Signed-off-by: Selvin Xavier <selvin.xavier@broadcom.com>
+Link: https://lore.kernel.org/r/1705985677-15551-5-git-send-email-selvin.xavier@broadcom.com
+Signed-off-by: Leon Romanovsky <leon@kernel.org>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/infiniband/hw/bnxt_re/ib_verbs.c | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/drivers/infiniband/hw/bnxt_re/ib_verbs.c b/drivers/infiniband/hw/bnxt_re/ib_verbs.c
+index f8c9caa8aad6d..e365fa8251c16 100644
+--- a/drivers/infiniband/hw/bnxt_re/ib_verbs.c
++++ b/drivers/infiniband/hw/bnxt_re/ib_verbs.c
+@@ -1475,7 +1475,7 @@ int bnxt_re_modify_srq(struct ib_srq *ib_srq, struct ib_srq_attr *srq_attr,
+ switch (srq_attr_mask) {
+ case IB_SRQ_MAX_WR:
+ /* SRQ resize is not supported */
+- break;
++ return -EINVAL;
+ case IB_SRQ_LIMIT:
+ /* Change the SRQ threshold */
+ if (srq_attr->srq_limit > srq->qplib_srq.max_wqe)
+@@ -1490,13 +1490,12 @@ int bnxt_re_modify_srq(struct ib_srq *ib_srq, struct ib_srq_attr *srq_attr,
+ /* On success, update the shadow */
+ srq->srq_limit = srq_attr->srq_limit;
+ /* No need to Build and send response back to udata */
+- break;
++ return 0;
+ default:
+ dev_err(rdev_to_dev(rdev),
+ "Unsupported srq_attr_mask 0x%x", srq_attr_mask);
+ return -EINVAL;
+ }
+- return 0;
+ }
+
+ int bnxt_re_query_srq(struct ib_srq *ib_srq, struct ib_srq_attr *srq_attr)
+--
+2.43.0
+
--- /dev/null
+From 562942986934273b86fceb0cd6d6c6477dfdd092 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Tue, 13 Feb 2024 11:07:13 +0100
+Subject: RDMA/srpt: fix function pointer cast warnings
+
+From: Arnd Bergmann <arnd@arndb.de>
+
+[ Upstream commit eb5c7465c3240151cd42a55c7ace9da0026308a1 ]
+
+clang-16 notices that srpt_qp_event() gets called through an incompatible
+pointer here:
+
+drivers/infiniband/ulp/srpt/ib_srpt.c:1815:5: error: cast from 'void (*)(struct ib_event *, struct srpt_rdma_ch *)' to 'void (*)(struct ib_event *, void *)' converts to incompatible function type [-Werror,-Wcast-function-type-strict]
+ 1815 | = (void(*)(struct ib_event *, void*))srpt_qp_event;
+
+Change srpt_qp_event() to use the correct prototype and adjust the
+argument inside of it.
+
+Fixes: a42d985bd5b2 ("ib_srpt: Initial SRP Target merge for v3.3-rc1")
+Signed-off-by: Arnd Bergmann <arnd@arndb.de>
+Link: https://lore.kernel.org/r/20240213100728.458348-1-arnd@kernel.org
+Reviewed-by: Bart Van Assche <bvanassche@acm.org>
+Signed-off-by: Leon Romanovsky <leon@kernel.org>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/infiniband/ulp/srpt/ib_srpt.c | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/infiniband/ulp/srpt/ib_srpt.c b/drivers/infiniband/ulp/srpt/ib_srpt.c
+index 4a696bf280ef9..5cbccf5a54d68 100644
+--- a/drivers/infiniband/ulp/srpt/ib_srpt.c
++++ b/drivers/infiniband/ulp/srpt/ib_srpt.c
+@@ -221,10 +221,12 @@ static const char *get_ch_state_name(enum rdma_ch_state s)
+ /**
+ * srpt_qp_event - QP event callback function
+ * @event: Description of the event that occurred.
+- * @ch: SRPT RDMA channel.
++ * @ptr: SRPT RDMA channel.
+ */
+-static void srpt_qp_event(struct ib_event *event, struct srpt_rdma_ch *ch)
++static void srpt_qp_event(struct ib_event *event, void *ptr)
+ {
++ struct srpt_rdma_ch *ch = ptr;
++
+ pr_debug("QP event %d on ch=%p sess_name=%s-%d state=%s\n",
+ event->event, ch, ch->sess_name, ch->qp->qp_num,
+ get_ch_state_name(ch->state));
+@@ -1766,8 +1768,7 @@ static int srpt_create_ch_ib(struct srpt_rdma_ch *ch)
+ }
+
+ qp_init->qp_context = (void *)ch;
+- qp_init->event_handler
+- = (void(*)(struct ib_event *, void*))srpt_qp_event;
++ qp_init->event_handler = srpt_qp_event;
+ qp_init->send_cq = ch->cq;
+ qp_init->recv_cq = ch->cq;
+ qp_init->sq_sig_type = IB_SIGNAL_REQ_WR;
+--
+2.43.0
+
--- /dev/null
+From b920d5bcc513657809d68753e80d4f6520a7b9ce Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Mon, 25 May 2020 10:22:10 -0700
+Subject: RDMA/srpt: Make debug output more detailed
+
+From: Bart Van Assche <bvanassche@acm.org>
+
+[ Upstream commit d4ee7f3a4445ec1b0b88af216f4032c4d30abf5a ]
+
+Since the session name by itself is not sufficient to uniquely identify a
+queue pair, include the queue pair number. Show the ASCII channel state
+name instead of the numeric value. This change makes the ib_srpt debug
+output more consistent.
+
+Link: https://lore.kernel.org/r/20200525172212.14413-3-bvanassche@acm.org
+Signed-off-by: Bart Van Assche <bvanassche@acm.org>
+Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
+Stable-dep-of: eb5c7465c324 ("RDMA/srpt: fix function pointer cast warnings")
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/infiniband/ulp/srpt/ib_srpt.c | 9 +++++----
+ 1 file changed, 5 insertions(+), 4 deletions(-)
+
+diff --git a/drivers/infiniband/ulp/srpt/ib_srpt.c b/drivers/infiniband/ulp/srpt/ib_srpt.c
+index fd3d8da6a9db8..4a696bf280ef9 100644
+--- a/drivers/infiniband/ulp/srpt/ib_srpt.c
++++ b/drivers/infiniband/ulp/srpt/ib_srpt.c
+@@ -225,8 +225,9 @@ static const char *get_ch_state_name(enum rdma_ch_state s)
+ */
+ static void srpt_qp_event(struct ib_event *event, struct srpt_rdma_ch *ch)
+ {
+- pr_debug("QP event %d on ch=%p sess_name=%s state=%d\n",
+- event->event, ch, ch->sess_name, ch->state);
++ pr_debug("QP event %d on ch=%p sess_name=%s-%d state=%s\n",
++ event->event, ch, ch->sess_name, ch->qp->qp_num,
++ get_ch_state_name(ch->state));
+
+ switch (event->event) {
+ case IB_EVENT_COMM_EST:
+@@ -1967,8 +1968,8 @@ static void __srpt_close_all_ch(struct srpt_port *sport)
+ list_for_each_entry(nexus, &sport->nexus_list, entry) {
+ list_for_each_entry(ch, &nexus->ch_list, list) {
+ if (srpt_disconnect_ch(ch) >= 0)
+- pr_info("Closing channel %s because target %s_%d has been disabled\n",
+- ch->sess_name,
++ pr_info("Closing channel %s-%d because target %s_%d has been disabled\n",
++ ch->sess_name, ch->qp->qp_num,
+ dev_name(&sport->sdev->device->dev),
+ sport->port);
+ srpt_close_ch(ch);
+--
+2.43.0
+
--- /dev/null
+From 4329d895c611e9f34d0504610c893704979f417a Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Sun, 4 Feb 2024 16:42:07 -0800
+Subject: RDMA/srpt: Support specifying the srpt_service_guid parameter
+
+From: Bart Van Assche <bvanassche@acm.org>
+
+[ Upstream commit fdfa083549de5d50ebf7f6811f33757781e838c0 ]
+
+Make loading ib_srpt with this parameter set work. The current behavior is
+that setting that parameter while loading the ib_srpt kernel module
+triggers the following kernel crash:
+
+BUG: kernel NULL pointer dereference, address: 0000000000000000
+Call Trace:
+ <TASK>
+ parse_one+0x18c/0x1d0
+ parse_args+0xe1/0x230
+ load_module+0x8de/0xa60
+ init_module_from_file+0x8b/0xd0
+ idempotent_init_module+0x181/0x240
+ __x64_sys_finit_module+0x5a/0xb0
+ do_syscall_64+0x5f/0xe0
+ entry_SYSCALL_64_after_hwframe+0x6e/0x76
+
+Cc: LiHonggang <honggangli@163.com>
+Reported-by: LiHonggang <honggangli@163.com>
+Fixes: a42d985bd5b2 ("ib_srpt: Initial SRP Target merge for v3.3-rc1")
+Signed-off-by: Bart Van Assche <bvanassche@acm.org>
+Link: https://lore.kernel.org/r/20240205004207.17031-1-bvanassche@acm.org
+Signed-off-by: Leon Romanovsky <leon@kernel.org>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/infiniband/ulp/srpt/ib_srpt.c | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/infiniband/ulp/srpt/ib_srpt.c b/drivers/infiniband/ulp/srpt/ib_srpt.c
+index 6090f1ce0c56f..f3d83a05aa4fa 100644
+--- a/drivers/infiniband/ulp/srpt/ib_srpt.c
++++ b/drivers/infiniband/ulp/srpt/ib_srpt.c
+@@ -82,12 +82,16 @@ module_param(srpt_srq_size, int, 0444);
+ MODULE_PARM_DESC(srpt_srq_size,
+ "Shared receive queue (SRQ) size.");
+
++static int srpt_set_u64_x(const char *buffer, const struct kernel_param *kp)
++{
++ return kstrtou64(buffer, 16, (u64 *)kp->arg);
++}
+ static int srpt_get_u64_x(char *buffer, const struct kernel_param *kp)
+ {
+ return sprintf(buffer, "0x%016llx", *(u64 *)kp->arg);
+ }
+-module_param_call(srpt_service_guid, NULL, srpt_get_u64_x, &srpt_service_guid,
+- 0444);
++module_param_call(srpt_service_guid, srpt_set_u64_x, srpt_get_u64_x,
++ &srpt_service_guid, 0444);
+ MODULE_PARM_DESC(srpt_service_guid,
+ "Using this value for ioc_guid, id_ext, and cm_listen_id"
+ " instead of using the node_guid of the first HCA.");
+--
+2.43.0
+
--- /dev/null
+From 56df73401a6ae90607473451b51cebbadbef6934 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Thu, 20 Sep 2018 16:42:27 -0600
+Subject: RDMA/ulp: Use dev_name instead of ibdev->name
+
+From: Jason Gunthorpe <jgg@mellanox.com>
+
+[ Upstream commit 6c8541118bd53bc90b6c2473e289e5541de80376 ]
+
+These return the same thing but dev_name is a more conventional use of the
+kernel API.
+
+Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
+Reviewed-by: Steve Wise <swise@opengridcomputing.com>
+Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
+Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
+Stable-dep-of: eb5c7465c324 ("RDMA/srpt: fix function pointer cast warnings")
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/infiniband/ulp/ipoib/ipoib_verbs.c | 2 +-
+ drivers/infiniband/ulp/iser/iser_verbs.c | 9 ++++---
+ drivers/infiniband/ulp/isert/ib_isert.c | 2 +-
+ .../infiniband/ulp/opa_vnic/opa_vnic_vema.c | 3 ++-
+ drivers/infiniband/ulp/srp/ib_srp.c | 10 ++++---
+ drivers/infiniband/ulp/srpt/ib_srpt.c | 26 ++++++++++---------
+ include/rdma/rdma_vt.h | 2 +-
+ 7 files changed, 30 insertions(+), 24 deletions(-)
+
+diff --git a/drivers/infiniband/ulp/ipoib/ipoib_verbs.c b/drivers/infiniband/ulp/ipoib/ipoib_verbs.c
+index 9f36ca786df84..1e88213459f2f 100644
+--- a/drivers/infiniband/ulp/ipoib/ipoib_verbs.c
++++ b/drivers/infiniband/ulp/ipoib/ipoib_verbs.c
+@@ -277,7 +277,7 @@ void ipoib_event(struct ib_event_handler *handler,
+ return;
+
+ ipoib_dbg(priv, "Event %d on device %s port %d\n", record->event,
+- record->device->name, record->element.port_num);
++ dev_name(&record->device->dev), record->element.port_num);
+
+ if (record->event == IB_EVENT_SM_CHANGE ||
+ record->event == IB_EVENT_CLIENT_REREGISTER) {
+diff --git a/drivers/infiniband/ulp/iser/iser_verbs.c b/drivers/infiniband/ulp/iser/iser_verbs.c
+index bee8c0b1d6a51..4ff3d98fa6a4e 100644
+--- a/drivers/infiniband/ulp/iser/iser_verbs.c
++++ b/drivers/infiniband/ulp/iser/iser_verbs.c
+@@ -55,7 +55,7 @@ static void iser_event_handler(struct ib_event_handler *handler,
+ {
+ iser_err("async event %s (%d) on device %s port %d\n",
+ ib_event_msg(event->event), event->event,
+- event->device->name, event->element.port_num);
++ dev_name(&event->device->dev), event->element.port_num);
+ }
+
+ /**
+@@ -85,7 +85,7 @@ static int iser_create_device_ib_res(struct iser_device *device)
+ max_cqe = min(ISER_MAX_CQ_LEN, ib_dev->attrs.max_cqe);
+
+ iser_info("using %d CQs, device %s supports %d vectors max_cqe %d\n",
+- device->comps_used, ib_dev->name,
++ device->comps_used, dev_name(&ib_dev->dev),
+ ib_dev->num_comp_vectors, max_cqe);
+
+ device->pd = ib_alloc_pd(ib_dev,
+@@ -468,7 +468,8 @@ static int iser_create_ib_conn_res(struct ib_conn *ib_conn)
+ iser_conn->max_cmds =
+ ISER_GET_MAX_XMIT_CMDS(ib_dev->attrs.max_qp_wr);
+ iser_dbg("device %s supports max_send_wr %d\n",
+- device->ib_device->name, ib_dev->attrs.max_qp_wr);
++ dev_name(&device->ib_device->dev),
++ ib_dev->attrs.max_qp_wr);
+ }
+ }
+
+@@ -764,7 +765,7 @@ static void iser_addr_handler(struct rdma_cm_id *cma_id)
+ IB_DEVICE_SIGNATURE_HANDOVER)) {
+ iser_warn("T10-PI requested but not supported on %s, "
+ "continue without T10-PI\n",
+- ib_conn->device->ib_device->name);
++ dev_name(&ib_conn->device->ib_device->dev));
+ ib_conn->pi_support = false;
+ } else {
+ ib_conn->pi_support = true;
+diff --git a/drivers/infiniband/ulp/isert/ib_isert.c b/drivers/infiniband/ulp/isert/ib_isert.c
+index d7b7b77e4d658..c4eec0aef76e6 100644
+--- a/drivers/infiniband/ulp/isert/ib_isert.c
++++ b/drivers/infiniband/ulp/isert/ib_isert.c
+@@ -262,7 +262,7 @@ isert_alloc_comps(struct isert_device *device)
+
+ isert_info("Using %d CQs, %s supports %d vectors support "
+ "pi_capable %d\n",
+- device->comps_used, device->ib_device->name,
++ device->comps_used, dev_name(&device->ib_device->dev),
+ device->ib_device->num_comp_vectors,
+ device->pi_capable);
+
+diff --git a/drivers/infiniband/ulp/opa_vnic/opa_vnic_vema.c b/drivers/infiniband/ulp/opa_vnic/opa_vnic_vema.c
+index 15711dcc6f585..d119d9afa845a 100644
+--- a/drivers/infiniband/ulp/opa_vnic/opa_vnic_vema.c
++++ b/drivers/infiniband/ulp/opa_vnic/opa_vnic_vema.c
+@@ -888,7 +888,8 @@ static void opa_vnic_event(struct ib_event_handler *handler,
+ return;
+
+ c_dbg("OPA_VNIC received event %d on device %s port %d\n",
+- record->event, record->device->name, record->element.port_num);
++ record->event, dev_name(&record->device->dev),
++ record->element.port_num);
+
+ if (record->event == IB_EVENT_PORT_ERR)
+ idr_for_each(&port->vport_idr, vema_disable_vport, NULL);
+diff --git a/drivers/infiniband/ulp/srp/ib_srp.c b/drivers/infiniband/ulp/srp/ib_srp.c
+index 6dcdc42ed0819..f5402c5742009 100644
+--- a/drivers/infiniband/ulp/srp/ib_srp.c
++++ b/drivers/infiniband/ulp/srp/ib_srp.c
+@@ -3115,7 +3115,8 @@ static ssize_t show_local_ib_device(struct device *dev,
+ {
+ struct srp_target_port *target = host_to_target(class_to_shost(dev));
+
+- return sprintf(buf, "%s\n", target->srp_host->srp_dev->dev->name);
++ return sprintf(buf, "%s\n",
++ dev_name(&target->srp_host->srp_dev->dev->dev));
+ }
+
+ static ssize_t show_ch_count(struct device *dev, struct device_attribute *attr,
+@@ -3990,7 +3991,7 @@ static ssize_t show_ibdev(struct device *dev, struct device_attribute *attr,
+ {
+ struct srp_host *host = container_of(dev, struct srp_host, dev);
+
+- return sprintf(buf, "%s\n", host->srp_dev->dev->name);
++ return sprintf(buf, "%s\n", dev_name(&host->srp_dev->dev->dev));
+ }
+
+ static DEVICE_ATTR(ibdev, S_IRUGO, show_ibdev, NULL);
+@@ -4022,7 +4023,8 @@ static struct srp_host *srp_add_port(struct srp_device *device, u8 port)
+
+ host->dev.class = &srp_class;
+ host->dev.parent = device->dev->dev.parent;
+- dev_set_name(&host->dev, "srp-%s-%d", device->dev->name, port);
++ dev_set_name(&host->dev, "srp-%s-%d", dev_name(&device->dev->dev),
++ port);
+
+ if (device_register(&host->dev))
+ goto free_host;
+@@ -4098,7 +4100,7 @@ static void srp_add_one(struct ib_device *device)
+ srp_dev->mr_max_size = srp_dev->mr_page_size *
+ srp_dev->max_pages_per_mr;
+ pr_debug("%s: mr_page_shift = %d, device->max_mr_size = %#llx, device->max_fast_reg_page_list_len = %u, max_pages_per_mr = %d, mr_max_size = %#x\n",
+- device->name, mr_page_shift, attr->max_mr_size,
++ dev_name(&device->dev), mr_page_shift, attr->max_mr_size,
+ attr->max_fast_reg_page_list_len,
+ srp_dev->max_pages_per_mr, srp_dev->mr_max_size);
+
+diff --git a/drivers/infiniband/ulp/srpt/ib_srpt.c b/drivers/infiniband/ulp/srpt/ib_srpt.c
+index f3d83a05aa4fa..fd3d8da6a9db8 100644
+--- a/drivers/infiniband/ulp/srpt/ib_srpt.c
++++ b/drivers/infiniband/ulp/srpt/ib_srpt.c
+@@ -152,7 +152,7 @@ static void srpt_event_handler(struct ib_event_handler *handler,
+ return;
+
+ pr_debug("ASYNC event= %d on device= %s\n", event->event,
+- sdev->device->name);
++ dev_name(&sdev->device->dev));
+
+ switch (event->event) {
+ case IB_EVENT_PORT_ERR:
+@@ -1969,7 +1969,8 @@ static void __srpt_close_all_ch(struct srpt_port *sport)
+ if (srpt_disconnect_ch(ch) >= 0)
+ pr_info("Closing channel %s because target %s_%d has been disabled\n",
+ ch->sess_name,
+- sport->sdev->device->name, sport->port);
++ dev_name(&sport->sdev->device->dev),
++ sport->port);
+ srpt_close_ch(ch);
+ }
+ }
+@@ -2163,7 +2164,7 @@ static int srpt_cm_req_recv(struct srpt_device *const sdev,
+ if (!sport->enabled) {
+ rej->reason = cpu_to_be32(SRP_LOGIN_REJ_INSUFFICIENT_RESOURCES);
+ pr_info("rejected SRP_LOGIN_REQ because target port %s_%d has not yet been enabled\n",
+- sport->sdev->device->name, port_num);
++ dev_name(&sport->sdev->device->dev), port_num);
+ goto reject;
+ }
+
+@@ -2303,7 +2304,7 @@ static int srpt_cm_req_recv(struct srpt_device *const sdev,
+ rej->reason = cpu_to_be32(
+ SRP_LOGIN_REJ_INSUFFICIENT_RESOURCES);
+ pr_info("rejected SRP_LOGIN_REQ because target %s_%d is not enabled\n",
+- sdev->device->name, port_num);
++ dev_name(&sdev->device->dev), port_num);
+ mutex_unlock(&sport->mutex);
+ ret = -EINVAL;
+ goto reject;
+@@ -2890,7 +2891,7 @@ static int srpt_release_sport(struct srpt_port *sport)
+ while (wait_event_timeout(sport->ch_releaseQ,
+ srpt_ch_list_empty(sport), 5 * HZ) <= 0) {
+ pr_info("%s_%d: waiting for session unregistration ...\n",
+- sport->sdev->device->name, sport->port);
++ dev_name(&sport->sdev->device->dev), sport->port);
+ rcu_read_lock();
+ list_for_each_entry(nexus, &sport->nexus_list, entry) {
+ list_for_each_entry(ch, &nexus->ch_list, list) {
+@@ -2980,7 +2981,7 @@ static int srpt_alloc_srq(struct srpt_device *sdev)
+ }
+
+ pr_debug("create SRQ #wr= %d max_allow=%d dev= %s\n", sdev->srq_size,
+- sdev->device->attrs.max_srq_wr, device->name);
++ sdev->device->attrs.max_srq_wr, dev_name(&device->dev));
+
+ sdev->ioctx_ring = (struct srpt_recv_ioctx **)
+ srpt_alloc_ioctx_ring(sdev, sdev->srq_size,
+@@ -3013,8 +3014,8 @@ static int srpt_use_srq(struct srpt_device *sdev, bool use_srq)
+ } else if (use_srq && !sdev->srq) {
+ ret = srpt_alloc_srq(sdev);
+ }
+- pr_debug("%s(%s): use_srq = %d; ret = %d\n", __func__, device->name,
+- sdev->use_srq, ret);
++ pr_debug("%s(%s): use_srq = %d; ret = %d\n", __func__,
++ dev_name(&device->dev), sdev->use_srq, ret);
+ return ret;
+ }
+
+@@ -3100,7 +3101,7 @@ static void srpt_add_one(struct ib_device *device)
+
+ if (srpt_refresh_port(sport)) {
+ pr_err("MAD registration failed for %s-%d.\n",
+- sdev->device->name, i);
++ dev_name(&sdev->device->dev), i);
+ goto err_event;
+ }
+ }
+@@ -3111,7 +3112,7 @@ static void srpt_add_one(struct ib_device *device)
+
+ out:
+ ib_set_client_data(device, &srpt_client, sdev);
+- pr_debug("added %s.\n", device->name);
++ pr_debug("added %s.\n", dev_name(&device->dev));
+ return;
+
+ err_event:
+@@ -3126,7 +3127,7 @@ static void srpt_add_one(struct ib_device *device)
+ kfree(sdev);
+ err:
+ sdev = NULL;
+- pr_info("%s(%s) failed.\n", __func__, device->name);
++ pr_info("%s(%s) failed.\n", __func__, dev_name(&device->dev));
+ goto out;
+ }
+
+@@ -3141,7 +3142,8 @@ static void srpt_remove_one(struct ib_device *device, void *client_data)
+ int i;
+
+ if (!sdev) {
+- pr_info("%s(%s): nothing to do.\n", __func__, device->name);
++ pr_info("%s(%s): nothing to do.\n", __func__,
++ dev_name(&device->dev));
+ return;
+ }
+
+diff --git a/include/rdma/rdma_vt.h b/include/rdma/rdma_vt.h
+index e79229a0cf014..8a36122afb754 100644
+--- a/include/rdma/rdma_vt.h
++++ b/include/rdma/rdma_vt.h
+@@ -434,7 +434,7 @@ static inline void rvt_set_ibdev_name(struct rvt_dev_info *rdi,
+ */
+ static inline const char *rvt_get_ibdev_name(const struct rvt_dev_info *rdi)
+ {
+- return rdi->ibdev.name;
++ return dev_name(&rdi->ibdev.dev);
+ }
+
+ static inline struct rvt_pd *ibpd_to_rvtpd(struct ib_pd *ibpd)
+--
+2.43.0
+
--- /dev/null
+From 5b5d5cecfee3699a602db2bce15c601f6b272d31 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Fri, 16 Feb 2024 20:48:14 -0400
+Subject: s390: use the correct count for __iowrite64_copy()
+
+From: Jason Gunthorpe <jgg@nvidia.com>
+
+[ Upstream commit 723a2cc8d69d4342b47dfddbfe6c19f1b135f09b ]
+
+The signature for __iowrite64_copy() requires the number of 64 bit
+quantities, not bytes. Multiple by 8 to get to a byte length before
+invoking zpci_memcpy_toio()
+
+Fixes: 87bc359b9822 ("s390/pci: speed up __iowrite64_copy by using pci store block insn")
+Acked-by: Niklas Schnelle <schnelle@linux.ibm.com>
+Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
+Link: https://lore.kernel.org/r/0-v1-9223d11a7662+1d7785-s390_iowrite64_jgg@nvidia.com
+Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ arch/s390/pci/pci.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/arch/s390/pci/pci.c b/arch/s390/pci/pci.c
+index 9f6f392a44619..66c7f13b0c990 100644
+--- a/arch/s390/pci/pci.c
++++ b/arch/s390/pci/pci.c
+@@ -273,7 +273,7 @@ resource_size_t pcibios_align_resource(void *data, const struct resource *res,
+ /* combine single writes by using store-block insn */
+ void __iowrite64_copy(void __iomem *to, const void *from, size_t count)
+ {
+- zpci_memcpy_toio(to, from, count);
++ zpci_memcpy_toio(to, from, count * 8);
+ }
+
+ /* Create a virtual mapping cookie for a PCI BAR */
+--
+2.43.0
+
--- /dev/null
+From 06581ef434f5bbb7f2986d5ab339c70d0a25a135 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Sun, 6 Oct 2019 20:07:37 -0700
+Subject: scripts/bpf: teach bpf_helpers_doc.py to dump BPF helper definitions
+
+From: Andrii Nakryiko <andriin@fb.com>
+
+[ Upstream commit 7a387bed47f7e80e257d966cd64a3e92a63e26a1 ]
+
+Enhance scripts/bpf_helpers_doc.py to emit C header with BPF helper
+definitions (to be included from libbpf's bpf_helpers.h).
+
+Signed-off-by: Andrii Nakryiko <andriin@fb.com>
+Signed-off-by: Alexei Starovoitov <ast@kernel.org>
+Stable-dep-of: e37243b65d52 ("bpf, scripts: Correct GPL license name")
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ scripts/bpf_helpers_doc.py | 155 ++++++++++++++++++++++++++++++++++++-
+ 1 file changed, 154 insertions(+), 1 deletion(-)
+
+diff --git a/scripts/bpf_helpers_doc.py b/scripts/bpf_helpers_doc.py
+index 5010a4d5bfbab..dcddacc25dff3 100755
+--- a/scripts/bpf_helpers_doc.py
++++ b/scripts/bpf_helpers_doc.py
+@@ -391,6 +391,154 @@ SEE ALSO
+
+ print('')
+
++class PrinterHelpers(Printer):
++ """
++ A printer for dumping collected information about helpers as C header to
++ be included from BPF program.
++ @helpers: array of Helper objects to print to standard output
++ """
++
++ type_fwds = [
++ 'struct bpf_fib_lookup',
++ 'struct bpf_perf_event_data',
++ 'struct bpf_perf_event_value',
++ 'struct bpf_sock',
++ 'struct bpf_sock_addr',
++ 'struct bpf_sock_ops',
++ 'struct bpf_sock_tuple',
++ 'struct bpf_spin_lock',
++ 'struct bpf_sysctl',
++ 'struct bpf_tcp_sock',
++ 'struct bpf_tunnel_key',
++ 'struct bpf_xfrm_state',
++ 'struct pt_regs',
++ 'struct sk_reuseport_md',
++ 'struct sockaddr',
++ 'struct tcphdr',
++
++ 'struct __sk_buff',
++ 'struct sk_msg_md',
++ 'struct xpd_md',
++ ]
++ known_types = {
++ '...',
++ 'void',
++ 'const void',
++ 'char',
++ 'const char',
++ 'int',
++ 'long',
++ 'unsigned long',
++
++ '__be16',
++ '__be32',
++ '__wsum',
++
++ 'struct bpf_fib_lookup',
++ 'struct bpf_perf_event_data',
++ 'struct bpf_perf_event_value',
++ 'struct bpf_sock',
++ 'struct bpf_sock_addr',
++ 'struct bpf_sock_ops',
++ 'struct bpf_sock_tuple',
++ 'struct bpf_spin_lock',
++ 'struct bpf_sysctl',
++ 'struct bpf_tcp_sock',
++ 'struct bpf_tunnel_key',
++ 'struct bpf_xfrm_state',
++ 'struct pt_regs',
++ 'struct sk_reuseport_md',
++ 'struct sockaddr',
++ 'struct tcphdr',
++ }
++ mapped_types = {
++ 'u8': '__u8',
++ 'u16': '__u16',
++ 'u32': '__u32',
++ 'u64': '__u64',
++ 's8': '__s8',
++ 's16': '__s16',
++ 's32': '__s32',
++ 's64': '__s64',
++ 'size_t': 'unsigned long',
++ 'struct bpf_map': 'void',
++ 'struct sk_buff': 'struct __sk_buff',
++ 'const struct sk_buff': 'const struct __sk_buff',
++ 'struct sk_msg_buff': 'struct sk_msg_md',
++ 'struct xdp_buff': 'struct xdp_md',
++ }
++
++ def print_header(self):
++ header = '''\
++/* This is auto-generated file. See bpf_helpers_doc.py for details. */
++
++/* Forward declarations of BPF structs */'''
++
++ print(header)
++ for fwd in self.type_fwds:
++ print('%s;' % fwd)
++ print('')
++
++ def print_footer(self):
++ footer = ''
++ print(footer)
++
++ def map_type(self, t):
++ if t in self.known_types:
++ return t
++ if t in self.mapped_types:
++ return self.mapped_types[t]
++ print("")
++ print("Unrecognized type '%s', please add it to known types!" % t)
++ sys.exit(1)
++
++ seen_helpers = set()
++
++ def print_one(self, helper):
++ proto = helper.proto_break_down()
++
++ if proto['name'] in self.seen_helpers:
++ return
++ self.seen_helpers.add(proto['name'])
++
++ print('/*')
++ print(" * %s" % proto['name'])
++ print(" *")
++ if (helper.desc):
++ # Do not strip all newline characters: formatted code at the end of
++ # a section must be followed by a blank line.
++ for line in re.sub('\n$', '', helper.desc, count=1).split('\n'):
++ print(' *{}{}'.format(' \t' if line else '', line))
++
++ if (helper.ret):
++ print(' *')
++ print(' * Returns')
++ for line in helper.ret.rstrip().split('\n'):
++ print(' *{}{}'.format(' \t' if line else '', line))
++
++ print(' */')
++ print('static %s %s(*%s)(' % (self.map_type(proto['ret_type']),
++ proto['ret_star'], proto['name']), end='')
++ comma = ''
++ for i, a in enumerate(proto['args']):
++ t = a['type']
++ n = a['name']
++ if proto['name'] == 'bpf_get_socket_cookie' and i == 0:
++ t = 'void'
++ n = 'ctx'
++ one_arg = '{}{}'.format(comma, self.map_type(t))
++ if n:
++ if a['star']:
++ one_arg += ' {}'.format(a['star'])
++ else:
++ one_arg += ' '
++ one_arg += '{}'.format(n)
++ comma = ', '
++ print(one_arg, end='')
++
++ print(') = (void *) %d;' % len(self.seen_helpers))
++ print('')
++
+ ###############################################################################
+
+ # If script is launched from scripts/ from kernel tree and can access
+@@ -405,6 +553,8 @@ Parse eBPF header file and generate documentation for eBPF helper functions.
+ The RST-formatted output produced can be turned into a manual page with the
+ rst2man utility.
+ """)
++argParser.add_argument('--header', action='store_true',
++ help='generate C header file')
+ if (os.path.isfile(bpfh)):
+ argParser.add_argument('--filename', help='path to include/uapi/linux/bpf.h',
+ default=bpfh)
+@@ -417,5 +567,8 @@ headerParser = HeaderParser(args.filename)
+ headerParser.run()
+
+ # Print formatted output to standard output.
+-printer = PrinterRST(headerParser.helpers)
++if args.header:
++ printer = PrinterHelpers(headerParser.helpers)
++else:
++ printer = PrinterRST(headerParser.helpers)
+ printer.print_all()
+--
+2.43.0
+
--- /dev/null
+From fe1e093ed8666919e5a060acc2e0dc18a85a5a8d Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Tue, 13 Feb 2024 21:59:53 -0800
+Subject: scsi: jazz_esp: Only build if SCSI core is builtin
+
+From: Randy Dunlap <rdunlap@infradead.org>
+
+[ Upstream commit 9ddf190a7df77b77817f955fdb9c2ae9d1c9c9a3 ]
+
+JAZZ_ESP is a bool kconfig symbol that selects SCSI_SPI_ATTRS. When
+CONFIG_SCSI=m, this results in SCSI_SPI_ATTRS=m while JAZZ_ESP=y, which
+causes many undefined symbol linker errors.
+
+Fix this by only offering to build this driver when CONFIG_SCSI=y.
+
+[mkp: JAZZ_ESP is unique in that it does not support being compiled as a
+module unlike the remaining SPI SCSI HBA drivers]
+
+Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
+Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
+Link: https://lore.kernel.org/r/20240214055953.9612-1-rdunlap@infradead.org
+Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
+Cc: linux-mips@vger.kernel.org
+Cc: Arnd Bergmann <arnd@arndb.de>
+Cc: Masahiro Yamada <masahiroy@kernel.org>
+Cc: Nicolas Schier <nicolas@fjasle.eu>
+Cc: James E.J. Bottomley <jejb@linux.ibm.com>
+Cc: Martin K. Petersen <martin.petersen@oracle.com>
+Cc: linux-scsi@vger.kernel.org
+Cc: Geert Uytterhoeven <geert@linux-m68k.org>
+Reported-by: kernel test robot <lkp@intel.com>
+Closes: https://lore.kernel.org/oe-kbuild-all/202402112222.Gl0udKyU-lkp@intel.com/
+Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/scsi/Kconfig | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/scsi/Kconfig b/drivers/scsi/Kconfig
+index 6047f0284f73a..5c3635378c321 100644
+--- a/drivers/scsi/Kconfig
++++ b/drivers/scsi/Kconfig
+@@ -1252,7 +1252,7 @@ source "drivers/scsi/arm/Kconfig"
+
+ config JAZZ_ESP
+ bool "MIPS JAZZ FAS216 SCSI support"
+- depends on MACH_JAZZ && SCSI
++ depends on MACH_JAZZ && SCSI=y
+ select SCSI_SPI_ATTRS
+ help
+ This is the driver for the onboard SCSI host adapter of MIPS Magnum
+--
+2.43.0
+
arm-ep93xx-add-terminator-to-gpiod_lookup_table.patch
usb-gadget-ncm-avoid-dropping-datagrams-of-properly-parsed-ntbs.patch
usb-roles-don-t-get-set_role-when-usb_role_switch-is-unregistered.patch
+ib-hfi1-fix-a-memleak-in-init_credit_return.patch
+rdma-bnxt_re-return-error-for-srq-resize.patch
+rdma-srpt-support-specifying-the-srpt_service_guid-p.patch
+rdma-ulp-use-dev_name-instead-of-ibdev-name.patch
+rdma-srpt-make-debug-output-more-detailed.patch
+rdma-srpt-fix-function-pointer-cast-warnings.patch
+scripts-bpf-teach-bpf_helpers_doc.py-to-dump-bpf-hel.patch
+bpf-scripts-correct-gpl-license-name.patch
+scsi-jazz_esp-only-build-if-scsi-core-is-builtin.patch
+nouveau-fix-function-cast-warnings.patch
+ipv6-sr-fix-possible-use-after-free-and-null-ptr-der.patch
+packet-move-from-strlcpy-with-unused-retval-to-strsc.patch
+s390-use-the-correct-count-for-__iowrite64_copy.patch