From patchwork Wed Jun 21 17:55:47 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: 9802435 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 880DA60234 for ; Wed, 21 Jun 2017 17:56:04 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 770CF28634 for ; Wed, 21 Jun 2017 17:56:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6BB032863A; Wed, 21 Jun 2017 17:56:04 +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 A2F8A28634 for ; Wed, 21 Jun 2017 17:56:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751148AbdFUR4D (ORCPT ); Wed, 21 Jun 2017 13:56:03 -0400 Received: from esa2.hgst.iphmx.com ([68.232.143.124]:54598 "EHLO esa2.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751152AbdFUR4A (ORCPT ); Wed, 21 Jun 2017 13:56:00 -0400 X-IronPort-AV: E=Sophos;i="5.39,369,1493654400"; d="scan'208";a="124564178" Received: from mail-dm3nam03lp0023.outbound.protection.outlook.com (HELO NAM03-DM3-obe.outbound.protection.outlook.com) ([207.46.163.23]) by ob1.hgst.iphmx.com with ESMTP; 22 Jun 2017 02:13:53 +0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sharedspace.onmicrosoft.com; s=selector1-wdc-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=35DOi1zMQNMGKziBF+/x7RPpD+mYgPmLdl4hQ0uXj7w=; b=eoYjSjrB77l5KjOq+A/8wGBb5eSG6kZuNmhQfdw5EozrruxZZlWhp3Q6cVX5ZoYwgcL7X2mklUpQDh/ULlXGpWSQKSfzh196Lhfz2/OUZuY8/GRhkvK5uiuAW1n0MDF4zLBhHlX1O0nHSG2oI/DREv1bwGwiQoticMoYpLqEa/U= Received: from BLUPR0401CA0023.namprd04.prod.outlook.com (2a01:111:e400:525a::33) by DM2PR04MB560.namprd04.prod.outlook.com (2a01:111:e400:2430::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1199.15; Wed, 21 Jun 2017 17:55:57 +0000 Received: from CO1NAM04FT058.eop-NAM04.prod.protection.outlook.com (2a01:111:f400:7e4d::204) by BLUPR0401CA0023.outlook.office365.com (2a01:111:e400:525a::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1199.15 via Frontend Transport; Wed, 21 Jun 2017 17:55:56 +0000 Authentication-Results: spf=fail (sender IP is 63.163.107.225) smtp.mailfrom=wdc.com; lst.de; dkim=none (message not signed) header.d=none;lst.de; dmarc=none action=none header.from=wdc.com; Received-SPF: Fail (protection.outlook.com: domain of wdc.com does not designate 63.163.107.225 as permitted sender) receiver=protection.outlook.com; client-ip=63.163.107.225; helo=milsmgep14.sandisk.com; Received: from milsmgep14.sandisk.com (63.163.107.225) by CO1NAM04FT058.mail.protection.outlook.com (10.152.91.93) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.1178.14 via Frontend Transport; Wed, 21 Jun 2017 17:55:55 +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 2C.88.03809.A23BA495; Wed, 21 Jun 2017 10:55:54 -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; Wed, 21 Jun 2017 10:55:06 -0700 X-AuditID: 0ac94371-10e5898000000ee1-d9-594ab32aaa29 Received: from exp-402881.sandisk.com.com ( [10.177.8.100]) by (Symantec Messaging Gateway) with SMTP id 33.4A.18148.623BA495; Wed, 21 Jun 2017 10:55:50 -0700 (PDT) From: Bart Van Assche To: Jens Axboe CC: , Christoph Hellwig , "Bart Van Assche" , Ming Lei , "Hannes Reinecke" , "Martin K . Petersen" Subject: [PATCH 3/3] blk-mq: Make it safe to quiesce and unquiesce from an interrupt handler Date: Wed, 21 Jun 2017 10:55:47 -0700 Message-ID: <20170621175547.21692-4-bart.vanassche@wdc.com> X-Mailer: git-send-email 2.13.1 In-Reply-To: <20170621175547.21692-1-bart.vanassche@wdc.com> References: <20170621175547.21692-1-bart.vanassche@wdc.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrBLMWRmVeSWpSXmKPExsXCddJ5ka7WZq9Ig60TLS1W3+1ns1jwZi+b xcrVR5ks9t7Stlh+/B+TxaHJzUwObB6Xz5Z67L7ZwObx8ektFo/3+66yeazfcpXF4/MmuQC2 KC6blNSczLLUIn27BK6MV8fWMRccFKmYv/QwSwPjQcEuRk4OCQETic0n17N0MXJxCAksZZJY 2nObEcLZwSgxdcsqJpiqi1tXMEMkVjJK/Fu/kRUkwSagJ3Fq3j6wIhEBBYme3yvZQGxmgReM En+/JoHYwgIxEg2rJ4HVsAioSizpmsoMYvMKWEu0XTnCCrFAXmLau14wm1PARuLU6aMsILYQ UM2hL/cZIWoWsUpcmakG0SsocXLmExaIXRISB1+8YIaoV5Y4v/YJ2wRGoVlIymYhKVvAyLSK USw3M6c4Nz21wNBErzgxLyWzOFsvOT93EyMk/At3ML6+7X2IUYCDUYmH16LOK1KINbGsuDL3 EKMEB7OSCG/rJqAQb0piZVVqUX58UWlOavEhRmkOFiVx3izZqRFCAumJJanZqakFqUUwWSYO TqkGxiXa+l8Xflr8RqJQZMX8NxrXljhHqvxhrF8+x6tiVXftFa/62MtyBj+kxDceaOQz7zjF 6ODQcupyaPm5ignMM5tPLX8vqS2x9kR6o1L57sh/F2Mda1T2rLjhsE94vzZ/5ieJlMRnj3at d50dYpHmuIZ12j5zg/1r3iit2KerID/FOHSKUdi590osxRmJhlrMRcWJAEH4bvt7AgAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrBJMWRmVeSWpSXmKPExsXCtZEjRVdts1ekwYajuhar7/azWVz684XR YsGbvWwWK1cfZbLYe0vbYvnxf0wWhyY3Mzmwe1w+W+qx+2YDm8fHp7dYPN7vu8rmsX7LVRaP z5vkPNoPdDMFsEdx2aSk5mSWpRbp2yVwZbw6to654KBIxfylh1kaGA8KdjFyckgImEhc3LqC GcQWEljOKHHpfCaIzSagJ3Fq3j4mEFtEQEGi5/dKti5GLg5mgReMErMW9LCDJIQFYiQaVk8C K2IRUJVY0jUVbBCvgLXEx9/3mSAWyEtMe9fLCmJzCthInDp9lAVimbXEoS/3GScwci9gZFjF KJabmVOcm55ZYGikV5yYl5JZnK2XnJ+7iREcNpxROxivTzQ/xMjEwSnVwLg9+2qC0u3f1udc ju24vmH5hR2T1tn/DljYUvl1/TXm0Jdtzzjnzpr9OjMkgltUIkfZcROL+CSnG5v+OnRPnt94 d+5BrsAva5b3HU3qX7k472/xS4fjz+edd1q776A/j8z2lgfKa871/xG89V7RNyw1qj35QoXR HIPrF1XZwibzBSw/p3dm9+39SizFGYmGWsxFxYkAUCZqzssBAAA= MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:63.163.107.225; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(39400400002)(39410400002)(39860400002)(39450400003)(39850400002)(39840400002)(2980300002)(1109001)(1110001)(339900001)(189002)(199003)(9170700003)(305945005)(72206003)(478600001)(2906002)(36756003)(189998001)(77096006)(86362001)(47776003)(575784001)(85426001)(5660300001)(356003)(33646002)(8676002)(5003940100001)(50986999)(76176999)(38730400002)(1076002)(110136004)(6666003)(53936002)(4326008)(2950100002)(81166006)(6916009)(106466001)(50466002)(50226002)(54906002)(8936002); DIR:OUT; SFP:1102; SCL:1; SRVR:DM2PR04MB560; H:milsmgep14.sandisk.com; FPR:; SPF:Fail; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; CO1NAM04FT058; 1:yqY77G8sKeN7kmXzB7YBdHWEDe6P8jm6HV46kAGG3K18UDZaDyc+5MvVaotX+sDt/pM9h/8winF2aFhc7HfpnnjZ7TGJxYFCp6+FhBIaVFuDxPBBylaIiH+v3zMu0oNrm8OQpIzkpmxxldhQuwP9qwNRaDyVfgptuMaYOsK5VC/9yhMkdcrW03aV4BZBQna/Ggzu2kZ2KjTgcTkfQft/h1lITmDw1kmQsEapxjAQYLKqFPYgRnFFNKbzf0ALhkPc4XWkFOutNN5AnXTkr5FyM6R3erYp7jo2Qq21VbiUCbckibx7ixFXv5slmvMx2FSQ0Fh36rdUT4zU9FAu0ZwSXeL0pw5Lr/oeXKIWQrrrdq9crdhQFsGW/FMQV8Vip/I//ilxREc/ozx9AjUZjD6sNjL7YojGjN/ClCaYJrp+s4GLxcQdLNFUjkgzt8B17vQAICu0B3skllZkokEH059DBerHF31gAMc8V0xIxA8zMER88OEDhrH9kN/RZRgPkG7f7FK+4qPj6ziScdFNUj8rNPNEj8Je0XI4fmCFxHr/DGqPdks2z2rSBLhnpcUw/3r9tukoJi05vQkDK2puLpXL7xI6BHkXN8uw1TU9Lt8kpHCfxeCOFFzgf0VqQLZjp1SOQHw0Yx4ZUe/6yIEtVf30F430uS0B6zlipX5uCo///NqQA03/BENDDo5AdPzQ4lFoyJSZPYK17V+ch71XgRCdP2BuaOtyKzCDlwJXEbf56gfwYpbBjjgJal5ZLILjQ7FU X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: cc16e899-af89-415b-93a1-08d4b8cec432 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254075)(201703131423075)(201703031133081)(201702281549075); SRVR:DM2PR04MB560; X-Microsoft-Exchange-Diagnostics: 1; DM2PR04MB560; 3:nrSgvo9tGPKJjooVCHIJe2RCFJ6K8DzBHPoks0lL0VLv3KogW1IBf5oIhcRp2I47mBF0lq6n/YKKXHyAmPtCID+37aa6tKqq1Ox+i3Pa/bkZaevZTYbSkMCj3ZFaYUyCYWaGkR6M2v3V0pNI2vOTYHqgBMgrhkzVPpCnsWtxSIY0ABJOcv7wyg518ZUcj18vNGzxe0I8l+xvSM6gyfn/6LLFlSYf3MUnSbJ7Btc/lsv0DUIFh2Ywes5Ml0SKYcdhce/NFrP1OJ99NLQML2o8jaidQLP1qeGY/EGiI5J87P6X5ofCn/77iymZsOK1ybjWxx/2DgORwTQl3S0zZo/nVq9MDNtPA1hNcGKQQ6JD2CcU5nLfYBFvxJINMV1+zZgahloyvWznY3lRqvKOm6P/Rm8zWx+3wFSYgyvEmnHDQnr1drdVpmbB24YpP26VHsfYxqovnS7kjLlPGFPrg/B4BeTQT+qI009v5Qlqqc4eks3fUfeQTtpFyifSzDjPGIwQ X-MS-TrafficTypeDiagnostic: DM2PR04MB560: X-Microsoft-Exchange-Diagnostics: 1; DM2PR04MB560; 25:rOpjs2AqHpYpmYWAKIRoL8O7mow1+cbJsoz4ZhuLhC5+Fip+N0oXKHASHuq2zJtFEo7YcSvjOQVEQRDmtCa+HHuFP5S6x7POMj+IShsA3AejStVGiqJuTp3sH5fwEu3+0uMl5ogRPPGtINZPqY2Sfyw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q8d/iTYCfua7aoeWG45osH4xMcm927qVh3IGlPg00RXrBBLbyYrfKJFtUW/FKYv8XEXIzwvlGIvfH7OM1389JVNva1e08G3DvPbIqB4tJlNaNAM46wIZnRVqwMkai X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(788757137089)(146099531331640); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(13018025)(8121501046)(5005006)(13016025)(93006095)(93003095)(3002001)(100000703101)(100105400095)(10201501046)(6055026)(6041248)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(20161123558100)(20161123564025)(20161123555025)(20161123562025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DM2PR04MB560; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DM2PR04MB560; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM2PR04MB560; 4:5nfPTt/48NRbw54qp64OI5BFzVcq/oOw6WrgXrV5sIG?= =?us-ascii?Q?Dp1k7VuUqWJrXOTzfLGq1oBSg/o7sYfieowTRVd+/L8L6VdTfPQEEEcIgjHY?= =?us-ascii?Q?jLk3xJKihvgTrlt3yJPVrY0L4aXh3qBTaUP53YNOLs6/ne7nZhQoZgYdYyY7?= =?us-ascii?Q?lZFCnyi7rMg7aestGutPPhYntK1HcdaanHgkCEfhd7sotJ8rjSs4UvCRSGb8?= =?us-ascii?Q?aOnGpjny3dtE2N6yMaawuU8+0MLPfpYEOE7AEtzh9fKMnZxB7mL0mkfYtcGt?= =?us-ascii?Q?EMTblioxbtmUgA//u/Ed8DAkYbiP7ANdl3k1P1EQan0GCvHrOQUW6UobXGDw?= =?us-ascii?Q?BPWhvZ8jRbiPVESn9GBd9QDnl0TODM4RkY8TliRy4eUMV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GOeHujMz6kuk99zmQqF1RH?= X-Forefront-PRVS: 0345CFD558 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM2PR04MB560; 23:TtNafbvRhR9GHKPqkAF/XidOFsVPFj9rVPZl83OqDu?= =?us-ascii?Q?MwhNuA6jdPJ0iJ1Q2N/E22xh6MiEgwNzViMgz9zt8ncO8eL6mptd1BpzR7F6?= =?us-ascii?Q?RqZ6MhALDtmvt5QmUPgnxeHbhsmeNHkwzZWTIU8yliBeAFmiHpNDq+GfAXwi?= =?us-ascii?Q?jozXMprXYtUU+0N/RVOws8s0LibWh+HpABxp8JUerr8D7Mvvi3oyZNK05H4Z?= =?us-ascii?Q?jLFkZsaJqGdlrGLXStSOTFzByokwGliH8Sno6aYU0S0MWJgvRGYqQwIOynYN?= =?us-ascii?Q?YteeOB49Roh5LEYrDPzmen+NSv5x+JOQpI/k6l68ocgKGpOeeYusM76tcFnQ?= =?us-ascii?Q?dGJd/kgEsKki582Mj/wqapjs3AgqLZAk+8pf+vues2dDMSlSL48C5Jf1xgzJ?= =?us-ascii?Q?LtesFmwfJdMXw1eC8caXBnEdo1Nu8QtSfrxo+RcBDG7xgtc6JLxvLyK143dk?= =?us-ascii?Q?bMT3f41Cjc8joDV/hezC71YIrAiSTfvXn3xZc6DhFJdmZMapJITiFOZbcLbH?= =?us-ascii?Q?iyQzRIIdf9B1O34ZGsMJF6cU5oiZqmTrcEgRgDIcnP0P8jYLeo0hDWWaHIoX?= =?us-ascii?Q?tt9b8+hEq4UlMPm7WN8bzup5vqJuASUWF/rWEI+dud0nPrzDfvNbxZWljQwm?= =?us-ascii?Q?qCR3E/S1TDfCdYH6UefG/o6K8Nsf8vKt2l+TuXaDEFHOhrww1f7v304afLFe?= =?us-ascii?Q?Igrgdd2HItvc/ily18YCtPDuMfilaxJANXU30609cxDsHVb5kQ3htJ7kTmI5?= =?us-ascii?Q?paK3JFDxK1LhrA9mXz/QUlY5LyRm9GQ4Bz87vkxP8Y/9wEN4N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tLiLQgY5swr4UzXHVvg4iVTf18Zj0wBHB3duvjRLkDMeSM5hp4ehcWWxfycsf9Y5/NEiO4lhJFIITIby+vu7aHUYNlvJuiTIqFS0= X-Microsoft-Exchange-Diagnostics: 1; DM2PR04MB560; 20:FeblsDiemX1BPEtNoUQ04lbLmk+E+qzFgd4xfx3DnoVSy94d6/ohLLRvdWuhc/plnbHS6j8AtZKq+LczYGAme/T7LmmTo1hzG0RnPYDIHnlKt7c3S4zLj5pg7h8uM5/OCys/e+qnoXK4O+m0M8tlSFG0+aRzTN2Ds3Zm35MmKbc= X-OriginatorOrg: wdc.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jun 2017 17:55:55.6755 (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.225]; Helo=[milsmgep14.sandisk.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM2PR04MB560 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 Since blk_mq_quiesce_queue_nowait() can be called from interrupt context, make this safe. Since this function is not in the hot path, uninline it. Fixes: commit f4560ffe8cec ("blk-mq: use QUEUE_FLAG_QUIESCED to quiesce queue") Signed-off-by: Bart Van Assche Cc: Ming Lei Cc: Hannes Reinecke Cc: Martin K. Petersen Reviewed-by: Ming Lei --- block/blk-mq.c | 20 ++++++++++++++++++-- include/linux/blk-mq.h | 10 +--------- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/block/blk-mq.c b/block/blk-mq.c index 1c4f1f4978c6..2caac30e128a 100644 --- a/block/blk-mq.c +++ b/block/blk-mq.c @@ -153,6 +153,20 @@ void blk_mq_unfreeze_queue(struct request_queue *q) } EXPORT_SYMBOL_GPL(blk_mq_unfreeze_queue); +/* + * FIXME: replace the scsi_internal_device_*block_nowait() calls in the + * mpt3sas driver such that this function can be removed. + */ +void blk_mq_quiesce_queue_nowait(struct request_queue *q) +{ + unsigned long flags; + + spin_lock_irqsave(q->queue_lock, flags); + queue_flag_set(QUEUE_FLAG_QUIESCED, q); + spin_unlock_irqrestore(q->queue_lock, flags); +} +EXPORT_SYMBOL_GPL(blk_mq_quiesce_queue_nowait); + /** * blk_mq_quiesce_queue() - wait until all ongoing dispatches have finished * @q: request queue. @@ -190,9 +204,11 @@ EXPORT_SYMBOL_GPL(blk_mq_quiesce_queue); */ void blk_mq_unquiesce_queue(struct request_queue *q) { - spin_lock_irq(q->queue_lock); + unsigned long flags; + + spin_lock_irqsave(q->queue_lock, flags); queue_flag_clear(QUEUE_FLAG_QUIESCED, q); - spin_unlock_irq(q->queue_lock); + spin_unlock_irqrestore(q->queue_lock, flags); /* dispatch requests which are inserted during quiescing */ blk_mq_run_hw_queues(q, true); diff --git a/include/linux/blk-mq.h b/include/linux/blk-mq.h index 366b83cee955..23d32ff0b462 100644 --- a/include/linux/blk-mq.h +++ b/include/linux/blk-mq.h @@ -266,15 +266,7 @@ int blk_mq_reinit_tagset(struct blk_mq_tag_set *set); int blk_mq_map_queues(struct blk_mq_tag_set *set); void blk_mq_update_nr_hw_queues(struct blk_mq_tag_set *set, int nr_hw_queues); -/* - * FIXME: this helper is just for working around mpt3sas. - */ -static inline void blk_mq_quiesce_queue_nowait(struct request_queue *q) -{ - spin_lock_irq(q->queue_lock); - queue_flag_set(QUEUE_FLAG_QUIESCED, q); - spin_unlock_irq(q->queue_lock); -} +void blk_mq_quiesce_queue_nowait(struct request_queue *q); /* * Driver command data is immediately after the request. So subtract request