From patchwork Mon Apr 3 23:22:25 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: 9660699 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 4EB4D6032D for ; Mon, 3 Apr 2017 23:22:43 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3F2E828469 for ; Mon, 3 Apr 2017 23:22:43 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 341BA2849D; Mon, 3 Apr 2017 23:22:43 +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 C110D28469 for ; Mon, 3 Apr 2017 23:22:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751732AbdDCXWm (ORCPT ); Mon, 3 Apr 2017 19:22:42 -0400 Received: from esa3.hgst.iphmx.com ([216.71.153.141]:61477 "EHLO esa3.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751756AbdDCXWj (ORCPT ); Mon, 3 Apr 2017 19:22:39 -0400 X-IronPort-AV: E=Sophos;i="5.36,272,1486396800"; d="scan'208";a="7968475" Received: from mail-co1nam03lp0016.outbound.protection.outlook.com (HELO NAM03-CO1-obe.outbound.protection.outlook.com) ([216.32.181.16]) by ob1.hgst.iphmx.com with ESMTP; 04 Apr 2017 07:22:37 +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=dHUHA2XNC0z6jo8vewRP2HW443FZm/ObpPr5SxLK4/M=; b=i/kiE4bY7jirrkEl+KiSxfFJA2B6dyCmpQGtib8B9HOQbv7zIyeGMimyJC5fOEdmdQAJQUJzUMpzV7fMgTDQe06xEmLRNvP68zd7ps0uJMVgWeH66+p1zA81j5GIFnbTftYfiNcqxlSGivFBanAXUTAhCt7CfS4+QhsUP1soAxU= Received: from MWHPR04CA0041.namprd04.prod.outlook.com (10.172.163.27) by BN1PR04MB108.namprd04.prod.outlook.com (10.255.199.146) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.991.14; Mon, 3 Apr 2017 23:22:36 +0000 Received: from SN1NAM04FT044.eop-NAM04.prod.protection.outlook.com (2a01:111:f400:7e4c::204) by MWHPR04CA0041.outlook.office365.com (2603:10b6:300:ee::27) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1005.10 via Frontend Transport; Mon, 3 Apr 2017 23:22:35 +0000 Authentication-Results: spf=pass (sender IP is 63.163.107.21) smtp.mailfrom=sandisk.com; lst.de; dkim=none (message not signed) header.d=none;lst.de; 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 SN1NAM04FT044.mail.protection.outlook.com (10.152.89.63) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.1005.5 via Frontend Transport; Mon, 3 Apr 2017 23:22:34 +0000 Received: from MILHUBIP03.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 5C.D0.29323.839D2E85; Mon, 3 Apr 2017 16:22:32 -0700 (PDT) Received: from milsmgip11.sandisk.com (10.177.8.100) by MILHUBIP03.sdcorp.global.sandisk.com (10.177.9.96) with Microsoft SMTP Server id 14.3.319.2; Mon, 3 Apr 2017 16:22:30 -0700 X-AuditID: 0ac94369-548749800000728b-2b-58e2d93824d3 Received: from exp-402881.sdcorp.global.sandisk.com ( [10.177.9.6]) by (Symantec Messaging Gateway) with SMTP id 7A.C4.11415.639D2E85; Mon, 3 Apr 2017 16:22:30 -0700 (PDT) From: Bart Van Assche To: Jens Axboe CC: , "Martin K . Petersen" , James Bottomley , Bart Van Assche , Christoph Hellwig , Hannes Reinecke Subject: [PATCH v2 2/5] blk-mq: Make it safe to use RCU to iterate over blk_mq_tag_set.tag_list Date: Mon, 3 Apr 2017 16:22:25 -0700 Message-ID: <20170403232228.11208-3-bart.vanassche@sandisk.com> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170403232228.11208-1-bart.vanassche@sandisk.com> References: <20170403232228.11208-1-bart.vanassche@sandisk.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrOLMWRmVeSWpSXmKPExsXCddJ5ka7FzUcRBut2yFmsvtvPZrHgzV42 i5WrjzJZbOznsNh7S9ti+fF/TA5sHtMmnWLzuHy21GP3zQY2j49Pb7F4rN9ylcXj8ya5ALYo LpuU1JzMstQifbsEroyHy7YwFczlrriy6SpLA+Muzi5GTg4JAROJ83tmsHUxcnEICSxlktiw uh/K2c4ose3rRFaYqp7Xn5ghEhsZJY5cbWACSbAJGEl8ez+TBcQWEVCQ6Pm9EqybWaCVSWL1 xFb2LkYODmGBeIlbG01BalgEVCTaV3Wxg9i8AvYSvUufM0IskJdYtGkGC0g5p4CDxJ1dGSBh IaCS/X27wPZKCC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edMessage: 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)(39410400002)(39850400002)(39840400002)(39860400002)(39450400003)(39400400002)(2980300002)(438002)(199003)(189002)(9170700003)(77096006)(6666003)(4326008)(81166006)(5660300001)(8676002)(50226002)(38730400002)(110136004)(6916009)(8936002)(2950100002)(54906002)(305945005)(36756003)(50466002)(2906002)(5003940100001)(106466001)(86362001)(48376002)(356003)(189998001)(50986999)(76176999)(33646002)(53936002)(1076002); DIR:OUT; SFP:1102; SCL:1; SRVR:BN1PR04MB108; H:milsmgep15.sandisk.com; FPR:; SPF:Pass; MLV:sfv; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; SN1NAM04FT044; 1:FjEZj91ppIF0IbT5670iSvdVKduXhk1LIr4dtgGbLfwQqqj8idErZoCU+YzxPrzxE5gLltHMI9+0N7p2WGpc+2sKfo7YrBRmpPtzI/oWXPo30UBEsOI+jRR/zZ/Y3+J2+ITpUlPkp1TnRKuGHfUUn9DkuH0cnBqOgBsvnlBDqyazg0zPzf/bbaATgAEv+ol6QE+QVmrfn4PUZXqLw5BauVNQQlZ6tz1XyebZ0V9cPg6hUgtaxi+FzeD+XbTey+Y1QL433LdKBaf/K7908xVMAnTQrf66p/ThMgMH7ClzCdiIOEKWErOli7c/jMnytZd8+AoxOqmjl8Hj9k8anktkDqz8sBeomnWzf4IKe14CECWq+stcmGFmc1ThiSAecDH/+2bx1gsib78we6ZEeVtmw8ZTcuV/xcIBW82EsJ9O6X/DbVHbY7LTOeNIlmDTY2iZ6L/AXTDwRjf1U6XwGjqRcb/9yZcfFahH5+JAkrpd09DeDVk2DhMyCAmMxHxdkWj9fFkauQcU2K6kGwlP2woN+5Fi2DZBSq9UYc4uwYpwx5I= X-MS-Office365-Filtering-Correlation-Id: 529472cc-4ce6-47a3-fc9a-08d47ae84f55 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(8251501002)(2017030254075)(201703131423075)(201703031133081)(201702281549075); SRVR:BN1PR04MB108; X-Microsoft-Exchange-Diagnostics: 1; BN1PR04MB108; 3:gNlGu/GLJZ2zF2Ndhh98lVHR31ndKicqTh03gnOmV0pPRApVaI1c1pqXli0w4kNcVfFCQ4/ropJCf51ferhGAe0fMs2zVI+5mPukycULkS/T/STkNMHn46C4708DC18heIauBsf4bxS+b4zH8X0NIfMI+SqFzdtgDXq1LFiIXcZHKu/SJMIT1z8D/5MKhuYh1UEJYSju5/EumyeLZJaBt1Ojma9vTl5AtJHVXkh+EuL7DHLByTSJKEM29Rx7ofY6njC/++S0Ag0WA+RlqVIvXSyIKCNJ+SI9GdEJRok9I4h7CcV7YKg6p0xxNEgjU8NvsTF4BA2Coat+BfPPXEaaHEdnYVP0oJSFHsJ9aTdoW5HpIl2IZ/P8+vDuEwVTXJS5k93mpE+JJtd+zU85DONqGhvKDmU1nzN7vXSXnRUqZf/a/V68y2AejSEH2Janq487hgjJN1UDhGYS9PS2Cld56OGQ7FuA8S5rrVrT19P2G4hzrYpllgZfC8PHElFDtAaUn2mag5YLm9K1XE9mchgbPQ== X-Microsoft-Exchange-Diagnostics: 1; BN1PR04MB108; 25:Rc3t7b1xQ9OLJUiyNNz5cUFljcRqZpfPEL5dZ8wcnsOnvpNB8jQZn0YO43I2HYRIhQalr7qMDwkuImG6d58tNHao+wVXPPvdoKYseNrC3LpH4anolIO5selEEL7XA6lkwLCRq6wo2eXDobxMfhwRD8yST8WICM8NsNWrNJIU6q7fDCn0jN8mU6J74Nhi3J4mnOva3J/DnFNICJCSuS+DxbRVWjHpGimveoPY6OVXvxmiG18vsyRY1MZmVoeVmQtD5MesoAKykXu959y/9m6uA8fbIFHWyTOj2mUpUHzV6qXaZzFvp8uAcNoaMUvfbT2d+mu+oHGKg0FWAzKVnQmHgm3RicKU21dIyPLredfaPM0KON5+JJMC2XUeqYCrm1fhJYIJEosEh7Zy6WEggqc0nqn/g1R/+lGT6vufoKBV6fs1QDGXEu1qQBjXc1JUq276tar9grfdcPo2xItwP8MwYA==; 31:002rz0I3cwwn+k7q4vh7+uuVy+qdFROwK1VJ2Zxlc+8iVQeAn/gfFHY58fJYrszytbWHu2gz3fgGlBmBJof6qtgVh7b+TlCOhv8esvdbL6tc8kUXMYItgcZiQ5dMVpzEVB3LtAGBUz5wETFUa+U0MMTgIV2bWdsPu0ICPAcSd52BeWjU6dVW6QNy6asvtIdQgCuRt6JWRhY5sQbYwoSuyfDLfYcCT8WeQFud2HxL2SwxmBLgpwHoASOGdYBOYM/x WDCIPOUTBOUND: EOP-TRUE X-Microsoft-Exchange-Diagnostics: 1; BN1PR04MB108; 20:OVCvFMOY8mbcAzRvssXr9SgqYxaIGLzF7z61rZfFMMYRiYQ9x7E8IEG/xNmC5wVHTP+zjrxvdI+U+STxJvO3obVpO4brFoCa68JUdfmVywnPo+SRuqvFFij9zPICSwVxRrrJH7PXxosITHGozcmC0M/abzZvn9/g94r0Li/fj2dvVhvLLCzhnsReZcvkXW88QqWXeDDKUE4pZfXZu2GDUn2JAtwuTpG8Nzip1Z5rrXVCQZSxYeRJGnlrfysV2lrMGdi0f0q4DSaI0Qn7R70aAn7DlPEfJpytifYmo3J5XYVBYSlOuheAtyUe9vdrBPVQE5GyEhT4ElDk+xL3WIdr0l4B442WkFfmeOGAhdKluWYD/n2yarl13r8QTGlj5YBrFX60iy86533iY+gG/pvoV3+aN4l05iKAVjNM/TqD6Ovsp6ENOlORSNcD0dWYoVDgXexq2Pc7rcGt40Q2ac0sC98tUMD3/1RvhYu0Sgijwfc8XVmi/4XKFldm9SNtGufQ X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(146099531331640)(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(13018025)(8121501046)(5005006)(13016025)(10201501046)(3002001)(93006095)(93004095)(6055026)(6041248)(201703131423075)(201702281528075)(201703061421075)(20161123560025)(20161123555025)(20161123562025)(20161123564025)(6072148); SRVR:BN1PR04MB108; BCL:0; PCL:0; RULEID:; SRVR:BN1PR04MB108; X-Microsoft-Exchange-Diagnostics: 1; BN1PR04MB108; 4:50G/8ju9bOIAnjrcahBzBEVNSt4eDijXmYCl0cQK6s65PN1kbO8cqPdv4oC7R/6q0Wz03CnEgd36A8HQ6TWKy3HjHLFHtbjC7a+urAOAoNpVIrTEXS0W1CRwLnbNYIIHvs46rRZYn80WKCuFB5QLh9M8DivRPckeZWjOmaJXxXWkWYi+AQ+2SkpZOydGZI/3yvXl21ah7LS29BgJolEpWApR0WcyKROCZ1bO2wuTdsM3V3gXAdsu0lByx15ZrlO5L+sVCu+P8UrhISpJrFNZdNrnK4fAFBL+E3lo8cd2qR2i1vdty8ZY5njXH97TIJ7Mnb7ThH9IvOp/xfcfGdMDvn3hHrKElUv5n5Buyyf091rK03gjobogTaKQRPlsqHSUyvQnXjqbPcm+LgF7uzKfWyrk79+etlztq8h/bIyxqhJVhjheqOF9w+InPyR3MmCGttgx/h+JeWhaWfKmbwnr9Hgze+LPgChMVhsC+rLoB6u93r3kG09z3dfdJ+YQW0KPEHdu+1fF6z9wEn0H6CapXvCRcpjjJavdqdU5GpJXWdEGiBhQQtdqwblOAKBQIcRKLHMU5FKrFpJVkuVo3ZP5beFVTi4he21ycDeAqyPuBxM0pYfkelm0o6axrJ2ifsTKXYBdrZ05qX6yvQOv27gvq/fSvv/m+vo1WZ72p1memvIFq6b3m3u7tJrE4MAiI4y3J0n9vJ66Fm6wHC6L76/PfVHdNsWE9ECZgFRW4F84Lj91hzodUP44H2X29yoAEZtd76miJ6MaFouqfeM2csqc99/JOUAodCi6ZXcsrGR98eEHxgdB9V9wDwPlhflcNT/6bNtsqp64nR0rboH+e7N4zfqQm07CZm7qwNwnBoHCEbA= X-Forefront-PRVS: 0266491E90 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN1PR04MB108; 23:RNQ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ii?Q?/a0OXzyiw36K3UIpepnV0C/HedAIKTbG8JjlsbQ30Gy38OIlmxU7AnmqrbRL?= =?us-ascii?Q?0JXy6vxBJkMWxycEFFFXp9EtzsiRWzINeKF4tZjw4tZpmQKxY5/gibe2pEyP?= =?us-ascii?Q?7j9k0RT9GvpprXGNa1323l?= X-Microsoft-Exchange-Diagnostics: 1; BN1PR04MB108; 6:UAsTMjFJo6YDtYPGjtWOMkfJ4oF+86oho0ZHQhDGxamGVrJalmRtvp/7Xo/+RnuGocovXznc5/GmqfWDoRhUHb4Ka+QjCkxBm5nqkBRUyK6Z7hOS6v4F8AN4I0bVgUtFyMfkkz/wi6+HKDEwUC1TegIQVCdY/918f2EiYS8rFBDzIwY+tWBpiCFrddfPZ+nidKRh8wvnxuE7SVXHhn2Iv/FHF2YauBu3KCh+NYOw0/jNm3EsP9514AKZSF2oS2xU15jqP5TKj9bSD3XQObS7dnMprqT6Z+eDNZj2J0EE47myWm0tzgbxdRjMvln+j3nz+ICrbDtDCiTLWUC+mCmb5X27cc+sCZ2l/OkRtgj7yBxCEhg+VFBKo9OgQ0c6b92HKpy4ugMRbm9C+ZrP8KwrTOEFW4JnMgXnF1enoMsgSW0=; 5:YTxbvb8oZC3UCtT2/PFEtP4MUCLnFci5JQ7jcdo5jU7G5hadUUKCFX8G5CCZN0Mxg1RHBqn0okjYIgHTGdzL0BxAorUb5HYmNyZRxo7PFZkXRxJ4QV+DxfOvf7jOAjQiw4x8PrWHksmh7UrbHimC4g==; 24:08ZvDi2WoEnnwtfQxFqdja4/7vZLfjEel829j6ZkmGpRGeCd1o5qIIX61bOdsXkwJmHMlhn5PKP28AXRieLO8SYt+/PII168aJuKEiJfdTE= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BN1PR04MB108; 7:biBWtZrySqK2uKCmNcZf+UbWBYhzs6ztVQBZ7TC2w6x2dYk3vBbhjHGCob/78+yQ62glxlZchiLCX+u/XT9QkGzv41hDwDNGbmtmxTQkk+1wkFFowgG+y3aSAzcKCUc+b+yzuEqE3MJ5qy1MCE/AFw2eHDe9zzBvXN2BDS+a2jBDeXuvjubduIqueFldMt12VKV/8+bLcYcXdFfxNKpxbzGfPC0R6GTASW4maNkeeRZbOP9fx1VhQvvUJ3amWA1ZkHyf8mRTrpjkGzAm2cTZUwjg86l9uezW34P0FtFTER1xc47qJ/7kmSRVXXXRR4XpsHqug3vkAPev5uu6hWnYVA==; 20:R/SdORt2QFiL1NU5vOxrq5PbuheMC/EQgMxuwyLoIP9gpgKsLitK/xHHdQgRgyHoetmpIN4S0AZJRuSnqyyBEH51wOMxg/oiefMJNCFeidM1ljew8q+sBgoV0HjSFgEinkeXFYk7uhbMgdnRAS0LgBAPJOF4lDJ4DXGu2yFLkq4= X-OriginatorOrg: sandisk.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Apr 2017 23:22:34.2337 (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: BN1PR04MB108 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 A later patch in this series will namely use RCU to iterate over this list. Signed-off-by: Bart Van Assche Cc: Christoph Hellwig Cc: Hannes Reinecke Cc: Martin K. Petersen Cc: James Bottomley Reviewed-by: Christoph Hellwig --- block/blk-mq.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/block/blk-mq.c b/block/blk-mq.c index 061fc2cc88d3..8fb983e6e2e4 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -2093,6 +2093,8 @@ static void blk_mq_update_tag_set_depth(struct blk_mq_tag_set *set, bool shared) { struct request_queue *q; + lockdep_assert_held(&set->tag_list_lock); + list_for_each_entry(q, &set->tag_list, tag_set_list) { blk_mq_freeze_queue(q); queue_set_hctx_shared(q, shared); @@ -2113,6 +2115,8 @@ static void blk_mq_del_queue_tag_set(struct request_queue *q) blk_mq_update_tag_set_depth(set, false); } mutex_unlock(&set->tag_list_lock); + + synchronize_rcu(); } static void blk_mq_add_queue_tag_set(struct blk_mq_tag_set *set, @@ -2618,6 +2622,8 @@ void blk_mq_update_nr_hw_queues(struct blk_mq_tag_set *set, int nr_hw_queues) { struct request_queue *q; + lockdep_assert_held(&set->tag_list_lock); + if (nr_hw_queues > nr_cpu_ids) nr_hw_queues = nr_cpu_ids; if (nr_hw_queues < 1 || nr_hw_queues == set->nr_hw_queues)