ocfs2: set i_mode on disk during acl operations
authorMark Fasheh <mfasheh@suse.com>
Mon, 15 Mar 2010 22:39:00 +0000 (15:39 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 26 Apr 2010 14:41:29 +0000 (07:41 -0700)
commit80acb6490eca937a70e00e69fcae35f92ea0ad63
treef111022da2873e8783b578b9c03e2bbd73b22f7c
parent361096052132966bc6a25b0826d59c2c3babc244
ocfs2: set i_mode on disk during acl operations

commit fcefd25ac89239cb57fa198f125a79ff85468c75 upstream.

ocfs2_set_acl() and ocfs2_init_acl() were setting i_mode on the in-memory
inode, but never setting it on the disk copy. Thus, acls were some times not
getting propagated between nodes. This patch fixes the issue by adding a
helper function ocfs2_acl_set_mode() which does this the right way.
ocfs2_set_acl() and ocfs2_init_acl() are then updated to call
ocfs2_acl_set_mode().

Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Signed-off-by: Joel Becker <joel.becker@oracle.com>
Cc: maximilian attems <max@stro.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
fs/ocfs2/acl.c