Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2)  * Copyright IBM Corporation, 2010
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3)  * Author Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5)  * This program is free software; you can redistribute it and/or modify it
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)  * under the terms of version 2.1 of the GNU Lesser General Public License
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7)  * as published by the Free Software Foundation.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9)  * This program is distributed in the hope that it would be useful, but
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10)  * WITHOUT ANY WARRANTY; without even the implied warranty of
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11)  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13)  */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) #ifndef FS_9P_ACL_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) #define FS_9P_ACL_H
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) #ifdef CONFIG_9P_FS_POSIX_ACL
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) extern int v9fs_get_acl(struct inode *, struct p9_fid *);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) extern struct posix_acl *v9fs_iop_get_acl(struct inode *inode, int type);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) extern int v9fs_acl_chmod(struct inode *, struct p9_fid *);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) extern int v9fs_set_create_acl(struct inode *, struct p9_fid *,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 			       struct posix_acl *, struct posix_acl *);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) extern int v9fs_acl_mode(struct inode *dir, umode_t *modep,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 			 struct posix_acl **dpacl, struct posix_acl **pacl);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) extern void v9fs_put_acl(struct posix_acl *dacl, struct posix_acl *acl);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) #else
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) #define v9fs_iop_get_acl NULL
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) static inline int v9fs_get_acl(struct inode *inode, struct p9_fid *fid)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) static inline int v9fs_acl_chmod(struct inode *inode, struct p9_fid *fid)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) static inline int v9fs_set_create_acl(struct inode *inode,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) 				      struct p9_fid *fid,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 				      struct posix_acl *dacl,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) 				      struct posix_acl *acl)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) static inline void v9fs_put_acl(struct posix_acl *dacl,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) 				struct posix_acl *acl)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 45) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 46) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 47) static inline int v9fs_acl_mode(struct inode *dir, umode_t *modep,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 48) 				struct posix_acl **dpacl,
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 49) 				struct posix_acl **pacl)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 50) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 51) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 52) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 53) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 54) #endif
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 55) #endif /* FS_9P_XATTR_H */