Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2412923imm; Thu, 2 Aug 2018 11:07:47 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfV7l1eUh0Ie/dpQvEhdtbMkaprL8l9NKtZkZlrej/5ZAgtFlsfLrrHYmz8zZznHVLZG8vh X-Received: by 2002:a62:4c0f:: with SMTP id z15-v6mr590015pfa.110.1533233267303; Thu, 02 Aug 2018 11:07:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533233267; cv=none; d=google.com; s=arc-20160816; b=dJsy0fT/KESTsXFu4cyfRyrwvZayxVHT8f29QujZXmEXN4M+izs2eyF45UcvDB8eoy L2oCyJmInS+vzax0EszFo1ckRIIM8uIJ5FxFBK+Ox+q8N1aQY9KYz7heBoZoh/czFfoC 7W92kEVUsbOvFMHPFA+PVq/QbWZtDlE0JgMd39m0X4lNmOeOXHTuH6N1RROvxfNGFQgm 9m8wMFUN1Hlm5Y4hRHd1Se5Wqt9LaiJ53TEbgEqdWGL1mY8cvwqyJg8IxtXgfrQFtjf2 TZs0j43Pd1AdbHDD1DFhik63cbW1UELXF/aBnH1ePoj7JZgfn2bNcJZqs9xjGOGBYnuV yfPg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature :arc-authentication-results; bh=9t/K0/W7nVK+HXimozMBZb3agmVO7lUKTOd8PoKBYZw=; b=adRyjD4ntKinLLaZBV48B1OTzO+9IoksyY8MP46SOwGQ1S3SE6YLQZmInV+CKCSUD5 v30BSztrpgih82NA+HHx/q/rcJ8OzqBuqEcardcKPZrQo5VmurZtm/n3idXa099eY/gE wGW9mxDhMAZCL408jZWxoTc0vq39LGqpdMk/fmNfshkhXQmVJuuI2a9SVJXG3O2LVIKk CIsCM8yEYSBTthE7f6bKz7sJfvY0RS9lyro+QP63VgqaDg4ws4YLG33kLHkY7V7jOLZA t6VBS/3qX0356ET7dtUWJ39nJNO8F03oeLrR+Ei1Et+Uf/e3dbB16o7TmOn7GMrRxzHn U+wQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=srJS9Ujw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b129-v6si2477927pfa.12.2018.08.02.11.07.32; Thu, 02 Aug 2018 11:07:47 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=srJS9Ujw; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731812AbeHBSmw (ORCPT + 99 others); Thu, 2 Aug 2018 14:42:52 -0400 Received: from mail-wr1-f67.google.com ([209.85.221.67]:35461 "EHLO mail-wr1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726938AbeHBSmw (ORCPT ); Thu, 2 Aug 2018 14:42:52 -0400 Received: by mail-wr1-f67.google.com with SMTP id a3-v6so2828033wrt.2; Thu, 02 Aug 2018 09:50:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=9t/K0/W7nVK+HXimozMBZb3agmVO7lUKTOd8PoKBYZw=; b=srJS9Ujw1raIBbpzLxb6XTFOnEvWyjY7B5bXFw3bN62p5z87mr1xZDvzJd269COT6+ rDHvmtdJjmcRJxD3/oaxE86XFhCkEJ7a6Y1qJPh7YEO1VNcSlUzXV9sKf8LdQ2QLnGS3 2OUz4tr4Lvrmv/PEyk5NBIp3E18Wvy7lJqYa7BBhaP2s7nFK5fC0hr1ft1Tsku0y8XK/ qFLrNLZn7OWUXQn+lDd3+zWTxN9r4IYYf1kpXZehJYarF2KzhVfpkbDPlHq1sKaRPN/+ kpUz8xq+g/6hp/G9DaapZ8YV/HC/ka91y86oL/0lNy2UWwz7+02qn/Xx5US6G5hfCv8H Z6Pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=9t/K0/W7nVK+HXimozMBZb3agmVO7lUKTOd8PoKBYZw=; b=JJcT7kNuUKgZIKL7YbYIMHblRqFfQQIpO/tBL4B5t+LSpqazP1+bWYrWXLbWhUIzfx eDGqK7IOjAQyH+3zsqZbQO7+N2Rql6GngHDUohjG3eBuU4OTlGDdW90+NQHG6Khq3+RI 3AnWl1K8C/46XisYCZq02kAy9MDTLZutEAdOBIKqetWcldWhDWZfmt3Eqd6Rxt6mNCGi odFXK0MzlvWT0WEQPkcTgB4wACEdpguV5XKLsLmjUjRhP6MoUZ7y7ve10szlOJfwZ+NE 9os+wVMJJY2O8njxlOa3H4CTkNg9141UXGTKymvJLX1lkgnbMLJVmgEffeqtspkPQz5J iYHA== X-Gm-Message-State: AOUpUlFdBheI8LEp+7Ge/Zv0g2M4SfjUCF/LSOGFRFxzZm9grh5bZQK/ k/Tx4onfHWv9A2M72DVoQawqqH4f0KlAxzkMGgUj7wM1 X-Received: by 2002:a5d:5201:: with SMTP id j1-v6mr178996wrv.198.1533228654239; Thu, 02 Aug 2018 09:50:54 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a1c:9c8:0:0:0:0:0 with HTTP; Thu, 2 Aug 2018 09:50:53 -0700 (PDT) In-Reply-To: <9329f50c734eec5fa994ea652890f017a88625c2.camel@wdc.com> References: <20180801175852.36549130@canb.auug.org.au> <20180801224813.GA13074@roeck-us.net> <1533163965.3158.1.camel@HansenPartnership.com> <20180801234727.GA3762@roeck-us.net> <1533168205.3158.12.camel@HansenPartnership.com> <171b2cdc-2e74-2b3c-e5f5-c656a196601a@roeck-us.net> <20180802162654.GA8928@ming.t460p> <9329f50c734eec5fa994ea652890f017a88625c2.camel@wdc.com> From: Ming Lei Date: Fri, 3 Aug 2018 00:50:53 +0800 Message-ID: Subject: Re: linux-next: Tree for Aug 1 To: Bart Van Assche Cc: "linux@roeck-us.net" , "ming.lei@redhat.com" , "linux-ide@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "hch@lst.de" , "axboe@kernel.dk" , "linux-scsi@vger.kernel.org" , "sfr@canb.auug.org.au" , "linux-next@vger.kernel.org" , "James.Bottomley@hansenpartnership.com" , "josef@toxicpanda.com" , "tj@kernel.org" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Aug 3, 2018 at 12:40 AM, Bart Van Assche wrote: > On Fri, 2018-08-03 at 00:27 +0800, Ming Lei wrote: >> This issue can be fixed by reverting d250bf4e776ff09d5 ("blk-mq: only iterate over >> inflight requests in blk_mq_tagset_busy_iter"). >> >> This patch looks wrong, because 'blk_mq_rq_state(rq) == MQ_RQ_IN_FLIGHT' >> isn't completely same with 'blk_mq_request_started(req)'. > > Please test the following change instead of reverting the commit mentioned > above: > > diff --git a/block/blk-mq-tag.c b/block/blk-mq-tag.c > index 09b2ee6694fb..25a0583d8b4c 100644 > --- a/block/blk-mq-tag.c > +++ b/block/blk-mq-tag.c > @@ -271,7 +271,7 @@ static bool bt_tags_iter(struct sbitmap *bitmap, unsigned int bitnr, void *data) > * test and set the bit before assining ->rqs[]. > */ > rq = tags->rqs[bitnr]; > - if (rq && blk_mq_rq_state(rq) == MQ_RQ_IN_FLIGHT) > + if (rq && blk_mq_rq_state(rq) != MQ_RQ_IDLE) > iter_data->fn(rq, iter_data->data, reserved); > > return true; > I just sent out a similar patch on list, but use blk_mq_request_started() instead. https://marc.info/?l=linux-scsi&m=153322823307754&w=2 Thanks, Ming Lei