Skip to contentSkip to conversation

gfs2: check rename2 flags at once

PATCH In review Fabian Frederick 2 participants 2 messages May 3, 2017 – May 4, 2017

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/2 gfs2: check rename2 flags at once

There's no need to update flags in gfs2_rename2()
This will ease whiteout addition.

---
 fs/gfs2/inode.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
fs/gfs2/inode.c +1 -3
index 9f605ea..9698796 100644
@@ -1706,9 +1706,7 @@ static int gfs2_rename2(struct inode *odir, struct dentry *odentry,
 			struct inode *ndir, struct dentry *ndentry,
 			unsigned int flags)
 {
-	flags &= ~RENAME_NOREPLACE;
-
-	if (flags & ~RENAME_EXCHANGE)
+	if (flags & ~(RENAME_NOREPLACE | RENAME_EXCHANGE))
 		return -EINVAL;
 
 	if (flags & RENAME_EXCHANGE)
Signature · 1 line
2.9.3
#1 lore raw

----- Original Message -----

| There's no need to update flags in gfs2_rename2()
| This will ease whiteout addition.
| 
| Signed-off-by: Fabian Frederick <[email protected]>
| ---

Hi Fabian,

Your patches look good. I'll push them to the for-next branch of our repo after the merge window is closed.

Regards,

Bob Peterson
Red Hat File Systems