]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - block/blk-mq-tag.c
Merge branch 'akpm-current/current'
[karo-tx-linux.git] / block / blk-mq-tag.c
index ec2d11915142a8f9b7a49e839e41a2f54a55aa09..a07ca3488d96fb7a96159fbe48c0c9e5e95391ec 100644 (file)
@@ -75,6 +75,10 @@ void blk_mq_tag_wakeup_all(struct blk_mq_tags *tags, bool include_reserve)
        struct blk_mq_bitmap_tags *bt;
        int i, wake_index;
 
+       /*
+        * Make sure all changes prior to this are visible from other CPUs.
+        */
+       smp_mb();
        bt = &tags->bitmap_tags;
        wake_index = atomic_read(&bt->wake_index);
        for (i = 0; i < BT_WAIT_QUEUES; i++) {
@@ -264,7 +268,7 @@ static int bt_get(struct blk_mq_alloc_data *data,
        if (tag != -1)
                return tag;
 
-       if (!(data->gfp & __GFP_WAIT))
+       if (!gfpflags_allow_blocking(data->gfp))
                return -1;
 
        bs = bt_wait_ptr(bt, hctx);