aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/drbd/drbd_req.h
diff options
context:
space:
mode:
authorPhilipp Reisner <philipp.reisner@linbit.com>2010-08-31 06:00:50 -0400
committerPhilipp Reisner <philipp.reisner@linbit.com>2010-10-14 12:38:26 -0400
commit0778286a133d2d3f81861a4e5db308e359583006 (patch)
tree14bdfe375481d8954ada1ddaa0bc84fcaba4e23d /drivers/block/drbd/drbd_req.h
parentd53733893dc43f4ebb5be510863c5debf0f8990b (diff)
drbd: Disable activity log updates when the whole device is out of sync
When the complete device is marked as out of sync, we can disable updates of the on disk AL. Currently AL updates are only disabled if one uses the "invalidate-remote" command on an unconnected, primary device, or when at attach time all bits in the bitmap are set. As of now, AL updated do not get disabled when a all bits becomes set due to application writes to an unconnected DRBD device. While this is a missing feature, it is not considered important, and might get added later. BTW, after initializing a "one legged" DRBD device drbdadm create-md resX drbdadm -- --force primary resX AL updates also get disabled, until the first connect. Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Diffstat (limited to 'drivers/block/drbd/drbd_req.h')
-rw-r--r--drivers/block/drbd/drbd_req.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/block/drbd/drbd_req.h b/drivers/block/drbd/drbd_req.h
index f2e45aaa2cd5..181ea0364822 100644
--- a/drivers/block/drbd/drbd_req.h
+++ b/drivers/block/drbd/drbd_req.h
@@ -189,6 +189,9 @@ enum drbd_req_state_bits {
189 189
190 /* Set when this is a write, clear for a read */ 190 /* Set when this is a write, clear for a read */
191 __RQ_WRITE, 191 __RQ_WRITE,
192
193 /* Should call drbd_al_complete_io() for this request... */
194 __RQ_IN_ACT_LOG,
192}; 195};
193 196
194#define RQ_LOCAL_PENDING (1UL << __RQ_LOCAL_PENDING) 197#define RQ_LOCAL_PENDING (1UL << __RQ_LOCAL_PENDING)
@@ -208,6 +211,7 @@ enum drbd_req_state_bits {
208#define RQ_NET_MASK (((1UL << __RQ_NET_MAX)-1) & ~RQ_LOCAL_MASK) 211#define RQ_NET_MASK (((1UL << __RQ_NET_MAX)-1) & ~RQ_LOCAL_MASK)
209 212
210#define RQ_WRITE (1UL << __RQ_WRITE) 213#define RQ_WRITE (1UL << __RQ_WRITE)
214#define RQ_IN_ACT_LOG (1UL << __RQ_IN_ACT_LOG)
211 215
212/* For waking up the frozen transfer log mod_req() has to return if the request 216/* For waking up the frozen transfer log mod_req() has to return if the request
213 should be counted in the epoch object*/ 217 should be counted in the epoch object*/