Commit 05a46cc8 authored by Steve French's avatar Steve French Committed by Steve French

fix listxattr error path

Signed-off-by: Steve French (sfrench@us.ibm.com)
parent c1f8b629
Version 1.18 Version 1.18
------------ ------------
Do not rename hardlinked files (since that should be a noop). Flush Do not rename hardlinked files (since that should be a noop). Flush
cached write behind data when reopening a file after session abend. cached write behind data when reopening a file after session abend,
except when already in write. Grab per socket sem during reconnect
to avoid oops in sendmsg if overlapping with reconnect.
Version 1.17 Version 1.17
------------ ------------
......
...@@ -97,7 +97,9 @@ Linux: ...@@ -97,7 +97,9 @@ Linux:
case sensitive = yes case sensitive = yes
delete readonly = yes delete readonly = yes
ea support = yes
Note that ea support is required for supporting Linux xattrs.
Some administrators also change the "map archive" and the "create mask" Some administrators also change the "map archive" and the "create mask"
parameters from their default values. Creating special devices (mknod) remotely parameters from their default values. Creating special devices (mknod) remotely
may require specifying a mkdev function to Samba. For more information on these may require specifying a mkdev function to Samba. For more information on these
...@@ -268,11 +270,12 @@ Misc /proc/fs/cifs Flags and Debug Info ...@@ -268,11 +270,12 @@ 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 and shares.
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 as well as per
share statistics, if CONFIG_CIFS_STATS in enabled
in the kernel configuration.
Configuration pseudo-files: Configuration pseudo-files:
MultiuserMount If set to one, more than one CIFS session to MultiuserMount If set to one, more than one CIFS session to
......
...@@ -190,26 +190,26 @@ cifs_stats_read(char *buf, char **beginBuffer, off_t offset, ...@@ -190,26 +190,26 @@ cifs_stats_read(char *buf, char **beginBuffer, off_t offset,
struct cifsTconInfo *tcon; struct cifsTconInfo *tcon;
length = sprintf(buf, length = sprintf(buf,
"Currently Allocated structures\nCIFS Sessions: %d\n", "Resources in use\nCIFS Session: %d\n",
sesInfoAllocCount.counter); sesInfoAllocCount.counter);
buf += length; buf += length;
item_length = item_length =
sprintf(buf,"Shares (unique mount targets): %d\n", sprintf(buf,"Share (unique mount targets): %d\n",
tconInfoAllocCount.counter); tconInfoAllocCount.counter);
length += item_length; length += item_length;
buf += item_length; buf += item_length;
item_length = item_length =
sprintf(buf,"Allocated SMB Request/Response Buffers: %d\n", sprintf(buf,"SMB Request/Response Buffer: %d\n",
bufAllocCount.counter); bufAllocCount.counter);
length += item_length; length += item_length;
buf += item_length; buf += item_length;
item_length = item_length =
sprintf(buf,"Active Operations (MIDs in use): %d\n", sprintf(buf,"Operations (MIDs): %d\n",
midCount.counter); midCount.counter);
length += item_length; length += item_length;
buf += item_length; buf += item_length;
item_length = sprintf(buf, item_length = sprintf(buf,
"%d session %d share reconnects\n", "\n%d session %d share reconnects\n",
tcpSesReconnectCount.counter,tconInfoReconnectCount.counter); tcpSesReconnectCount.counter,tconInfoReconnectCount.counter);
length += item_length; length += item_length;
buf += item_length; buf += item_length;
......
...@@ -1690,16 +1690,17 @@ struct gealist { ...@@ -1690,16 +1690,17 @@ struct gealist {
}; };
struct fea { struct fea {
unsigned char fEA; unsigned char EA_flags;
unsigned char cbName; __u8 name_len;
unsigned short cbValue; __u16 value_len;
char szName[1]; char szName[1];
/* optionally followed by value */
}; };
/* flags for _FEA.fEA */ /* flags for _FEA.fEA */
#define FEA_NEEDEA 0x80 /* need EA bit */ #define FEA_NEEDEA 0x80 /* need EA bit */
struct fealist { struct fealist {
unsigned long cbList; unsigned long list_len;
struct fea list[1]; struct fea list[1];
}; };
......
...@@ -57,7 +57,7 @@ ssize_t cifs_listxattr(struct dentry * direntry, char * ea_data, size_t ea_size) ...@@ -57,7 +57,7 @@ ssize_t cifs_listxattr(struct dentry * direntry, char * ea_data, size_t ea_size)
char * full_path; char * full_path;
if(direntry == NULL) if(direntry == NULL)
return -EIO; return -EIO;
if(direntry->d_inode) if(direntry->d_inode == NULL)
return -EIO; return -EIO;
sb = direntry->d_inode->i_sb; sb = direntry->d_inode->i_sb;
if(sb == NULL) if(sb == NULL)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment