ctree.h (33268eaf0b3db5e2bd12c0ada81a8e8f87a46d68) | ctree.h (7b1287662304c3cb05cb38f5e3e2d69f386e8f10) |
---|---|
1/* 2 * Copyright (C) 2007 Oracle. All rights reserved. 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public 6 * License v2 as published by the Free Software Foundation. 7 * 8 * This program is distributed in the hope that it will be useful, --- 60 unchanged lines hidden (view full) --- 69#define BTRFS_DEV_TREE_OBJECTID 4ULL 70 71/* one per subvolume, storing files and directories */ 72#define BTRFS_FS_TREE_OBJECTID 5ULL 73 74/* directory objectid inside the root tree */ 75#define BTRFS_ROOT_TREE_DIR_OBJECTID 6ULL 76 | 1/* 2 * Copyright (C) 2007 Oracle. All rights reserved. 3 * 4 * This program is free software; you can redistribute it and/or 5 * modify it under the terms of the GNU General Public 6 * License v2 as published by the Free Software Foundation. 7 * 8 * This program is distributed in the hope that it will be useful, --- 60 unchanged lines hidden (view full) --- 69#define BTRFS_DEV_TREE_OBJECTID 4ULL 70 71/* one per subvolume, storing files and directories */ 72#define BTRFS_FS_TREE_OBJECTID 5ULL 73 74/* directory objectid inside the root tree */ 75#define BTRFS_ROOT_TREE_DIR_OBJECTID 6ULL 76 |
77/* orhpan objectid for tracking unlinked/truncated files */ 78#define BTRFS_ORPHAN_OBJECTID -5ULL 79 |
|
77/* 78 * All files have objectids higher than this. 79 */ 80#define BTRFS_FIRST_FREE_OBJECTID 256ULL 81#define BTRFS_FIRST_CHUNK_TREE_OBJECTID 256ULL 82 83 84/* --- 556 unchanged lines hidden (view full) --- 641 struct btrfs_key defrag_max; 642 int defrag_running; 643 int defrag_level; 644 char *name; 645 int in_sysfs; 646 647 /* the dirty list is only used by non-reference counted roots */ 648 struct list_head dirty_list; | 80/* 81 * All files have objectids higher than this. 82 */ 83#define BTRFS_FIRST_FREE_OBJECTID 256ULL 84#define BTRFS_FIRST_CHUNK_TREE_OBJECTID 256ULL 85 86 87/* --- 556 unchanged lines hidden (view full) --- 644 struct btrfs_key defrag_max; 645 int defrag_running; 646 int defrag_level; 647 char *name; 648 int in_sysfs; 649 650 /* the dirty list is only used by non-reference counted roots */ 651 struct list_head dirty_list; |
652 653 spinlock_t orphan_lock; 654 struct list_head orphan_list; |
|
649}; 650 651/* 652 653 * inode items have the data typically returned from stat and store other 654 * info about object characteristics. There is one for every file and dir in 655 * the FS 656 */ 657#define BTRFS_INODE_ITEM_KEY 1 658#define BTRFS_INODE_REF_KEY 2 659#define BTRFS_XATTR_ITEM_KEY 8 | 655}; 656 657/* 658 659 * inode items have the data typically returned from stat and store other 660 * info about object characteristics. There is one for every file and dir in 661 * the FS 662 */ 663#define BTRFS_INODE_ITEM_KEY 1 664#define BTRFS_INODE_REF_KEY 2 665#define BTRFS_XATTR_ITEM_KEY 8 |
666#define BTRFS_ORPHAN_ITEM_KEY 9 |
|
660/* reserve 2-15 close to the inode for later flexibility */ 661 662/* 663 * dir items are the name -> inode pointers in a directory. There is one 664 * for every name in a directory. 665 */ 666#define BTRFS_DIR_ITEM_KEY 16 667#define BTRFS_DIR_INDEX_KEY 17 --- 887 unchanged lines hidden (view full) --- 1555 struct btrfs_root *root, const char *name, 1556 u16 name_len, const void *data, u16 data_len, 1557 u64 dir); 1558struct btrfs_dir_item *btrfs_lookup_xattr(struct btrfs_trans_handle *trans, 1559 struct btrfs_root *root, 1560 struct btrfs_path *path, u64 dir, 1561 const char *name, u16 name_len, 1562 int mod); | 667/* reserve 2-15 close to the inode for later flexibility */ 668 669/* 670 * dir items are the name -> inode pointers in a directory. There is one 671 * for every name in a directory. 672 */ 673#define BTRFS_DIR_ITEM_KEY 16 674#define BTRFS_DIR_INDEX_KEY 17 --- 887 unchanged lines hidden (view full) --- 1562 struct btrfs_root *root, const char *name, 1563 u16 name_len, const void *data, u16 data_len, 1564 u64 dir); 1565struct btrfs_dir_item *btrfs_lookup_xattr(struct btrfs_trans_handle *trans, 1566 struct btrfs_root *root, 1567 struct btrfs_path *path, u64 dir, 1568 const char *name, u16 name_len, 1569 int mod); |
1570 1571/* orphan.c */ 1572int btrfs_insert_orphan_item(struct btrfs_trans_handle *trans, 1573 struct btrfs_root *root, u64 offset); 1574int btrfs_del_orphan_item(struct btrfs_trans_handle *trans, 1575 struct btrfs_root *root, u64 offset); 1576 |
|
1563/* inode-map.c */ 1564int btrfs_find_free_objectid(struct btrfs_trans_handle *trans, 1565 struct btrfs_root *fs_root, 1566 u64 dirid, u64 *objectid); 1567int btrfs_find_highest_inode(struct btrfs_root *fs_root, u64 *objectid); 1568 1569/* inode-item.c */ 1570int btrfs_insert_inode_ref(struct btrfs_trans_handle *trans, --- 134 unchanged lines hidden --- | 1577/* inode-map.c */ 1578int btrfs_find_free_objectid(struct btrfs_trans_handle *trans, 1579 struct btrfs_root *fs_root, 1580 u64 dirid, u64 *objectid); 1581int btrfs_find_highest_inode(struct btrfs_root *fs_root, u64 *objectid); 1582 1583/* inode-item.c */ 1584int btrfs_insert_inode_ref(struct btrfs_trans_handle *trans, --- 134 unchanged lines hidden --- |