From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Sun, 28 May 2017 10:42:08 +0200 From: Christoph Hellwig To: Bart Van Assche Cc: Jens Axboe , linux-block@vger.kernel.org, Christoph Hellwig , Hannes Reinecke , Omar Sandoval , Ming Lei Subject: Re: [PATCH 12/19] blk-mq: Initialize a request before assigning a tag Message-ID: <20170528084208.GG13083@lst.de> References: <20170525184327.23570-1-bart.vanassche@sandisk.com> <20170525184327.23570-13-bart.vanassche@sandisk.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: <20170525184327.23570-13-bart.vanassche@sandisk.com> List-ID: On Thu, May 25, 2017 at 11:43:20AM -0700, Bart Van Assche wrote: > Initialization of blk-mq requests is a bit weird: blk_mq_rq_ctx_init() > is called after a tag has been assigned and .rq_flags is initialized > in __blk_mq_finish_request(). > > Call blk_mq_rq_ctx_init() before > modifying any struct request members. Initialize .rq_flags in > blk_mq_rq_ctx_init() instead of in __blk_mq_finish_request(). This > patch does not change the behavior of the block layer. One things this patch does is to initialize the tag value actually set twice. In general this looks ok, but I can't really see the real value. So a very reluctant: Reviewed-by: Christoph Hellwig