Lines Matching defs:inode
144 * and write data. For any given inode, we should have one or more
148 * Each cap is referenced by the inode's i_caps rbtree and by per-mds
188 struct list_head i_list; // per inode
258 * We cache inode xattrs as an encoded blob until they are first used,
314 * Ceph inode.
360 * is also protected by the inode's i_ceph_lock. Walking s_cap_dirty
371 * holding the i_ceph_lock for this inode.
377 * reduce the tid to 8 bits if we're concerned about inode size. */
413 struct list_head i_unsafe_iops; /* uncommitted mds inode ops */
433 struct inode vfs_inode; /* at end */
437 ceph_inode(const struct inode *inode)
439 return container_of(inode, struct ceph_inode_info, vfs_inode);
443 ceph_inode_to_client(const struct inode *inode)
445 return (struct ceph_fs_client *)inode->i_sb->s_fs_info;
461 ceph_vino(const struct inode *inode)
463 return ceph_inode(inode)->i_vino;
476 * Inode numbers in cephfs are 64 bits, but inode->i_ino is 32-bits on
491 static inline u64 ceph_ino(struct inode *inode)
493 return ceph_inode(inode)->i_vino.ino;
496 static inline u64 ceph_snap(struct inode *inode)
498 return ceph_inode(inode)->i_vino.snap;
502 * ceph_present_ino - format an inode number for presentation to userland
503 * @sb: superblock where the inode lives
504 * @ino: inode number to (possibly) convert
518 static inline u64 ceph_present_inode(struct inode *inode)
520 return ceph_present_ino(inode->i_sb, ceph_ino(inode));
523 static inline int ceph_ino_compare(struct inode *inode, void *data)
526 struct ceph_inode_info *ci = ceph_inode(inode);
547 WARN_RATELIMIT(1, "Attempt to access reserved inode number 0x%llx", vino.ino);
553 static inline struct inode *ceph_find_inode(struct super_block *sb,
560 * NB: The hashval will be run through the fs/inode.c hash function
561 * anyway, so there is no need to squash the inode number down to
569 * Ceph inode.
581 #define CEPH_I_ODIRECT (1 << 11) /* inode in direct I/O mode */
586 * Masks of ceph inode work.
593 * We set the ERROR_WRITE bit when we start seeing write errors on an inode
655 static inline void ceph_dir_clear_complete(struct inode *inode)
657 __ceph_dir_clear_complete(ceph_inode(inode));
660 static inline void ceph_dir_clear_ordered(struct inode *inode)
662 __ceph_dir_clear_ordered(ceph_inode(inode));
665 static inline bool ceph_dir_is_complete_ordered(struct inode *inode)
667 bool ret = __ceph_dir_is_complete_ordered(ceph_inode(inode));
856 struct inode *inode;
953 /* inode.c */
959 extern struct inode *ceph_alloc_inode(struct super_block *sb);
960 extern void ceph_evict_inode(struct inode *inode);
961 extern void ceph_free_inode(struct inode *inode);
963 extern struct inode *ceph_get_inode(struct super_block *sb,
965 extern struct inode *ceph_get_snapdir(struct inode *parent);
966 extern int ceph_fill_file_size(struct inode *inode, int issued,
968 extern void ceph_fill_file_time(struct inode *inode, int issued,
972 extern int ceph_fill_inode(struct inode *inode, struct page *locked_page,
982 extern int ceph_inode_holds_cap(struct inode *inode, int mask);
984 extern bool ceph_inode_set_size(struct inode *inode, loff_t size);
985 extern void __ceph_do_pending_vmtruncate(struct inode *inode);
986 extern void ceph_queue_vmtruncate(struct inode *inode);
987 extern void ceph_queue_invalidate(struct inode *inode);
988 extern void ceph_queue_writeback(struct inode *inode);
989 extern void ceph_async_iput(struct inode *inode);
991 extern int __ceph_do_getattr(struct inode *inode, struct page *locked_page,
993 static inline int ceph_do_getattr(struct inode *inode, int mask, bool force)
995 return __ceph_do_getattr(inode, NULL, mask, force);
997 extern int ceph_permission(struct inode *inode, int mask);
998 extern int __ceph_setattr(struct inode *inode, struct iattr *attr);
1004 int __ceph_setxattr(struct inode *, const char *, const void *, size_t, int);
1005 ssize_t __ceph_getxattr(struct inode *, const char *, void *, size_t);
1024 extern bool ceph_security_xattr_deadlock(struct inode *in);
1025 extern bool ceph_security_xattr_wanted(struct inode *in);
1027 static inline bool ceph_security_xattr_deadlock(struct inode *in)
1031 static inline bool ceph_security_xattr_wanted(struct inode *in)
1040 static inline void ceph_security_invalidate_secctx(struct inode *inode)
1042 security_inode_invalidate_secctx(inode);
1050 static inline void ceph_security_invalidate_secctx(struct inode *inode)
1060 struct posix_acl *ceph_get_acl(struct inode *, int);
1061 int ceph_set_acl(struct inode *inode, struct posix_acl *acl, int type);
1062 int ceph_pre_init_acls(struct inode *dir, umode_t *mode,
1064 void ceph_init_inode_acls(struct inode *inode,
1067 static inline void ceph_forget_all_cached_acls(struct inode *inode)
1069 forget_all_cached_acls(inode);
1077 static inline int ceph_pre_init_acls(struct inode *dir, umode_t *mode,
1082 static inline void ceph_init_inode_acls(struct inode *inode,
1086 static inline int ceph_acl_chmod(struct dentry *dentry, struct inode *inode)
1091 static inline void ceph_forget_all_cached_acls(struct inode *inode)
1103 extern void ceph_add_cap(struct inode *inode,
1112 extern int ceph_is_any_caps(struct inode *inode);
1114 extern int ceph_write_inode(struct inode *inode, struct writeback_control *wbc);
1133 extern void __ceph_remove_capsnap(struct inode *inode,
1136 extern void ceph_remove_capsnap(struct inode *inode,
1146 extern int ceph_drop_caps_for_unlink(struct inode *inode);
1147 extern int ceph_encode_inode_release(void **p, struct inode *inode,
1150 struct inode *dir,
1155 extern int ceph_try_get_caps(struct inode *inode,
1168 extern int ceph_pool_perm_check(struct inode *inode, int need);
1174 extern int ceph_renew_caps(struct inode *inode, int fmode);
1175 extern int ceph_open(struct inode *inode, struct file *file);
1176 extern int ceph_atomic_open(struct inode *dir, struct dentry *dentry,
1178 extern int ceph_release(struct inode *inode, struct file *filp);
1179 extern void ceph_fill_inline_data(struct inode *inode, struct page *locked_page,
1190 extern int ceph_handle_notrace_create(struct inode *dir, struct dentry *dentry);
1200 extern unsigned ceph_dentry_hash(struct inode *dir, struct dentry *dn);
1208 struct inode *ceph_lookup_inode(struct super_block *sb, u64 ino);
1214 extern void ceph_count_locks(struct inode *inode, int *p_num, int *f_num);
1215 extern int ceph_encode_locks_to_buffer(struct inode *inode,
1233 extern void ceph_adjust_quota_realms_count(struct inode *inode, bool inc);
1251 extern bool ceph_quota_is_max_files_exceeded(struct inode *inode);
1252 extern bool ceph_quota_is_max_bytes_exceeded(struct inode *inode,
1254 extern bool ceph_quota_is_max_bytes_approaching(struct inode *inode,
1259 struct inode *old, struct inode *new);