summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorLars Ellenberg <lars.ellenberg@linbit.com>2011-02-21 13:21:03 +0100
committerPhilipp Reisner <philipp.reisner@linbit.com>2011-10-14 16:47:46 +0200
commit7ad651b52218eea3f9280dbb353dfe0c42742d85 (patch)
tree52206f862eb6d1999252522e181d833673348ff7 /include
parent46a15bc3ec425b546d140581c28192ab7877ddc4 (diff)
downloadlinux-7ad651b52218eea3f9280dbb353dfe0c42742d85.tar.gz
linux-7ad651b52218eea3f9280dbb353dfe0c42742d85.tar.bz2
linux-7ad651b52218eea3f9280dbb353dfe0c42742d85.zip
drbd: new on-disk activity log transaction format
Use a new on-disk transaction format for the activity log, which allows for multiple changes to the active set per transaction. Using 4k transaction blocks, we can now get rid of the work-around code to deal with devices not supporting 512 byte logical block size. Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/drbd.h4
-rw-r--r--include/linux/drbd_limits.h8
2 files changed, 9 insertions, 3 deletions
diff --git a/include/linux/drbd.h b/include/linux/drbd.h
index 35fc08a0a552..70a688b92c1b 100644
--- a/include/linux/drbd.h
+++ b/include/linux/drbd.h
@@ -336,6 +336,10 @@ enum drbd_timeout_flag {
#define DRBD_MAGIC 0x83740267
#define DRBD_MAGIC_BIG 0x835a
+/* how I came up with this magic?
+ * base64 decode "actlog==" ;) */
+#define DRBD_AL_MAGIC 0x69cb65a2
+
/* these are of type "int" */
#define DRBD_MD_INDEX_INTERNAL -1
#define DRBD_MD_INDEX_FLEX_EXT -2
diff --git a/include/linux/drbd_limits.h b/include/linux/drbd_limits.h
index 447c36752385..75f05af33725 100644
--- a/include/linux/drbd_limits.h
+++ b/include/linux/drbd_limits.h
@@ -102,10 +102,12 @@
#define DRBD_RATE_DEF 250 /* kb/second */
/* less than 7 would hit performance unnecessarily.
- * 3833 is the largest prime that still does fit
- * into 64 sectors of activity log */
+ * 919 slots context information per transaction,
+ * 32k activity log, 4k transaction size,
+ * one transaction in flight:
+ * 919 * 7 = 6433 */
#define DRBD_AL_EXTENTS_MIN 7
-#define DRBD_AL_EXTENTS_MAX 3833
+#define DRBD_AL_EXTENTS_MAX 6433
#define DRBD_AL_EXTENTS_DEF 127
#define DRBD_AFTER_MIN -1