Skip to content

Commit 87d03d6

Browse files
metze-sambasmfrench
authored andcommitted
smb: client: remove unused smbd_connection->protocol
There is only one protocol version for smbdirect yet and this variable is write only. 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>
1 parent 4dc536a commit 87d03d6

File tree

3 files changed

+2
-4
lines changed

3 files changed

+2
-4
lines changed

fs/smb/client/cifs_debug.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
#endif
2525
#ifdef CONFIG_CIFS_SMB_DIRECT
2626
#include "smbdirect.h"
27+
#include "../common/smbdirect/smbdirect_pdu.h"
2728
#endif
2829
#include "cifs_swn.h"
2930
#include "cached_dir.h"
@@ -458,7 +459,7 @@ static int cifs_debug_data_proc_show(struct seq_file *m, void *v)
458459

459460
seq_printf(m, "\nSMBDirect protocol version: 0x%x "
460461
"transport status: %s (%u)",
461-
server->smbd_conn->protocol,
462+
SMBDIRECT_V1,
462463
smbdirect_socket_status_string(sc->status),
463464
sc->status);
464465
seq_printf(m, "\nConn receive_credit_max: %u "

fs/smb/client/smbdirect.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -481,7 +481,6 @@ static bool process_negotiation_response(
481481
le16_to_cpu(packet->negotiated_version));
482482
return false;
483483
}
484-
info->protocol = le16_to_cpu(packet->negotiated_version);
485484

486485
if (packet->credits_requested == 0) {
487486
log_rdma_event(ERR, "error: credits_requested==0\n");

fs/smb/client/smbdirect.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,6 @@ extern int smbd_receive_credit_max;
3939
struct smbd_connection {
4040
struct smbdirect_socket socket;
4141

42-
/* dynamic connection parameters defined in [MS-SMBD] 3.1.1.1 */
43-
int protocol;
4442

4543
/* Memory registrations */
4644
/* Maximum number of pages in a single RDMA write/read on this connection */

0 commit comments

Comments
 (0)