From patchwork Tue Oct 18 21:51:02 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bart Van Assche X-Patchwork-Id: 9383121 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 23915600CA for ; Tue, 18 Oct 2016 21:51:11 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 14A6B2878F for ; Tue, 18 Oct 2016 21:51:11 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0589029773; Tue, 18 Oct 2016 21:51:11 +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.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID 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 2F28B2878F for ; Tue, 18 Oct 2016 21:51:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755008AbcJRVvI (ORCPT ); Tue, 18 Oct 2016 17:51:08 -0400 Received: from mail-co1nam03on0085.outbound.protection.outlook.com ([104.47.40.85]:5618 "EHLO NAM03-CO1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754138AbcJRVvF (ORCPT ); Tue, 18 Oct 2016 17:51:05 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sandiskcorp.onmicrosoft.com; s=selector1-sandisk-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=TFC2kZfDBbMCUYX3h5AtrIiVNbEJWDDXpO6QkaMgWmc=; b=X0kIvkjwlsJAuLI2vYVS7EuDU4yTwiO0ggr6xUV5MHlexWKvla67k+i5QE68mmAS9Jwdm7+C09ih3LuxzijW3QAceWnViw4fVDPdv5eekqkCG95suLEZ74s9k8kWnRYAiZWj0SesQhKuj7FlJT4xqxseqy6jH2PsaBZgWo7zEVE= Received: from MWHPR02CA0011.namprd02.prod.outlook.com (10.168.209.149) by CY1PR0201MB1916.namprd02.prod.outlook.com (10.163.56.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.669.12; Tue, 18 Oct 2016 21:51:03 +0000 Received: from BY2FFO11FD052.protection.gbl (2a01:111:f400:7c0c::151) by MWHPR02CA0011.outlook.office365.com (2603:10b6:300:4b::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.659.11 via Frontend Transport; Tue, 18 Oct 2016 21:51:03 +0000 Authentication-Results: spf=pass (sender IP is 63.163.107.21) smtp.mailfrom=sandisk.com; vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; 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 BY2FFO11FD052.mail.protection.outlook.com (10.1.15.189) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.669.7 via Frontend Transport; Tue, 18 Oct 2016 21:51:03 +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 7F.CD.26959.6C696085; Tue, 18 Oct 2016 14:40:22 -0700 (PDT) Received: from milsmgip12.sandisk.com (10.177.9.6) by MILHUBIP04.sdcorp.global.sandisk.com (10.177.9.97) with Microsoft SMTP Server id 14.3.319.2; Tue, 18 Oct 2016 14:51:02 -0700 X-AuditID: 0ac94369-babff7000001694f-4f-580696c67251 Received: from exp-402881.sandisk.com ( [10.177.8.100]) by (Symantec Messaging Gateway) with SMTP id 00.B3.03615.64996085; Tue, 18 Oct 2016 14:51:02 -0700 (PDT) Subject: [PATCH v3 05/11] blk-mq: Add a kick_requeue_list argument to blk_mq_requeue_request() To: Jens Axboe References: CC: Christoph Hellwig , James Bottomley , "Martin K. Petersen" , Mike Snitzer , Doug Ledford , Keith Busch , Ming Lin , Laurence Oberman , "linux-block@vger.kernel.org" , "linux-scsi@vger.kernel.org" , "linux-rdma@vger.kernel.org" , "linux-nvme@lists.infradead.org" From: Bart Van Assche Message-ID: <7b52319b-03f7-e432-909a-2f46232770c6@sandisk.com> Date: Tue, 18 Oct 2016 14:51:02 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrPIsWRmVeSWpSXmKPExsXCddJ5ke6xaWwRBg/myVj833OMzeLl+Q+s FitXH2WyWDUxz+Le0S9MFntvaVvMX/aU3eLZoV4Wi+7rO9gszn94xWSx/Pg/Jov23g5mi7aN XxkdeD0mNr9j91i85yWTx4NDm1k8Ni+p99h9s4HN4+PTWywe7/ddZfN4+3Inq8fnTXIBnFFc NimpOZllqUX6dglcGRNOb2Qv2K9ZsepWL1sD4xzlLkZODgkBE4mTn06zdTFycQgJLGWSWLDs OSOEs41R4tmsfWwwVQfnNDBDVTFKTLw9ix0kISyQILFu40pmEFtEQFbi++7XYA1CAnYSb9fv ZAFpYBbYyyLx8PItVpAEm4CRxLf3M4ESHBy8QEULVrmDhFkEVCVO3ZnNCGKLCkRIbPo6hwXE 5hUQlDg58wlYOaeA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pr9PrK3aPz/d6e8vDZWnk4Wm JShMD+7njarek3ppd/wl63nzj0r7TVrh98Vf0DnSZF+EZmWEwvRbNjsnVCmxFGckGmoxFxUn AgAp7DSJOQIAAA== 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:(10009020)(6009001)(7916002)(2980300002)(438002)(189002)(199003)(69596002)(65806001)(229853001)(97736004)(81166006)(50466002)(8676002)(54356999)(65956001)(36756003)(76176999)(110136003)(65826007)(5660300001)(86362001)(81156014)(31686004)(7846002)(626004)(305945005)(19580395003)(64126003)(19580405001)(356003)(106466001)(47776003)(53416004)(4326007)(7416002)(2906002)(4001350100001)(586003)(2950100002)(8936002)(230700001)(92566002)(11100500001)(50986999)(2270400002)(77096005)(33646002)(68736007)(83506001)(23676002)(575784001)(31696002)(87936001)(6916009)(189998001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY1PR0201MB1916; H:milsmgep15.sandisk.com; FPR:; SPF:Pass; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BY2FFO11FD052; 1:9xuxUFu9xfP9GT+Xkce82G4NmnmPUC9hX2sMAHIYTBqttbYHAgQuyGX9gRvGRTzD1wci01Amyje72GKCz8bzTf1+JGnr8joDmvRFcYvfsvXUfa85wUZ1RXMltACUBk8iNxKIw5Uf/4B24SPiqLkw6DoFXisxEqUzWkz5R0fXVSlYY/d959l4b3ZB2GgTk1cFxDmYuT8KcJ+OE9VhpmpgAE8lcVsXAsNr637I8pXfj/tF5DmIJIGL8ZcNRcJfz2tVPcnsXw3tlZ/xnnGsASZ8tM5uAEZxrTXGTcaW/09wOEb/piyNDaONHJn4BbQGnSQ8rHJ3dMtdWuoNYSwPxGPNu4E1fspjE4Tc0G1KNTW9HdbcGCGV5WxUHtN9uSm7XZf2SgpTRsv16pVh3d4MeI4/FE4YEqxu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Gi9nHslKmwAncTA8AXosDOAgR1ZWgr3fVjmlokoxlET4l4RWxfzaoSMAFV6aPu2WWhqSB5/KZ3rZBoosGpMBFRjJk2Nhy+z4CGOMCfv8xPJl/Mcc xZbsa6fcNYu5taJGMRMMaFEddIKowM8/lQa X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(8251501002); SRVR:CY1PR0201MB1916; X-Microsoft-Exchange-Diagnostics: 1; CY1PR0201MB1916; 31:YLYt2DDJCIFQm+muh7arWH//Ofu208KN6p2TkdRoIeGvSiBVUojjcToNOD8OsgUra8kvFX7OJKPJWn41fX1Ws8BFunfBf5RF/jZM0B0wxdPsUhQzWDwnX8cCGAYfLUj01qSO98cn+5lEu7yBRyzX4/qWIOf75gsS+Wp/sdaJx0YslXc17OeT8pIrztYkk3NeVjxURtJukl1dRgBbHmTSLgAn1oRlUH1mcCHnJoLoJeeZP9pju3PWo3NUGj6NYnFB; 20:1JkM7kxr9H13HbDOab+5gR8wI7L/fMSMv/PyOUqa4p9NVukZNSuDMpI9BcqDFUszNF6JfyMCaXGZkChQg3EmpXCfYHK+/txxJG086CBCkjcikwrS9BLlpPutCi8rDDO/WCJeMXr9opnbk6S2bcnGC/b1n+mPiZx14cr5maRX1xydhdXcXE+WEQAQFGQu8PndQaL2hiHXg7vIPJ1oEjD3h/5IrElcGaFhBxcpczQaBpz6tWm76u9S0yvZDpD5UlEyvLwfDxzU+MYAe85BBloHO3uM6/cl0xGnzuY92ij0Yy3LRm3k8pUBrVuQxDxU7CxqSHopiXXohD2BLEHAupFW3JYsFMTjz/Flt0S3qGA+Id1UAVP8WbSjKrzRDWly8O9dQbzTvD/eMw21SEY++T9Wj4hmXleV1B1x1NiRB6Ki5J96WvNSjv3DoHq6arHCldSwzj0vs11GGAxUlVsXjBGO7C0Dn8CgqqDbtlT8zrOvdG9FmwXxEU4FNpMDTKTn2EQF X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(13016025)(13018025)(3002001)(10201501046)(6055026); SRVR:CY1PR0201MB1916; BCL:0; PCL:0; RULEID:; SRVR:CY1PR0201MB1916; X-Microsoft-Exchange-Diagnostics: 1; CY1PR0201MB1916; 4:Muh/pYCCCjO/5vnUYp2+eYAJwLapvoHk2bXvB+9V6GjtTCrBT2+KYSLVk3sPSXyuIolnxaIyqwr0dF7/iwQSaOzKEsr0zhGwJ0wnqwgxHnAu54Dgh6tgEyKRBeyVCy+WpUTGClTr2bN7/EnrQu8qboTMa68tVtXGesqkUmelX25wkQoPeeisejn1N/1kzbCgiK1pavP6VMZuPlYkxirMmgx+qlVd4UCybfpJdAybIxBgWo3kV+s9rfvkgvnO7qDD2E411wW7smysn0ck8Dt1L3blVEdcUmLERroliurA1KQ8Gdmn2zXAuOZ4ZazUo1dMsYCSm3pci7Nnc7hZoaKM+10Wk1DPgnURsngHzlxtUp3NAiHYjKMAe9W/5dHNpJLh7H0FKGUiNelZDcXBFBiTxznNVEDAqcRi0qsgp1s6MjvlNGmk4HDd7CwnPEoOW5sOzt+NVyfmGnK95RjpZBp/PZ6R0HbnzlA2KjRmyx/tmS781OoREfnWOdugMpsrWbb9 X-Forefront-PRVS: 00997889E7 X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtDWTFQUjAyMDFNQjE5MTY7MjM6OWVDNVRaZTJhOGRYdDIwUFFRT0pwbnZp?= =?utf-8?B?ZW02N3hhb2EwdWNVWHNRaDJ4ZUlEa3RZQ1I5T0RqbnVzRWkwMmVOTXo0Z2FO?= =?utf-8?B?OWM2WXY0cnVmUm4yQStBQVlwdFhwUmpZemxEYUdFZTFYL3M1S1RKVmNTcDFl?= =?utf-8?B?RUtwaTVsRFY4dWVhWkJqd2prMFlOS1FlY3dmY0VoOHJBTzA2Ukt3dnR6WGRN?= =?utf-8?B?a0JRUDRHcDRyTnVSc0JrUEJyYUJ6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dWiVmH1CilurGL0+DSB38zT3B9lyx7DIVIyCQeteIrm5ORCezTOXNTAsBW1+sP9p/GMmA7BoaUy8Dan7g=; 5:W4W541BJxvzaZVVTcuEkurlAxEFSYtTPe62kpGHCMIP3EBERrGBT0m82MHO5HzBX/PqQTgOvid+dIq5RB6fDvn4ukNDa+Kc6zziFVRR2rT8TOcUvUFoqzCZ59MYgTHF7fsGC5o0fTc6LR+UmaQ9Z/Q==; 24:8nJmT1bNXVojYiG3X7qSSzrJOtrPGHSlWa/zON4/PGRrbmsJ6d60qTp5hgbFKftpqh3ySPTMDvqF2aR7svAqKopahrm62MUBEpQUpsnvT+0= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY1PR0201MB1916; 7:Xq3Gsbgw4E1ZQPmBpIRlTyMo0PopPrkQBCfLbYEmDd39sb0UcaFaJsZq5gKSpcGtC9qSL/c3Bw67WhWye1urvYENyvJIL0HcoWjgyXEhwE6uumkSumexLIbZaHslKaqY9RarrpF6cwW2Sgow11ArW5Y8aWcgpyFn7AeIiUo9qId0u1MrR28CetaDC8v+152lOX3KVxqz/XNG05FCTeYDZjli8g4uZaqa4RYCVvaslcZNxjFen5eBzeoy4u1H78YQwPOjXhXVv2VeHBi4ECSLs4V2bMI/0YYJ6MbDldcVsbzxjkmDhl42iEvfCMdL9pjtNRWkcjow8zh802YnYubJRhTkIwVxjnB8lNfCTwg2r0c=; 20:rZ38Y9zWmExQ5QKKT9dU4WaERnMAlJQitJcAXygJCNUeVAGpdvjy1dqzpe4VT6CRCWGEgThyVW3rQvQxRGW2IrdGLToQcwikR3cjGw/3+RnBHS9OtJiDo7HXQVnCL/xsRW6GrfenhmaK7zS8ElRtHhMrYJYVearJyDfE1cOAQGNK454eGMuUwNOusFdmOtzBwrwEWDBAUyHn5LXwnpkkuDpUwi/gkNci5FpQe1deQ1f8s8OBHAPwlTW0Fy6dxbTC X-OriginatorOrg: sandisk.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Oct 2016 21:51:03.3592 (UTC) X-MS-Exchange-CrossTenant-Id: fcd9ea9c-ae8c-460c-ab3c-3db42d7ac64d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=fcd9ea9c-ae8c-460c-ab3c-3db42d7ac64d; Ip=[63.163.107.21]; Helo=[milsmgep15.sandisk.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY1PR0201MB1916 Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Most blk_mq_requeue_request() and blk_mq_add_to_requeue_list() calls are followed by kicking the requeue list. Hence add an argument to these two functions that allows to kick the requeue list. This was proposed by Christoph Hellwig. Signed-off-by: Bart Van Assche Cc: Christoph Hellwig Cc: Hannes Reinecke Cc: Sagi Grimberg Cc: Johannes Thumshirn Reviewed-by: Christoph Hellwig --- block/blk-flush.c | 5 +---- block/blk-mq.c | 10 +++++++--- drivers/block/xen-blkfront.c | 2 +- drivers/md/dm-rq.c | 2 +- drivers/nvme/host/core.c | 2 +- drivers/scsi/scsi_lib.c | 4 +--- include/linux/blk-mq.h | 5 +++-- 7 files changed, 15 insertions(+), 15 deletions(-) diff --git a/block/blk-flush.c b/block/blk-flush.c index 6a14b68..a834aed 100644 --- a/block/blk-flush.c +++ b/block/blk-flush.c @@ -134,10 +134,7 @@ static void blk_flush_restore_request(struct request *rq) static bool blk_flush_queue_rq(struct request *rq, bool add_front) { if (rq->q->mq_ops) { - struct request_queue *q = rq->q; - - blk_mq_add_to_requeue_list(rq, add_front); - blk_mq_kick_requeue_list(q); + blk_mq_add_to_requeue_list(rq, add_front, true); return false; } else { if (add_front) diff --git a/block/blk-mq.c b/block/blk-mq.c index d41ed92..b0c8b44 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -491,12 +491,12 @@ static void __blk_mq_requeue_request(struct request *rq) } } -void blk_mq_requeue_request(struct request *rq) +void blk_mq_requeue_request(struct request *rq, bool kick_requeue_list) { __blk_mq_requeue_request(rq); BUG_ON(blk_queued_rq(rq)); - blk_mq_add_to_requeue_list(rq, true); + blk_mq_add_to_requeue_list(rq, true, kick_requeue_list); } EXPORT_SYMBOL(blk_mq_requeue_request); @@ -534,7 +534,8 @@ static void blk_mq_requeue_work(struct work_struct *work) blk_mq_start_hw_queues(q); } -void blk_mq_add_to_requeue_list(struct request *rq, bool at_head) +void blk_mq_add_to_requeue_list(struct request *rq, bool at_head, + bool kick_requeue_list) { struct request_queue *q = rq->q; unsigned long flags; @@ -553,6 +554,9 @@ void blk_mq_add_to_requeue_list(struct request *rq, bool at_head) list_add_tail(&rq->queuelist, &q->requeue_list); } spin_unlock_irqrestore(&q->requeue_lock, flags); + + if (kick_requeue_list) + blk_mq_kick_requeue_list(q); } EXPORT_SYMBOL(blk_mq_add_to_requeue_list); diff --git a/drivers/block/xen-blkfront.c b/drivers/block/xen-blkfront.c index 9908597..1ca702d 100644 --- a/drivers/block/xen-blkfront.c +++ b/drivers/block/xen-blkfront.c @@ -2043,7 +2043,7 @@ static int blkif_recover(struct blkfront_info *info) /* Requeue pending requests (flush or discard) */ list_del_init(&req->queuelist); BUG_ON(req->nr_phys_segments > segs); - blk_mq_requeue_request(req); + blk_mq_requeue_request(req, false); } blk_mq_kick_requeue_list(info->rq); diff --git a/drivers/md/dm-rq.c b/drivers/md/dm-rq.c index 76d1666..d5cec26 100644 --- a/drivers/md/dm-rq.c +++ b/drivers/md/dm-rq.c @@ -354,7 +354,7 @@ EXPORT_SYMBOL(dm_mq_kick_requeue_list); static void dm_mq_delay_requeue_request(struct request *rq, unsigned long msecs) { - blk_mq_requeue_request(rq); + blk_mq_requeue_request(rq, false); __dm_mq_kick_requeue_list(rq->q, msecs); } diff --git a/drivers/nvme/host/core.c b/drivers/nvme/host/core.c index 329381a..e4a6f2d 100644 --- a/drivers/nvme/host/core.c +++ b/drivers/nvme/host/core.c @@ -203,7 +203,7 @@ void nvme_requeue_req(struct request *req) { unsigned long flags; - blk_mq_requeue_request(req); + blk_mq_requeue_request(req, false); spin_lock_irqsave(req->q->queue_lock, flags); if (!blk_queue_stopped(req->q)) blk_mq_kick_requeue_list(req->q); diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index 2cca9cf..ab5b06f 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c @@ -86,10 +86,8 @@ scsi_set_blocked(struct scsi_cmnd *cmd, int reason) static void scsi_mq_requeue_cmd(struct scsi_cmnd *cmd) { struct scsi_device *sdev = cmd->device; - struct request_queue *q = cmd->request->q; - blk_mq_requeue_request(cmd->request); - blk_mq_kick_requeue_list(q); + blk_mq_requeue_request(cmd->request, true); put_device(&sdev->sdev_gendev); } diff --git a/include/linux/blk-mq.h b/include/linux/blk-mq.h index 02c3918..1fcdc04 100644 --- a/include/linux/blk-mq.h +++ b/include/linux/blk-mq.h @@ -218,8 +218,9 @@ void blk_mq_start_request(struct request *rq); void blk_mq_end_request(struct request *rq, int error); void __blk_mq_end_request(struct request *rq, int error); -void blk_mq_requeue_request(struct request *rq); -void blk_mq_add_to_requeue_list(struct request *rq, bool at_head); +void blk_mq_requeue_request(struct request *rq, bool kick_requeue_list); +void blk_mq_add_to_requeue_list(struct request *rq, bool at_head, + bool kick_requeue_list); void blk_mq_cancel_requeue_work(struct request_queue *q); void blk_mq_kick_requeue_list(struct request_queue *q); void blk_mq_delay_kick_requeue_list(struct request_queue *q, unsigned long msecs);