[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150709213405.GB18734@mtj.duckdns.org>
Date: Thu, 9 Jul 2015 17:34:05 -0400
From: Tejun Heo <tj@...nel.org>
To: Akinobu Mita <akinobu.mita@...il.com>
Cc: linux-kernel@...r.kernel.org, Jens Axboe <axboe@...nel.dk>,
Ming Lei <tom.leiming@...il.com>
Subject: Re: [PATCH v2 5/6] blk-mq: fix freeze queue race
On Thu, Jul 02, 2015 at 11:29:56PM +0900, Akinobu Mita wrote:
> There are several race conditions while freezing queue.
...
> Also, percpu_ref_reinit() and percpu_ref_kill() must not be executed
> at the same time. Because both functions could call
> __percpu_ref_switch_to_percpu() which adds the bias value and
> initialize percpu counter.
>
> Fix those races by serializing with per-queue mutex.
>
> Signed-off-by: Akinobu Mita <akinobu.mita@...il.com>
> Cc: Jens Axboe <axboe@...nel.dk>
> Cc: Ming Lei <tom.leiming@...il.com>
Yeap, all of the kill/reinit/switch mode functions assume caller side
synchronization.
Acked-by: Tejun Heo <tj@...nel.org>
Thanks.
--
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists