Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
5221ad8c
Commit
5221ad8c
authored
Jul 21, 2003
by
Steve French
Committed by
Steve French
Jul 21, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix create/open/lookup to use namei intent flags. Enable oplock and packet signing
parent
f280895e
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
29 additions
and
22 deletions
+29
-22
fs/cifs/CHANGES
fs/cifs/CHANGES
+7
-0
fs/cifs/README
fs/cifs/README
+5
-1
fs/cifs/cifsfs.c
fs/cifs/cifsfs.c
+11
-16
fs/cifs/misc.c
fs/cifs/misc.c
+2
-2
fs/cifs/transport.c
fs/cifs/transport.c
+4
-3
No files found.
fs/cifs/CHANGES
View file @
5221ad8c
Version 0.84
------------
Finish support for Linux 2.5 open/create changes, which removes the
redundant NTCreate/QPathInfo/close that was sent during file create.
Enable oplock by default. Enable packet signing by default (needed to
access many recent Windows servers)
Version 0.83
------------
Fix oops when mounting to long server names caused by inverted parms to kmalloc.
...
...
fs/cifs/README
View file @
5221ad8c
...
...
@@ -150,7 +150,10 @@ Configuration pseudo-files:
point and if the uids user/password mapping
information is available. (default is 0)
PacketSigningEnabled If set to one, cifs packet signing is enabled
(default 0)
and will be used if the server requires
it. If set to two, cifs packet signing is
required even if the server considers packet
signing optional. (default 1)
cifsFYI If set to one, additional debug information is
logged to the system error log. (default 0)
ExtendedSecurity If set to one, SPNEGO session establishment
...
...
@@ -166,6 +169,7 @@ Configuration pseudo-files:
for one second improving performance of lookups
(default 1)
OplockEnabled If set to one, safe distributed caching enabled.
(default 1)
These experimental features and tracing can be enabled by changing flags in /proc/fs/cifs
(after the cifs module has been installed or built into the kernel, e.g. insmod cifs).
...
...
fs/cifs/cifsfs.c
View file @
5221ad8c
...
...
@@ -47,12 +47,12 @@ extern struct file_system_type cifs_fs_type;
int
cifsFYI
=
0
;
int
cifsERROR
=
1
;
int
traceSMB
=
0
;
unsigned
int
oplockEnabled
=
0
;
unsigned
int
oplockEnabled
=
1
;
unsigned
int
lookupCacheEnabled
=
1
;
unsigned
int
multiuser_mount
=
0
;
unsigned
int
extended_security
=
0
;
unsigned
int
ntlmv2_support
=
0
;
unsigned
int
sign_CIFS_PDUs
=
0
;
unsigned
int
sign_CIFS_PDUs
=
1
;
unsigned
int
CIFSMaximumBufferSize
=
CIFS_MAX_MSGSIZE
;
struct
task_struct
*
oplockThread
=
NULL
;
...
...
@@ -439,7 +439,6 @@ static int cifs_oplock_thread(void * dummyarg)
struct
list_head
*
tmp
;
struct
list_head
*
tmp1
;
struct
oplock_q_entry
*
oplock_item
;
struct
file
*
pfile
;
struct
cifsTconInfo
*
pTcon
;
int
rc
;
...
...
@@ -457,23 +456,19 @@ static int cifs_oplock_thread(void * dummyarg)
qhead
);
if
(
oplock_item
)
{
pTcon
=
oplock_item
->
tcon
;
pfile
=
oplock_item
->
file_to_flush
;
cFYI
(
1
,(
"process item on queue"
));
/* BB remove */
DeleteOplockQEntry
(
oplock_item
);
write_unlock
(
&
GlobalMid_Lock
);
rc
=
filemap_fdatawrite
(
pfile
->
f_dentry
->
d_
inode
->
i_mapping
);
rc
=
filemap_fdatawrite
(
oplock_item
->
p
inode
->
i_mapping
);
if
(
rc
)
CIFS_I
(
pfile
->
f_dentry
->
d_
inode
)
->
write_behind_rc
CIFS_I
(
oplock_item
->
p
inode
)
->
write_behind_rc
=
rc
;
cFYI
(
1
,(
"Oplock flush file %p rc %d"
,
pfile
,
rc
));
if
(
pfile
->
private_data
)
{
rc
=
CIFSSMBLock
(
0
,
pTcon
,
((
struct
cifsFileInfo
*
)
pfile
->
private_data
)
->
netfid
,
0
/* len */
,
0
/* offset */
,
0
,
0
,
LOCKING_ANDX_OPLOCK_RELEASE
,
0
/* wait flag */
);
cFYI
(
1
,(
"Oplock release rc = %d "
,
rc
));
}
cFYI
(
1
,(
"Oplock flush inode %p rc %d"
,
oplock_item
->
pinode
,
rc
));
rc
=
CIFSSMBLock
(
0
,
pTcon
,
oplock_item
->
netfid
,
0
/* len */
,
0
/* offset */
,
0
,
0
,
LOCKING_ANDX_OPLOCK_RELEASE
,
0
/* wait flag */
);
cFYI
(
1
,(
"Oplock release rc = %d "
,
rc
));
write_lock
(
&
GlobalMid_Lock
);
}
else
break
;
...
...
fs/cifs/misc.c
View file @
5221ad8c
...
...
@@ -390,12 +390,12 @@ is_valid_oplock_break(struct smb_hdr *buf)
read_unlock
(
&
GlobalSMBSeslock
);
cFYI
(
1
,(
"Matching file id, processing oplock break"
));
pCifsInode
=
CIFS_I
(
netfile
->
p
file
->
f_dentry
->
d_i
node
);
CIFS_I
(
netfile
->
p
I
node
);
pCifsInode
->
clientCanCacheAll
=
FALSE
;
if
(
pSMB
->
OplockLevel
==
0
)
pCifsInode
->
clientCanCacheRead
=
FALSE
;
pCifsInode
->
oplockPending
=
TRUE
;
AllocOplockQEntry
(
netfile
->
p
file
,
tcon
);
AllocOplockQEntry
(
netfile
->
p
Inode
,
netfile
->
netfid
,
tcon
);
cFYI
(
1
,(
"about to wake up oplock thd"
));
wake_up_process
(
oplockThread
);
return
TRUE
;
...
...
fs/cifs/transport.c
View file @
5221ad8c
...
...
@@ -101,10 +101,10 @@ DeleteMidQEntry(struct mid_q_entry *midEntry)
}
struct
oplock_q_entry
*
AllocOplockQEntry
(
struct
file
*
file
,
struct
cifsTconInfo
*
tcon
)
AllocOplockQEntry
(
struct
inode
*
pinode
,
__u16
fid
,
struct
cifsTconInfo
*
tcon
)
{
struct
oplock_q_entry
*
temp
;
if
((
file
==
NULL
)
||
(
tcon
==
NULL
))
{
if
((
pinode
==
NULL
)
||
(
tcon
==
NULL
))
{
cERROR
(
1
,
(
"Null parms passed to AllocOplockQEntry"
));
return
NULL
;
}
...
...
@@ -113,8 +113,9 @@ AllocOplockQEntry(struct file * file, struct cifsTconInfo * tcon)
if
(
temp
==
NULL
)
return
temp
;
else
{
temp
->
file_to_flush
=
fil
e
;
temp
->
pinode
=
pinod
e
;
temp
->
tcon
=
tcon
;
temp
->
netfid
=
fid
;
write_lock
(
&
GlobalMid_Lock
);
list_add_tail
(
&
temp
->
qhead
,
&
GlobalOplock_Q
);
write_unlock
(
&
GlobalMid_Lock
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment