diff mbox

[5/6] Btrfs: subpagesize-blocksize: Hardcode MAX_EXTENT_BUFFERS_PER_PAGE to 2.

Message ID 1394634033-2528-6-git-send-email-chandan@linux.vnet.ibm.com (mailing list archive)
State Deferred
Headers show

Commit Message

Chandan Rajendra March 12, 2014, 2:20 p.m. UTC
With 2k blocksize the maximum number extent buffers per page will be 2. We
should be computing this value at runtime. For now, Let's work with the
hardcoded value.

Signed-off-by: Chandan Rajendra <chandan@linux.vnet.ibm.com>
---
 fs/btrfs/extent_io.h | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/fs/btrfs/extent_io.h b/fs/btrfs/extent_io.h
index 71100ad..6cc5ed2 100644
--- a/fs/btrfs/extent_io.h
+++ b/fs/btrfs/extent_io.h
@@ -123,7 +123,12 @@  struct extent_state {
 
 #define INLINE_EXTENT_BUFFER_PAGES 16
 #define MAX_INLINE_EXTENT_BUFFER_SIZE (INLINE_EXTENT_BUFFER_PAGES * PAGE_CACHE_SIZE)
-#define MAX_EXTENT_BUFFERS_PER_PAGE 16
+
+#if 0
+#define MAX_EXTENT_BUFFERS_PER_PAGE 1
+#else
+#define MAX_EXTENT_BUFFERS_PER_PAGE 2
+#endif
 
 struct extent_buffer {
 	u64 start;