mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-10 15:10:38 +00:00
smb3: add some more descriptive messages about share when mounting cache=ro
Add some additional logging so the user can see if the share they mounted with cache=ro is considered read only by the server CIFS: Attempting to mount //localhost/test CIFS VFS: mounting share with read only caching. Ensure that the share will not be modified while in use. CIFS VFS: read only mount of RW share CIFS: Attempting to mount //localhost/test-ro CIFS VFS: mounting share with read only caching. Ensure that the share will not be modified while in use. CIFS VFS: mounted to read only share Signed-off-by: Steve French <stfrench@microsoft.com> Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com>
This commit is contained in:
parent
83bbfa706d
commit
1981ebaabd
@ -4197,8 +4197,16 @@ static int mount_get_conns(struct smb_vol *vol, struct cifs_sb_info *cifs_sb,
|
||||
tcon->unix_ext = 0; /* server does not support them */
|
||||
|
||||
/* do not care if a following call succeed - informational */
|
||||
if (!tcon->pipe && server->ops->qfs_tcon)
|
||||
if (!tcon->pipe && server->ops->qfs_tcon) {
|
||||
server->ops->qfs_tcon(*xid, tcon);
|
||||
if (cifs_sb->mnt_cifs_flags & CIFS_MOUNT_RO_CACHE) {
|
||||
if (tcon->fsDevInfo.DeviceCharacteristics &
|
||||
FILE_READ_ONLY_DEVICE)
|
||||
cifs_dbg(VFS, "mounted to read only share\n");
|
||||
else
|
||||
cifs_dbg(VFS, "read only mount of RW share\n");
|
||||
}
|
||||
}
|
||||
|
||||
cifs_sb->wsize = server->ops->negotiate_wsize(tcon, vol);
|
||||
cifs_sb->rsize = server->ops->negotiate_rsize(tcon, vol);
|
||||
|
Loading…
x
Reference in New Issue
Block a user