summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/ctree.h
diff options
context:
space:
mode:
authorZheng Yan <zheng.yan@oracle.com>2008-09-05 16:43:53 -0400
committerChris Mason <chris.mason@oracle.com>2008-09-25 11:04:07 -0400
commit6527cdbe68a27a2ee745f36d001aa32d0f46f370 (patch)
tree2525855633856050a854cabd6dc46b3c955d3b40 /fs/btrfs/ctree.h
parentb214107eda845f9a5851ae198f5b972e0dc30c45 (diff)
downloadkernel-crypto-6527cdbe68a27a2ee745f36d001aa32d0f46f370.tar.gz
kernel-crypto-6527cdbe68a27a2ee745f36d001aa32d0f46f370.tar.xz
kernel-crypto-6527cdbe68a27a2ee745f36d001aa32d0f46f370.zip
Btrfs: Update find free objectid function for orphan cleanup code
Orphan items use BTRFS_ORPHAN_OBJECTID (-5UUL) as key objectid. This affects the find free objectid functions, inode objectid can easily overflow after orphan file cleanup. --- Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r--fs/btrfs/ctree.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index 754c738ec2e..2ed6918f32e 100644
--- a/fs/btrfs/ctree.h
+++ b/fs/btrfs/ctree.h
@@ -82,9 +82,10 @@ struct btrfs_ordered_sum;
#define BTRFS_TREE_LOG_FIXUP_OBJECTID -7ULL
/*
- * All files have objectids higher than this.
+ * All files have objectids in this range.
*/
#define BTRFS_FIRST_FREE_OBJECTID 256ULL
+#define BTRFS_LAST_FREE_OBJECTID -256ULL
#define BTRFS_FIRST_CHUNK_TREE_OBJECTID 256ULL