提交 b5b374ea 编写于 作者: S Steve French

Workaround Mac server problem

Mac server returns that they support CIFS Unix Extensions but
doesn't actually support QUERY_FILE_UNIX_BASIC so mount fails.

Workaround this problem by disabling use of Unix CIFS protocol
extensions if server returns an EOPNOTSUPP error on
QUERY_FILE_UNIX_BASIC during mount.
Signed-off-by: NSteve French <smfrench@gmail.com>
上级 2baa2682
......@@ -960,11 +960,18 @@ struct inode *cifs_root_iget(struct super_block *sb)
struct cifs_tcon *tcon = cifs_sb_master_tcon(cifs_sb);
xid = get_xid();
if (tcon->unix_ext)
if (tcon->unix_ext) {
rc = cifs_get_inode_info_unix(&inode, "", sb, xid);
else
rc = cifs_get_inode_info(&inode, "", NULL, sb, xid, NULL);
/* some servers mistakenly claim POSIX support */
if (rc != -EOPNOTSUPP)
goto iget_no_retry;
cifs_dbg(VFS, "server does not support POSIX extensions");
tcon->unix_ext = false;
}
rc = cifs_get_inode_info(&inode, "", NULL, sb, xid, NULL);
iget_no_retry:
if (!inode) {
inode = ERR_PTR(rc);
goto out;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册