]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
smb: server: pass struct smbdirect_socket to smb_direct_connect()
authorStefan Metzmacher <metze@samba.org>
Fri, 22 Aug 2025 12:55:50 +0000 (14:55 +0200)
committerSteve French <stfrench@microsoft.com>
Sun, 28 Sep 2025 23:29:53 +0000 (18:29 -0500)
This will make it easier to move function to the common code
in future.

Cc: Namjae Jeon <linkinjeon@kernel.org>
Cc: Steve French <smfrench@gmail.com>
Cc: Tom Talpey <tom@talpey.com>
Cc: linux-cifs@vger.kernel.org
Cc: samba-technical@lists.samba.org
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Acked-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/smb/server/transport_rdma.c

index 4ae94b67461fa99c67900cb955c3a537b25e994b..f8d08a329153bb251fb504ae1aab20306f2ae77c 100644 (file)
@@ -2106,11 +2106,10 @@ out:
        return ret;
 }
 
-static int smb_direct_connect(struct smb_direct_transport *st)
+static int smb_direct_connect(struct smbdirect_socket *sc)
 {
-       struct smbdirect_socket *sc = &st->socket;
-       int ret;
        struct ib_qp_cap qp_cap;
+       int ret;
 
        ret = smb_direct_init_params(sc, &qp_cap);
        if (ret) {
@@ -2232,7 +2231,7 @@ static int smb_direct_handle_connect_request(struct rdma_cm_id *new_cm_id,
                sp->responder_resources = min_t(u8, sp->responder_resources,
                                               peer_responder_resources);
 
-       ret = smb_direct_connect(t);
+       ret = smb_direct_connect(sc);
        if (ret)
                goto out_err;