diff options
-rw-r--r-- | fs/cifs/smb2inode.c | 9 | ||||
-rw-r--r-- | fs/cifs/smb2ops.c | 1 | ||||
-rw-r--r-- | fs/cifs/smb2proto.h | 2 |
3 files changed, 12 insertions, 0 deletions
diff --git a/fs/cifs/smb2inode.c b/fs/cifs/smb2inode.c index e129527a707a..2aa5cb08c526 100644 --- a/fs/cifs/smb2inode.c +++ b/fs/cifs/smb2inode.c | |||
@@ -152,3 +152,12 @@ smb2_mkdir_setinfo(struct inode *inode, const char *name, | |||
152 | if (tmprc == 0) | 152 | if (tmprc == 0) |
153 | cifs_i->cifsAttrs = dosattrs; | 153 | cifs_i->cifsAttrs = dosattrs; |
154 | } | 154 | } |
155 | |||
156 | int | ||
157 | smb2_rmdir(const unsigned int xid, struct cifs_tcon *tcon, const char *name, | ||
158 | struct cifs_sb_info *cifs_sb) | ||
159 | { | ||
160 | return smb2_open_op_close(xid, tcon, cifs_sb, name, DELETE, FILE_OPEN, | ||
161 | 0, CREATE_NOT_FILE | CREATE_DELETE_ON_CLOSE, | ||
162 | NULL, SMB2_OP_DELETE); | ||
163 | } | ||
diff --git a/fs/cifs/smb2ops.c b/fs/cifs/smb2ops.c index cc74871d2598..826209bf3684 100644 --- a/fs/cifs/smb2ops.c +++ b/fs/cifs/smb2ops.c | |||
@@ -320,6 +320,7 @@ struct smb_version_operations smb21_operations = { | |||
320 | .build_path_to_root = smb2_build_path_to_root, | 320 | .build_path_to_root = smb2_build_path_to_root, |
321 | .mkdir = smb2_mkdir, | 321 | .mkdir = smb2_mkdir, |
322 | .mkdir_setinfo = smb2_mkdir_setinfo, | 322 | .mkdir_setinfo = smb2_mkdir_setinfo, |
323 | .rmdir = smb2_rmdir, | ||
323 | }; | 324 | }; |
324 | 325 | ||
325 | struct smb_version_values smb21_values = { | 326 | struct smb_version_values smb21_values = { |
diff --git a/fs/cifs/smb2proto.h b/fs/cifs/smb2proto.h index f9925082737c..bfaa7b148afd 100644 --- a/fs/cifs/smb2proto.h +++ b/fs/cifs/smb2proto.h | |||
@@ -57,6 +57,8 @@ extern int smb2_mkdir(const unsigned int xid, struct cifs_tcon *tcon, | |||
57 | extern void smb2_mkdir_setinfo(struct inode *inode, const char *full_path, | 57 | extern void smb2_mkdir_setinfo(struct inode *inode, const char *full_path, |
58 | struct cifs_sb_info *cifs_sb, | 58 | struct cifs_sb_info *cifs_sb, |
59 | struct cifs_tcon *tcon, const unsigned int xid); | 59 | struct cifs_tcon *tcon, const unsigned int xid); |
60 | extern int smb2_rmdir(const unsigned int xid, struct cifs_tcon *tcon, | ||
61 | const char *name, struct cifs_sb_info *cifs_sb); | ||
60 | 62 | ||
61 | /* | 63 | /* |
62 | * SMB2 Worker functions - most of protocol specific implementation details | 64 | * SMB2 Worker functions - most of protocol specific implementation details |