Skip to content

Commit

Permalink
cifs: add xid to query server interface call
Browse files Browse the repository at this point in the history
We were passing 0 as the xid for the call to query
server interfaces. This is not great for debugging.
This change adds a real xid.

Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
Reviewed-by: Bharath SM <bharathsm@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
  • Loading branch information
Shyam Prasad N authored and Steve French committed Oct 31, 2023
1 parent 5276869 commit 4cf6e11
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion fs/smb/client/connect.c
Original file line number Diff line number Diff line change
Expand Up @@ -119,14 +119,18 @@ static int reconn_set_ipaddr_from_hostname(struct TCP_Server_Info *server)
static void smb2_query_server_interfaces(struct work_struct *work)
{
int rc;
int xid;
struct cifs_tcon *tcon = container_of(work,
struct cifs_tcon,
query_interfaces.work);

/*
* query server network interfaces, in case they change
*/
rc = SMB3_request_interfaces(0, tcon, false);
xid = get_xid();
rc = SMB3_request_interfaces(xid, tcon, false);
free_xid(xid);

if (rc) {
cifs_dbg(FYI, "%s: failed to query server interfaces: %d\n",
__func__, rc);
Expand Down

0 comments on commit 4cf6e11

Please sign in to comment.