diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2022-07-13 20:16:46 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2022-07-13 21:52:30 -0600 |
commit | db7047c394edbcc713accda2a15f201a5b400ef7 (patch) | |
tree | 0b8fb9c1b4176af762422197cca721145cda91a6 /lib/btrfs/internal/objid.go | |
parent | 166e51d3a6f81834cc89aec36015f05f350be31e (diff) |
Misc tidy up
Diffstat (limited to 'lib/btrfs/internal/objid.go')
-rw-r--r-- | lib/btrfs/internal/objid.go | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/lib/btrfs/internal/objid.go b/lib/btrfs/internal/objid.go index f1d2a2a..fa9eb4d 100644 --- a/lib/btrfs/internal/objid.go +++ b/lib/btrfs/internal/objid.go @@ -6,12 +6,12 @@ package internal import ( "fmt" - - "git.lukeshu.com/btrfs-progs-ng/lib/util" ) type ObjID uint64 +const maxUint64pp = 0x1_00000000_00000000 + const ( // The IDs of the various trees ROOT_TREE_OBJECTID = ObjID(1) // holds pointers to all of the tree roots @@ -30,21 +30,21 @@ const ( DEV_STATS_OBJECTID = ObjID(0) // device stats in the device tree // ??? - BALANCE_OBJECTID = ObjID(util.MaxUint64pp - 4) // for storing balance parameters in the root tree - ORPHAN_OBJECTID = ObjID(util.MaxUint64pp - 5) // orphan objectid for tracking unlinked/truncated files - TREE_LOG_OBJECTID = ObjID(util.MaxUint64pp - 6) // does write ahead logging to speed up fsyncs - TREE_LOG_FIXUP_OBJECTID = ObjID(util.MaxUint64pp - 7) - TREE_RELOC_OBJECTID = ObjID(util.MaxUint64pp - 8) // space balancing - DATA_RELOC_TREE_OBJECTID = ObjID(util.MaxUint64pp - 9) - EXTENT_CSUM_OBJECTID = ObjID(util.MaxUint64pp - 10) // extent checksums all have this objectid - FREE_SPACE_OBJECTID = ObjID(util.MaxUint64pp - 11) // For storing free space cache - FREE_INO_OBJECTID = ObjID(util.MaxUint64pp - 12) // stores the inode number for the free-ino cache - - MULTIPLE_OBJECTIDS = ObjID(util.MaxUint64pp - 255) // dummy objectid represents multiple objectids + BALANCE_OBJECTID = ObjID(maxUint64pp - 4) // for storing balance parameters in the root tree + ORPHAN_OBJECTID = ObjID(maxUint64pp - 5) // orphan objectid for tracking unlinked/truncated files + TREE_LOG_OBJECTID = ObjID(maxUint64pp - 6) // does write ahead logging to speed up fsyncs + TREE_LOG_FIXUP_OBJECTID = ObjID(maxUint64pp - 7) + TREE_RELOC_OBJECTID = ObjID(maxUint64pp - 8) // space balancing + DATA_RELOC_TREE_OBJECTID = ObjID(maxUint64pp - 9) + EXTENT_CSUM_OBJECTID = ObjID(maxUint64pp - 10) // extent checksums all have this objectid + FREE_SPACE_OBJECTID = ObjID(maxUint64pp - 11) // For storing free space cache + FREE_INO_OBJECTID = ObjID(maxUint64pp - 12) // stores the inode number for the free-ino cache + + MULTIPLE_OBJECTIDS = ObjID(maxUint64pp - 255) // dummy objectid represents multiple objectids // All files have objectids in this range. FIRST_FREE_OBJECTID = ObjID(256) - LAST_FREE_OBJECTID = ObjID(util.MaxUint64pp - 256) + LAST_FREE_OBJECTID = ObjID(maxUint64pp - 256) FIRST_CHUNK_TREE_OBJECTID = ObjID(256) |