cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
* [Cluster-devel] [PATCH v2] GFS2: make sure S_NOSEC flag isn't overwritten
@ 2015-04-15 21:15 Benjamin Marzinski
  0 siblings, 0 replies; 2+ messages in thread
From: Benjamin Marzinski @ 2015-04-15 21:15 UTC (permalink / raw)
  To: cluster-devel.redhat.com

At the end of gfs2_set_inode_flags inode->i_flags is set to flags, so
we should be modifying flags instead of inode->i_flags, so it isn't
overwritten.

Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
---
 fs/gfs2/file.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/gfs2/file.c b/fs/gfs2/file.c
index 6e600ab..80d1fd4 100644
--- a/fs/gfs2/file.c
+++ b/fs/gfs2/file.c
@@ -181,7 +181,7 @@ void gfs2_set_inode_flags(struct inode *inode)
 
 	flags &= ~(S_SYNC|S_APPEND|S_IMMUTABLE|S_NOATIME|S_DIRSYNC|S_NOSEC);
 	if ((ip->i_eattr == 0) && !is_sxid(inode->i_mode))
-		inode->i_flags |= S_NOSEC;
+		flags |= S_NOSEC;
 	if (ip->i_diskflags & GFS2_DIF_IMMUTABLE)
 		flags |= S_IMMUTABLE;
 	if (ip->i_diskflags & GFS2_DIF_APPENDONLY)
-- 
2.1.0



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [Cluster-devel] [PATCH v2] GFS2: make sure S_NOSEC flag isn't overwritten
  2015-04-15 18:56 [Cluster-devel] [PATCH] " Benjamin Marzinski
@ 2015-05-05 18:42 ` Bob Peterson
  0 siblings, 0 replies; 2+ messages in thread
From: Bob Peterson @ 2015-05-05 18:42 UTC (permalink / raw)
  To: cluster-devel.redhat.com

----- Original Message -----
> At the end of gfs2_set_inode_flags inode->i_flags is set to flags, so
> we should be mondifying flags instead of inode->i_flags, so it isn't
> overwritten.
> 
> Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
> ---

Hi,

The v2 version of the patch is now in the for-next branch of the linux-gfs2 tree:
https://git.kernel.org/cgit/linux/kernel/git/gfs2/linux-gfs2.git/commit/fs/gfs2?h=for-next&id=01e64ee40ad741037352d1d6202eaa432f833eb4

Regards,

Bob Peterson
Red Hat File Systems



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-05-05 18:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-15 21:15 [Cluster-devel] [PATCH v2] GFS2: make sure S_NOSEC flag isn't overwritten Benjamin Marzinski
  -- strict thread matches above, loose matches on Subject: below --
2015-04-15 18:56 [Cluster-devel] [PATCH] " Benjamin Marzinski
2015-05-05 18:42 ` [Cluster-devel] [PATCH v2] " Bob Peterson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).