26 Jul 2012 00:45
[PATCH v2] cifs: obtain file access during backup intent lookup
From: Shirish Pargaonkar <shirishpargaonkar@...> path based querries can fail for lack of access, especially during lookup during open. open itself would actually succeed becasue of back up intent bit but querries (either path or file handle based) do not have a means to specifiy backup intent bit. So querry the file info during lookup using trans2 / findfirst2 / file_id_full_ir_info to obtain file info as well as file_id/inode value. Signed-off-by: Shirish Pargaonkar <shirishpargaonkar@...> Reported-by: Tushar Gosavi <tugosavi@...> --- fs/cifs/cifssmb.c | 38 +++++++++++++++++------------ fs/cifs/inode.c | 67 +++++++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 87 insertions(+), 18 deletions(-) diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c index 4ee522b..f059c0a 100644 --- a/fs/cifs/cifssmb.c +++ b/fs/cifs/cifssmb.c <at> <at> -4257,7 +4257,7 <at> <at> CIFSFindFirst(const int xid, struct cifs_tcon *tcon, int rc = 0; int bytes_returned = 0; int name_len; - __u16 params, byte_count; + __u16 params, byte_count, ffattrs; cFYI(1, "In FindFirst for %s", searchName);(Continue reading)
RSS Feed