From patchwork Thu Apr 6 18:10:50 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bart Van Assche X-Patchwork-Id: 9668027 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E4621602B3 for ; Thu, 6 Apr 2017 18:11:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 13B60285B7 for ; Thu, 6 Apr 2017 18:11:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0866F285BC; Thu, 6 Apr 2017 18:11:16 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3FEA5285B7 for ; Thu, 6 Apr 2017 18:11:15 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932227AbdDFSLO (ORCPT ); Thu, 6 Apr 2017 14:11:14 -0400 Received: from esa4.hgst.iphmx.com ([216.71.154.42]:36047 "EHLO esa4.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752831AbdDFSLM (ORCPT ); Thu, 6 Apr 2017 14:11:12 -0400 X-IronPort-AV: E=Sophos;i="5.37,160,1488816000"; d="scan'208";a="9100685" Received: from mail-sn1nam02lp0023.outbound.protection.outlook.com (HELO NAM02-SN1-obe.outbound.protection.outlook.com) ([216.32.180.23]) by ob1.hgst.iphmx.com with ESMTP; 07 Apr 2017 02:11:03 +0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sharedspace.onmicrosoft.com; s=selector1-sharedspace-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=mSeLmicgR6A56aWJpU+QF/vAfrbWw3qB6szH+iR4uTo=; b=D0qA+BXSbj6fgsSSYr31KX7+hMPA6oaxv51wYAQjBjIgGutLh4Ttu7HFX1GcxKcNZsUsGXbk2y4odrnuFw4L/91+6MCscYaP4Y7KwbinWTWFun0DoORoWpij42ND8iYSLrUEQcmlH5ftM3w3bDf8gY969TaBF7MWJza0liedCR0= Received: from BN6PR04CA0005.namprd04.prod.outlook.com (10.172.194.15) by BLUPR04MB102.namprd04.prod.outlook.com (10.255.213.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1005.10; Thu, 6 Apr 2017 18:10:59 +0000 Received: from BN3NAM04FT056.eop-NAM04.prod.protection.outlook.com (2a01:111:f400:7e4e::204) by BN6PR04CA0005.outlook.office365.com (2603:10b6:404:cb::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1019.17 via Frontend Transport; Thu, 6 Apr 2017 18:10:59 +0000 Authentication-Results: spf=pass (sender IP is 63.163.107.21) smtp.mailfrom=sandisk.com; microsoft.com; dkim=none (message not signed) header.d=none;microsoft.com; dmarc=bestguesspass action=none header.from=sandisk.com; Received-SPF: Pass (protection.outlook.com: domain of sandisk.com designates 63.163.107.21 as permitted sender) receiver=protection.outlook.com; client-ip=63.163.107.21; helo=milsmgep15.sandisk.com; Received: from milsmgep15.sandisk.com (63.163.107.21) by BN3NAM04FT056.mail.protection.outlook.com (10.152.93.63) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.1019.14 via Frontend Transport; Thu, 6 Apr 2017 18:10:58 +0000 Received: from MILHUBIP04.sdcorp.global.sandisk.com (Unknown_Domain [10.201.67.162]) (using TLS with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by (Symantec Messaging Gateway) with SMTP id EB.A6.29323.1B486E85; Thu, 6 Apr 2017 11:10:58 -0700 (PDT) Received: from milsmgip12.sandisk.com (10.177.8.100) by MILHUBIP04.sdcorp.global.sandisk.com (10.177.9.97) with Microsoft SMTP Server id 14.3.319.2; Thu, 6 Apr 2017 11:10:54 -0700 X-AuditID: 0ac94369-548749800000728b-ed-58e684b18fb6 Received: from exp-402881.sdcorp.global.sandisk.com ( [10.177.9.6]) by (Symantec Messaging Gateway) with SMTP id A8.8A.18148.EA486E85; Thu, 6 Apr 2017 11:10:54 -0700 (PDT) From: Bart Van Assche To: Jens Axboe CC: , Bart Van Assche , "Martin K . Petersen" , James Bottomley , Christoph Hellwig , Hannes Reinecke , Sagi Grimberg , Long Li , "K . Y . Srinivasan" Subject: [PATCH v3 5/5] scsi: Avoid that SCSI queues get stuck Date: Thu, 6 Apr 2017 11:10:50 -0700 Message-ID: <20170406181050.12137-6-bart.vanassche@sandisk.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170406181050.12137-1-bart.vanassche@sandisk.com> References: <20170406181050.12137-1-bart.vanassche@sandisk.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrPLMWRmVeSWpSXmKPExsXCddJ5ke6mlmcRBn87GS1W3+1ns9izaBKT xcrVR5ksNvZzWDxZvZXdYu8tbYvj1w4yWyw//o/JYt3r9ywOnB7n721k8Zg26RSbx+WzpR67 bzawebTu+Mvu8fHpLRaPzaerPT5vkgvgiOKySUnNySxLLdK3S+DK+L9xNVPBVcGKU9t6mBoY v/J1MXJySAiYSEw784q1i5GLQ0hgKZPE4rerGUESQgLbGSVuvBKBKfrf+pYFomgjo8SDa23s IAk2ASOJb+9nsoDYIgIKEj2/V7KBFDELfGKS2PhgC1iRsICdxJTHi9lAbBYBFYmTS7uYQWxe AXu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Yd72M6l2dZfCPmf8WVQWG8lm8HL/4olbzJPXTcw/L/6nVYmlOCPRUIu5qDgRAGXW UlDgAQAA MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:63.163.107.21; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(39400400002)(39410400002)(39450400003)(39860400002)(39840400002)(39850400002)(2980300002)(438002)(189002)(199003)(9170700003)(356003)(4326008)(305945005)(36756003)(48376002)(50466002)(2906002)(50986999)(8666007)(5003940100001)(189998001)(76176999)(6916009)(77096006)(54906002)(2950100002)(5660300001)(53936002)(8676002)(110136004)(6666003)(38730400002)(86362001)(81166006)(33646002)(106466001)(1076002)(50226002)(8936002)(47776003); DIR:OUT; SFP:1102; SCL:1; SRVR:BLUPR04MB102; H:milsmgep15.sandisk.com; FPR:; SPF:Pass; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BN3NAM04FT056; 1:8P6npvhp+WFqVi6xMagclAydVeSu70Y33aopjJAs7o3cousMVmUKg4tRv5GcOMM1KO24acSFdUd0wqTSGRqggTwM3YKrqYW5L05L66hxzVvBINKf6HptRXlrxDyzmTnwZomEjQV8u4A3bGzfNJQoOBkerEhFjRQJMHU/fZ8NuME1YcN6ZtN12pm2hLd8kyDLyHyuNcwChN1My7jA1X0GPaCvNTdzHWdqWEoZtIvP9vPbZUcK2/b6JfI/zB0Fjg5A20TkHcGgVRDFiH0a79woCq+oBXlc3Etuip6hmORZ0nwm4Sxcx/VELQ/A8XxGayy3Y5FzVTMVoNEq6USmEy0F9USe0FH3N0iwWuZmO5VOp9MJAPz6yo0P4pRl4azqNFNPdAHCdDEYu0xylKnttfeJh5jTdafqTpObJ11k2jzdO06j5WPxQdR1VTqslyulE4+RRMWamcEeEs9knYq/DOGA5UIs5OF1zjieyey33MeXBHAqO5m4MKWzGquC8wqY5B1NW6KA4J8dwwsNPhfS5aWrnkCKqaIq15TZK/2iyso24DI= X-MS-Office365-Filtering-Correlation-Id: f76b38af-809b-474b-c830-08d47d184754 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(8251501002)(2017030254075)(201703131423075)(201703031133081)(201702281549075); SRVR:BLUPR04MB102; X-Microsoft-Exchange-Diagnostics: 1; BLUPR04MB102; 3:VTUI8EwAiSJdT7iOS+uGsbqcZ1TvzggLxKIjpAJWcn6G0ZscR3O5HRi7iUqMG1Sjk6XoXiqAu3N3lhIwWCLcH6X0mXOcuJNY3NXzCs61MtDjNsioSNrDACVtfoFXmbNQlIpusjbW2fj/S3j29eLT99o6rNeathMATbFCrF+MsQpIR4plNNpVSPlE015f7KFastK6EQt1rm2UlpNAMpKrmPW/X536RQ1KR4bTl4JtTGePumu8wZZtNLRLpPPYSlwrqV9dKDfZEPKywo0E+980bQjIe8wpqEBTgv8zNCDHBnOsSFy0mLD2r2qzU5Yev5aAhzabasr17zNGnIKiBj3UFfkimmIsZQ/Yejzc5byUTmy6vjqF+tps6N9ZqXSmfx51wMTqzZ1YI99PAYoubpwER2mAn8+fINW5/UE+xY0qzn/Yfn5EGcugdVpYvh0bLvUiBiKT49VllbHIXL5/KJ++eXft8nVitm+KdZrUbuv/Exfv3LPH2tH07GRoh3S3zuyNKtW4Yb5L/BUT6OLGQcypFA== X-Microsoft-Exchange-Diagnostics: 1; BLUPR04MB102; 25:mgl5jGbB5chhEi7vX/n2R0sBKPbB6Y0LAWo0T6u06YmFDg8Bt25lvJFmzKwe09dbH8V4zRED+bSU1yLA8Zn/MRvhSseCWc5RFqtgeQapKk684D9nw1eeMQdbLK4SwltSa2iaJnLe6hQDbIWgRXbmt5UyLfryWkUxMDBWOrc2Cn/uqNUDxmeK9tPhTrYsZWO5na5I/4KlmHfjeyLMAMtLRpobKQirjLZt1A3+RpC+h2xNycV0UJGsKNW3RCqN7ao3g33kxXeHS/Oh172kLgt+i+Yiuhh7jpGYcPUlx7iDtWfcZHH1Y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ispam-Report-Test: UriScan:(146099531331640)(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(13018025)(8121501046)(5005006)(13016025)(10201501046)(93006095)(93004095)(3002001)(6055026)(6041248)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(20161123562025)(20161123560025)(20161123555025)(6072148); SRVR:BLUPR04MB102; BCL:0; PCL:0; RULEID:; SRVR:BLUPR04MB102; X-Microsoft-Exchange-Diagnostics: 1; BLUPR04MB102; 4:jrdKFzxs7zma/4BSRcXxzQ8Z2geapM2s46nNgqWj2KtLKEaasNLHbrFcX+5apsD55S+3ZQpWs33WZHA0vMD5De/FE+vtf99YDlrc0elAReahBBhhLS5yob88FjoAqZqSBxrWQFZ1MBKlJbfah6SjfVSKeCe76owuMNPI8lfC1lzwXTzJRbAtqQftbhsX1t6FMcDi/ra76HYuKokGAKtE6UnknYG9Apy2K/iIz6qNK8E4k4jcG/RUUZH+losaOOlsdThcp6/ae0Jyf0HkIRkOBFbrKIBl+oovVjETLKyfv1B0KMYQq+PbAAdeoqNR5/c4wo8nbllZmrgkgAXdrvP6xLLTqKcN2kNcQMPDSGKWjGS7f7/4HUk7tPcP0rtkbm6JFlRw1+rW4rQgWwriwIXZVBA+V8GAvuFr0YNWnERVlYZOctYiv84tgSyrhpIUZSxQ6qgomXeTQbbTHT4gvKG3hKjm7msiQFT8hI0swaoba7mSwJHI8nXUgze0gqi7P50Gey0SNPrUbEJEWPRYtPnb1NgwAOLtOvcbkm9UAxc1mkJMmfWMVCq+QTxQ+58wYpVg5DY1Hrjk1f78yITSlEP+Ty3il+nvNqZuGxGia0JvLMlv2QdJr6DgFIzJnq2IuKHU5ZckUENUXte74RYFTy/J0sGFS+2/fhK+jYdT+wV9FqgJPQSSV1Z2H3N0No8YS5LykMRizAldgXeCL6IpZU0QR+FUPnzE2m6GWW1triqytzrq41KVHu8gQRIC+MoeNT6KGDWLh45dXuDv5KkoQG+t+62XPIsD4H+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HwLEV3NUFwPLdIONnB9Z9UJb6Hr0rbPvQbOE1bnMaQaOZAEg66fVRF5D2cM= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BLUPR04MB102; 7:NlmnYSQAh1gia91p4gjcLyB4PdloGZfTp15SlKlyK2D26GeSk0AVZ8tHlQmiPaKghU/1ha2lkwLPg5cwkTO9U2SkSjeSsg7rokZIXj4ccSOfAhWnGAw4y2gTH2kDB1JEQUGUZr0VFACGttnbZhvV0oaCY/S1Pe2X30C2Nb6klU1GgZ19/DL3NzgnbkKYqgyxzBSGMhb82i986576vq//O/c/u6RLme7BDwwSqrrfPa2GUE/42SW3nUgPlQt+DvE44tqMj8n+DsZyAzcwkaw8SwRFmUdZ4kuBKgTG4Zjo4ZvI2Yh9rTGQ/igUhRHwdR1MNhCFnaK1gG8yEZZA6ntwiw==; 20:xoQiOOoy2rkwGnRaergi77eNPVGnAZIDR3hBjCyeVoyrrIUlpLQq1/WtKQg5kH0MQh1p6/k4eNA8vBwGvg3fRpEs24qmy7ZNfQHC1gbJ11dSL3fizSVs5m/es+MJ3Y6ABaZyoN1r2GzjbalN8eQgNzrgAgckyLfheVRPOKKHyL4= X-OriginatorOrg: sandisk.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Apr 2017 18:10:58.7695 (UTC) X-MS-Exchange-CrossTenant-Id: b61c8803-16f3-4c35-9b17-6f65f441df86 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=b61c8803-16f3-4c35-9b17-6f65f441df86; Ip=[63.163.107.21]; Helo=[milsmgep15.sandisk.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR04MB102 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP commit 52d7f1b5c2f3 ("blk-mq: Avoid that requeueing starts stopped queues") removed the blk_mq_stop_hw_queue() call from scsi_queue_rq() for the BLK_MQ_RQ_QUEUE_BUSY case. Hence change all calls to functions that are intended to rerun a busy queue such that these examine all hardware queues instead of only stopped queues. Since no other functions than scsi_internal_device_block() and scsi_internal_device_unblock() should ever stop or restart a SCSI queue, change the blk_mq_delay_queue() call into a blk_mq_delay_run_hw_queue() call. Fixes: commit 52d7f1b5c2f3 ("blk-mq: Avoid that requeueing starts stopped queues") Fixes: commit 7e79dadce222 ("blk-mq: stop hardware queue in blk_mq_delay_queue()") Signed-off-by: Bart Van Assche Cc: Martin K. Petersen Cc: James Bottomley Cc: Christoph Hellwig Cc: Hannes Reinecke Cc: Sagi Grimberg Cc: Long Li Cc: K. Y. Srinivasan --- drivers/scsi/scsi_lib.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index 11972d1075f1..7bc4513bf4e4 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c @@ -496,7 +496,7 @@ static void scsi_run_queue(struct request_queue *q) scsi_starved_list_run(sdev->host); if (q->mq_ops) - blk_mq_start_stopped_hw_queues(q, false); + blk_mq_run_hw_queues(q, false); else blk_run_queue(q); } @@ -667,7 +667,7 @@ static bool scsi_end_request(struct request *req, int error, !list_empty(&sdev->host->starved_list)) kblockd_schedule_work(&sdev->requeue_work); else - blk_mq_start_stopped_hw_queues(q, true); + blk_mq_run_hw_queues(q, true); } else { unsigned long flags; @@ -1974,7 +1974,7 @@ static int scsi_queue_rq(struct blk_mq_hw_ctx *hctx, case BLK_MQ_RQ_QUEUE_BUSY: if (atomic_read(&sdev->device_busy) == 0 && !scsi_device_blocked(sdev)) - blk_mq_delay_queue(hctx, SCSI_QUEUE_DELAY); + blk_mq_delay_run_hw_queue(hctx, SCSI_QUEUE_DELAY); break; case BLK_MQ_RQ_QUEUE_ERROR: /*