diff options
| author | Stefan Metzmacher <metze@samba.org> | 2025-08-22 10:47:06 +0200 |
|---|---|---|
| committer | Steve French <stfrench@microsoft.com> | 2025-09-28 18:29:50 -0500 |
| commit | d76e8c7f546b2d2a49149b4ee59583aad0282c93 (patch) | |
| tree | 591d1c2c9a022a560b1781e022b79def26f43ba1 | |
| parent | 46b8fe2bd18c487aa4fd5c45e6f9c23a1c4c859a (diff) | |
smb: client: pass struct smbdirect_socket to smbd_post_send_empty()
This will make it easier to move function to the common code
in future.
Cc: Steve French <smfrench@gmail.com>
Cc: Tom Talpey <tom@talpey.com>
Cc: Long Li <longli@microsoft.com>
Cc: linux-cifs@vger.kernel.org
Cc: samba-technical@lists.samba.org
Acked-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
| -rw-r--r-- | fs/smb/client/smbdirect.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/smb/client/smbdirect.c b/fs/smb/client/smbdirect.c index 211cf391edb5..5784e82f7911 100644 --- a/fs/smb/client/smbdirect.c +++ b/fs/smb/client/smbdirect.c @@ -38,7 +38,7 @@ static int smbd_post_recv( struct smbdirect_socket *sc, struct smbdirect_recv_io *response); -static int smbd_post_send_empty(struct smbd_connection *info); +static int smbd_post_send_empty(struct smbdirect_socket *sc); static void destroy_mr_list(struct smbdirect_socket *sc); static int allocate_mr_list(struct smbdirect_socket *sc); @@ -1199,9 +1199,8 @@ err_wait_credit: * Empty message is used to extend credits to peer to for keep live * while there is no upper layer payload to send at the time */ -static int smbd_post_send_empty(struct smbd_connection *info) +static int smbd_post_send_empty(struct smbdirect_socket *sc) { - struct smbdirect_socket *sc = &info->socket; int remaining_data_length = 0; sc->statistics.send_empty++; @@ -1454,14 +1453,12 @@ static void send_immediate_empty_message(struct work_struct *work) { struct smbdirect_socket *sc = container_of(work, struct smbdirect_socket, idle.immediate_work); - struct smbd_connection *info = - container_of(sc, struct smbd_connection, socket); if (sc->status != SMBDIRECT_SOCKET_CONNECTED) return; log_keep_alive(INFO, "send an empty message\n"); - smbd_post_send_empty(info); + smbd_post_send_empty(sc); } /* Implement idle connection timer [MS-SMBD] 3.1.6.2 */ |
