• Long Li's avatar
    smbd: Make upper layer decide when to destroy the transport · 050b8c37
    Long Li authored
    On transport recoonect, upper layer CIFS code destroys the current
    transport and then recoonect. This code path is not used by SMBD, in that
    SMBD destroys its transport on RDMA disconnect notification independent of
    CIFS upper layer behavior.
    
    This approach adds some costs to SMBD layer to handle transport shutdown
    and restart, and to deal with several racing conditions on reconnecting
    transport.
    
    Re-work this code path by introducing a new smbd_destroy. This function is
    called form upper layer to ask SMBD to destroy the transport. SMBD will no
    longer need to destroy the transport by itself while worrying about data
    transfer is in progress. The upper layer guarantees the transport is
    locked.
    
    change log:
    v2: fix build errors when CONFIG_CIFS_SMB_DIRECT is not configured
    Signed-off-by: default avatarLong Li <longli@microsoft.com>
    Signed-off-by: default avatarSteve French <stfrench@microsoft.com>
    050b8c37
smbdirect.c 77 KB