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
Kirill Smelkov
linux
Commits
4d078eba
Commit
4d078eba
authored
May 27, 2004
by
Steve French
Committed by
Steve French
May 27, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix rc mapping on out of memory on mid alloc failure and cleanup dead code
parent
7713cd04
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
17 deletions
+28
-17
fs/cifs/README
fs/cifs/README
+18
-4
fs/cifs/cifsglob.h
fs/cifs/cifsglob.h
+7
-10
fs/cifs/transport.c
fs/cifs/transport.c
+3
-3
No files found.
fs/cifs/README
View file @
4d078eba
...
@@ -268,6 +268,8 @@ Misc /proc/fs/cifs Flags and Debug Info
...
@@ -268,6 +268,8 @@ Misc /proc/fs/cifs Flags and Debug Info
=======================================
=======================================
Informational pseudo-files:
Informational pseudo-files:
DebugData Displays information about active CIFS sessions
DebugData Displays information about active CIFS sessions
as well as per share statistics (if CONFIG_CIFS_STATS
is enabled in the kernel configuration).
SimultaneousOps Counter which holds maximum number of
SimultaneousOps Counter which holds maximum number of
simultaneous outstanding SMB/CIFS requests.
simultaneous outstanding SMB/CIFS requests.
Stats Lists summary resource usage information
Stats Lists summary resource usage information
...
@@ -324,13 +326,25 @@ and for more extensive tracing including the start of smb requests and responses
...
@@ -324,13 +326,25 @@ and for more extensive tracing including the start of smb requests and responses
Three other experimental features are under development and to test
Three other experimental features are under development and to test
require enabling an ifdef (e.g. by adding "#define CIFS_FCNTL" in cifsglob.h)
require enabling an ifdef (e.g. by adding "#define CIFS_FCNTL" in cifsglob.h)
CIFS_QUOTA
C
ONFIG_C
IFS_QUOTA
CIFS_XATTR
C
ONFIG_C
IFS_XATTR
CIFS_FCNTL (fcntl needed for support of directory change notification)
CONFIG_CIFS_FCNTL (fcntl needed for support of directory change
notification and perhaps later for file leases)
Also note that "cat /proc/fs/cifs/DebugData" will display some information about
Per share (per client mount) statistics are available in /proc/fs/cifs/DebugData
if the kernel was configured with cifs statistics enabled. The statistics
represent the number of successful (ie non-zero return code from the server)
SMB responses to some of the more common commands (open, delete, mkdir etc.).
Also recorded is the total bytes read and bytes written to the server for
that share. Note that due to client caching effects this can be less than the
number of bytes read and written by the application running on the client.
The statistics for the number of total SMBs and oplock breaks are different in
that they represent all for that share, not just those for which the server
returned success.
Also note that "cat /proc/fs/cifs/DebugData" will display information about
the active sessions and the shares that are mounted. Note: NTLMv2 enablement
the active sessions and the shares that are mounted. Note: NTLMv2 enablement
will not work since they its implementation is not quite complete yet.
will not work since they its implementation is not quite complete yet.
Do not alter these configuration values unless you are doing specific testing.
Do not alter these configuration values unless you are doing specific testing.
...
...
fs/cifs/cifsglob.h
View file @
4d078eba
...
@@ -34,9 +34,14 @@
...
@@ -34,9 +34,14 @@
/*
/*
* MAX_REQ is the maximum number of requests that WE will send
* MAX_REQ is the maximum number of requests that WE will send
* on one NetBIOS handle concurently.
* on one socket concurently. It also matches the most common
* value of max multiplex returned by servers. We may
* eventually want to use the negotiated value (in case
* future servers can handle more) when we are more confident that
* we will not have problems oveloading the socket with pending
* write data.
*/
*/
#define
MAX_REQ (10)
#define
CIFS_MAX_REQ 50
#define SERVER_NAME_LENGTH 15
#define SERVER_NAME_LENGTH 15
#define SERVER_NAME_LEN_WITH_NULL (SERVER_NAME_LENGTH + 1)
#define SERVER_NAME_LEN_WITH_NULL (SERVER_NAME_LENGTH + 1)
...
@@ -309,13 +314,6 @@ struct oplock_q_entry {
...
@@ -309,13 +314,6 @@ struct oplock_q_entry {
#define MID_RESPONSE_RECEIVED 4
#define MID_RESPONSE_RECEIVED 4
#define MID_RETRY_NEEDED 8
/* session closed while this request out */
#define MID_RETRY_NEEDED 8
/* session closed while this request out */
struct
servers_not_supported
{
/* @z4a */
struct
servers_not_supported
*
next1
;
/* @z4a */
char
server_Name
[
SERVER_NAME_LEN_WITH_NULL
];
/* @z4a */
/* Server Names in SMB protocol are 15 chars + X'20' */
/* in 16th byte... @z4a */
};
/*
/*
*****************************************************************
*****************************************************************
* All constants go here
* All constants go here
...
@@ -413,4 +411,3 @@ GLOBAL_EXTERN unsigned int ntlmv2_support; /* better optional password hash */
...
@@ -413,4 +411,3 @@ GLOBAL_EXTERN unsigned int ntlmv2_support; /* better optional password hash */
GLOBAL_EXTERN
unsigned
int
sign_CIFS_PDUs
;
/* enable smb packet signing */
GLOBAL_EXTERN
unsigned
int
sign_CIFS_PDUs
;
/* enable smb packet signing */
GLOBAL_EXTERN
unsigned
int
linuxExtEnabled
;
/* enable Linux/Unix CIFS extensions */
GLOBAL_EXTERN
unsigned
int
linuxExtEnabled
;
/* enable Linux/Unix CIFS extensions */
fs/cifs/transport.c
View file @
4d078eba
...
@@ -202,8 +202,8 @@ SendReceive(const unsigned int xid, struct cifsSesInfo *ses,
...
@@ -202,8 +202,8 @@ SendReceive(const unsigned int xid, struct cifsSesInfo *ses,
atomic_inc
(
&
ses
->
server
->
inFlight
);
atomic_inc
(
&
ses
->
server
->
inFlight
);
}
}
if
(
atomic_read
(
&
ses
->
server
->
inFlight
)
>
50
)
{
if
(
atomic_read
(
&
ses
->
server
->
inFlight
)
>
CIFS_MAX_REQ
)
{
wait_event
(
ses
->
server
->
request_q
,
atomic_read
(
&
ses
->
server
->
inFlight
)
<=
50
);
wait_event
(
ses
->
server
->
request_q
,
atomic_read
(
&
ses
->
server
->
inFlight
)
<=
CIFS_MAX_REQ
);
}
}
/* make sure that we sign in the same order that we send on this socket
/* make sure that we sign in the same order that we send on this socket
...
@@ -235,7 +235,7 @@ SendReceive(const unsigned int xid, struct cifsSesInfo *ses,
...
@@ -235,7 +235,7 @@ SendReceive(const unsigned int xid, struct cifsSesInfo *ses,
atomic_dec
(
&
ses
->
server
->
inFlight
);
atomic_dec
(
&
ses
->
server
->
inFlight
);
wake_up
(
&
ses
->
server
->
request_q
);
wake_up
(
&
ses
->
server
->
request_q
);
}
}
return
-
E
IO
;
return
-
E
NOMEM
;
}
}
if
(
in_buf
->
smb_buf_length
>
CIFS_MAX_MSGSIZE
+
MAX_CIFS_HDR_SIZE
-
4
)
{
if
(
in_buf
->
smb_buf_length
>
CIFS_MAX_MSGSIZE
+
MAX_CIFS_HDR_SIZE
-
4
)
{
...
...
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