[RFC PATCH v3 2/5] UBIFS: ACL: set ACL interfaces in inode_operations
Sheng Yong
shengyong1 at huawei.com
Fri Sep 11 02:09:54 PDT 2015
Set [get|set]_acl interfaces in inode_operations for directory, file,
and symbol link.
Signed-off-by: Sheng Yong <shengyong1 at huawei.com>
---
fs/ubifs/dir.c | 4 ++++
fs/ubifs/file.c | 8 ++++++++
2 files changed, 12 insertions(+)
diff --git a/fs/ubifs/dir.c b/fs/ubifs/dir.c
index 5c27c66..69ccc78 100644
--- a/fs/ubifs/dir.c
+++ b/fs/ubifs/dir.c
@@ -1188,6 +1188,10 @@ const struct inode_operations ubifs_dir_inode_operations = {
.getxattr = ubifs_getxattr,
.listxattr = ubifs_listxattr,
.removexattr = ubifs_removexattr,
+#ifdef CONFIG_UBIFS_FS_POSIX_ACL
+ .get_acl = ubifs_get_acl,
+ .set_acl = ubifs_set_acl,
+#endif
};
const struct file_operations ubifs_dir_operations = {
diff --git a/fs/ubifs/file.c b/fs/ubifs/file.c
index a3dfe2a..58298f8 100644
--- a/fs/ubifs/file.c
+++ b/fs/ubifs/file.c
@@ -1557,6 +1557,10 @@ const struct inode_operations ubifs_file_inode_operations = {
.getxattr = ubifs_getxattr,
.listxattr = ubifs_listxattr,
.removexattr = ubifs_removexattr,
+#ifdef CONFIG_UBIFS_FS_POSIX_ACL
+ .get_acl = ubifs_get_acl,
+ .set_acl = ubifs_set_acl,
+#endif
};
const struct inode_operations ubifs_symlink_inode_operations = {
@@ -1568,6 +1572,10 @@ const struct inode_operations ubifs_symlink_inode_operations = {
.getxattr = ubifs_getxattr,
.listxattr = ubifs_listxattr,
.removexattr = ubifs_removexattr,
+#ifdef CONFIG_UBIFS_FS_POSIX_ACL
+ .get_acl = ubifs_get_acl,
+ .set_acl = ubifs_set_acl,
+#endif
};
const struct file_operations ubifs_file_operations = {
--
1.9.1
More information about the linux-mtd
mailing list