]> git.sesse.net Git - bcachefs-tools-debian/blob - libbcachefs/fs-common.h
rust: bump rpassword to v7.x
[bcachefs-tools-debian] / libbcachefs / fs-common.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _BCACHEFS_FS_COMMON_H
3 #define _BCACHEFS_FS_COMMON_H
4
5 struct posix_acl;
6
7 #define BCH_CREATE_TMPFILE              (1U << 0)
8 #define BCH_CREATE_SUBVOL               (1U << 1)
9 #define BCH_CREATE_SNAPSHOT             (1U << 2)
10 #define BCH_CREATE_SNAPSHOT_RO          (1U << 3)
11
12 int bch2_create_trans(struct btree_trans *, subvol_inum,
13                       struct bch_inode_unpacked *,
14                       struct bch_inode_unpacked *,
15                       const struct qstr *,
16                       uid_t, gid_t, umode_t, dev_t,
17                       struct posix_acl *,
18                       struct posix_acl *,
19                       subvol_inum, unsigned);
20
21 int bch2_link_trans(struct btree_trans *,
22                     subvol_inum, struct bch_inode_unpacked *,
23                     subvol_inum, struct bch_inode_unpacked *,
24                     const struct qstr *);
25
26 int bch2_unlink_trans(struct btree_trans *, subvol_inum,
27                       struct bch_inode_unpacked *,
28                       struct bch_inode_unpacked *,
29                       const struct qstr *, bool);
30
31 int bch2_rename_trans(struct btree_trans *,
32                       subvol_inum, struct bch_inode_unpacked *,
33                       subvol_inum, struct bch_inode_unpacked *,
34                       struct bch_inode_unpacked *,
35                       struct bch_inode_unpacked *,
36                       const struct qstr *,
37                       const struct qstr *,
38                       enum bch_rename_mode);
39
40 bool bch2_reinherit_attrs(struct bch_inode_unpacked *,
41                           struct bch_inode_unpacked *);
42
43 #endif /* _BCACHEFS_FS_COMMON_H */