]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
drbd: Removed checks for REQ_HARDBARRIER on incomming BIOs
authorPhilipp Reisner <philipp.reisner@linbit.com>
Wed, 25 Aug 2010 08:47:17 +0000 (10:47 +0200)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Sat, 23 Oct 2010 11:02:34 +0000 (13:02 +0200)
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
drivers/block/drbd/drbd_int.h
drivers/block/drbd/drbd_main.c
drivers/block/drbd/drbd_req.c

index 575bfba1b0da3de4777f065c29630b2f6b031c3a..0c527d2816221711e48ff6855b754735fed926d1 100644 (file)
@@ -832,7 +832,6 @@ enum {
                                 * Gets cleared when the state.conn
                                 * goes into C_CONNECTED state. */
        WRITE_BM_AFTER_RESYNC,  /* A kmalloc() during resync failed */
-       NO_BARRIER_SUPP,        /* underlying block device doesn't implement barriers */
        CONSIDER_RESYNC,
 
        MD_NO_FUA,              /* Users wants us to not use FUA/FLUSH on meta data dev */
index 8e0d707df23d92d084b7bc3fed69d9cd1423510c..d7072bf0630dada684326934ed78cceeb4d1709e 100644 (file)
@@ -2788,11 +2788,6 @@ void drbd_init_set_defaults(struct drbd_conf *mdev)
 
        drbd_set_defaults(mdev);
 
-       /* for now, we do NOT yet support it,
-        * even though we start some framework
-        * to eventually support barriers */
-       set_bit(NO_BARRIER_SUPP, &mdev->flags);
-
        atomic_set(&mdev->ap_bio_cnt, 0);
        atomic_set(&mdev->ap_pending_cnt, 0);
        atomic_set(&mdev->rs_pending_cnt, 0);
index 5c2254853559e20e908a650bcedadb2113ed8e98..11a75d32a2e27f0d78c26b511921780f4d336264 100644 (file)
@@ -1032,20 +1032,6 @@ int drbd_make_request_26(struct request_queue *q, struct bio *bio)
                return 0;
        }
 
-       /* Reject barrier requests if we know the underlying device does
-        * not support them.
-        * XXX: Need to get this info from peer as well some how so we
-        * XXX: reject if EITHER side/data/metadata area does not support them.
-        *
-        * because of those XXX, this is not yet enabled,
-        * i.e. in drbd_init_set_defaults we set the NO_BARRIER_SUPP bit.
-        */
-       if (unlikely(bio->bi_rw & REQ_HARDBARRIER) && test_bit(NO_BARRIER_SUPP, &mdev->flags)) {
-               /* dev_warn(DEV, "Rejecting barrier request as underlying device does not support\n"); */
-               bio_endio(bio, -EOPNOTSUPP);
-               return 0;
-       }
-
        /*
         * what we "blindly" assume:
         */