]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - block/blk-timeout.c
blk-mq: attempt to fix atomic flag memory ordering
[mirror_ubuntu-bionic-kernel.git] / block / blk-timeout.c
index 17ec83bb09002ccfeead4b49692d52b3bc41caa5..e3e9c9771d36106d08bb959258f05236dfacf159 100644 (file)
@@ -211,7 +211,7 @@ void blk_add_timer(struct request *req)
        if (!req->timeout)
                req->timeout = q->rq_timeout;
 
-       req->deadline = jiffies + req->timeout;
+       WRITE_ONCE(req->deadline, jiffies + req->timeout);
 
        /*
         * Only the non-mq case needs to add the request to a protected list.