]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
drbd: silence some log messages on bitmap IO
authorLars Ellenberg <lars.ellenberg@linbit.com>
Mon, 21 Feb 2011 14:10:23 +0000 (15:10 +0100)
committerPhilipp Reisner <philipp.reisner@linbit.com>
Fri, 14 Oct 2011 14:47:47 +0000 (16:47 +0200)
Summary log messages meant for global bitmap IO
should not be printed for bitmap IO caused by
activity log transactions.

Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
drivers/block/drbd/drbd_bitmap.c

index bc89c4a30cbc111bbb8b0be96211287a71d913a6..3791082979e10fd49ce8a80c581b911683a1e364 100644 (file)
@@ -1096,9 +1096,12 @@ static int bm_rw(struct drbd_conf *mdev, int rw, unsigned flags, unsigned lazy_w
         */
        if (!atomic_dec_and_test(&ctx.in_flight))
                wait_for_completion(&ctx.done);
-       dev_info(DEV, "bitmap %s of %u pages took %lu jiffies\n",
-                       rw == WRITE ? "WRITE" : "READ",
-                       count, jiffies - now);
+
+       /* summary for global bitmap IO */
+       if (flags == 0)
+               dev_info(DEV, "bitmap %s of %u pages took %lu jiffies\n",
+                               rw == WRITE ? "WRITE" : "READ",
+                               count, jiffies - now);
 
        if (ctx.error) {
                dev_alert(DEV, "we had at least one MD IO ERROR during bitmap IO\n");
@@ -1116,8 +1119,9 @@ static int bm_rw(struct drbd_conf *mdev, int rw, unsigned flags, unsigned lazy_w
        }
        now = b->bm_set;
 
-       dev_info(DEV, "%s (%lu bits) marked out-of-sync by on disk bit-map.\n",
-            ppsize(ppb, now << (BM_BLOCK_SHIFT-10)), now);
+       if (flags == 0)
+               dev_info(DEV, "%s (%lu bits) marked out-of-sync by on disk bit-map.\n",
+                    ppsize(ppb, now << (BM_BLOCK_SHIFT-10)), now);
 
        return err;
 }