From patchwork Fri May 19 18:29:59 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: 9737933 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 9BD21601C2 for ; Fri, 19 May 2017 18:32:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 946BE2856F for ; Fri, 19 May 2017 18:32:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 894D528579; Fri, 19 May 2017 18:32:24 +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=unavailable 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 26B482856F for ; Fri, 19 May 2017 18:32:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756042AbdESScV (ORCPT ); Fri, 19 May 2017 14:32:21 -0400 Received: from esa1.hgst.iphmx.com ([68.232.141.245]:51075 "EHLO esa1.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755987AbdESSa1 (ORCPT ); Fri, 19 May 2017 14:30:27 -0400 X-IronPort-AV: E=Sophos;i="5.38,365,1491235200"; d="scan'208";a="121513945" Received: from mail-sn1nam02lp0015.outbound.protection.outlook.com (HELO NAM02-SN1-obe.outbound.protection.outlook.com) ([216.32.180.15]) by ob1.hgst.iphmx.com with ESMTP; 20 May 2017 02:30:26 +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=J+JvLftY6LtnTILEOmDx11V8p7/tUqoO/A+M1G6bKVY=; b=SxeyPsvIWddh/9fVY02retsTDogNDGEenjm+yf+NDelICU+/UpP4q1B0gyonlhcD/GSbbDr0nhCrTWVakOsXdO3uooIuZNk7cLudVT7N1ElimJ4IIqJXIsYvRHHVsKn4/HLiK+UtpmHwRVt9MSvJ+nBuBSoHnYg9kMdHz7wa9og= Received: from MWHPR04CA0047.namprd04.prod.outlook.com (10.172.163.33) by MWHPR04MB0511.namprd04.prod.outlook.com (10.173.49.12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1101.14; Fri, 19 May 2017 18:30:23 +0000 Received: from SN1NAM04FT040.eop-NAM04.prod.protection.outlook.com (2a01:111:f400:7e4c::208) by MWHPR04CA0047.outlook.office365.com (2603:10b6:300:ee::33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1101.14 via Frontend Transport; Fri, 19 May 2017 18:30:22 +0000 Authentication-Results: spf=pass (sender IP is 63.163.107.21) smtp.mailfrom=sandisk.com; fb.com; dkim=none (message not signed) header.d=none;fb.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 SN1NAM04FT040.mail.protection.outlook.com (10.152.89.1) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.1075.5 via Frontend Transport; Fri, 19 May 2017 18:30:21 +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 D3.5A.29323.CB93F195; Fri, 19 May 2017 11:30:20 -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; Fri, 19 May 2017 11:30:18 -0700 X-AuditID: 0ac94369-548749800000728b-96-591f39bc9774 Received: from exp-402881.sdcorp.global.sandisk.com ( [10.177.8.100]) by (Symantec Messaging Gateway) with SMTP id 98.37.18148.9B93F195; Fri, 19 May 2017 11:30:18 -0700 (PDT) From: Bart Van Assche To: "Martin K . Petersen" , James Bottomley CC: , Bart Van Assche , Jens Axboe , Christoph Hellwig , Omar Sandoval , Hannes Reinecke , Subject: [PATCH 01/18] block: Introduce blk_queue_cmd_size() Date: Fri, 19 May 2017 11:29:59 -0700 Message-ID: <20170519183016.12646-2-bart.vanassche@sandisk.com> X-Mailer: git-send-email 2.12.2 In-Reply-To: <20170519183016.12646-1-bart.vanassche@sandisk.com> References: <20170519183016.12646-1-bart.vanassche@sandisk.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrMLMWRmVeSWpSXmKPExsXCddJ5ke4eS/lIgytTVS3+7znGZrHgzV42 i5WrjzJZbOznsNh7S9ui+/oONovlx/8xWRy+d5XFgcNjYvM7do9pk06xeey+2cDm8fHpLRaP 9Vuusnh83iQXwBbFZZOSmpNZllqkb5fAldH6pJul4DdPxfeZh9gbGBu4uxg5OSQETCR+vN7E 1MXIxSEksJRJ4uCaqVDODkaJncfes8BULf5xGiqxmVHiZcNcRpAEm4CRxLf3M8GKRAQKJS5t 62AEKWIWeM8ocfnCIrAiYQEbic29r8GKWARUJR4+/sgMYvMK2EtMWbiTDWKDvMTZLTvB4pwC DhIvjy9k72LkANpmL3G/rx5kpoTAOlaJL0/fMEL0CkqcnPkEbCazgITEwRcvwHqFBNQl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ering-HT: Tenant X-Forefront-Antispam-Report: CIP:63.163.107.21; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(39840400002)(39410400002)(39850400002)(39450400003)(39400400002)(39860400002)(2980300002)(438002)(189002)(199003)(9170700003)(47776003)(54906002)(50226002)(48376002)(50466002)(81166006)(8936002)(8676002)(86362001)(38730400002)(53936002)(305945005)(2906002)(2950100002)(6666003)(5660300001)(5003940100001)(189998001)(72206003)(478600001)(50986999)(76176999)(77096006)(1076002)(36756003)(106466001)(33646002)(356003)(4326008); DIR:OUT; SFP:1102; SCL:1; SRVR:MWHPR04MB0511; H:milsmgep15.sandisk.com; FPR:; SPF:Pass; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; SN1NAM04FT040; 1:hwaRewfqPNaDRUj7payxfLzWbGwLqdzFMnNgFpZdBL0366jdQx9gL+AC946JNap0h83vJ6m/NrIl1EbTLk69JcFNJwXTRKwNVOu3bheNaNKmtepz8g9nHFTgvKsYYewwmrq3xmvol/ZbJIQIcNsbuVWnL7uzkVreWvHL4fVSK2nn91j+Gv6Isfu+lBjf0cnaxqKkO2YYwzztwi+HPd7N6qVNEaJeJC5+hWvkxNWui8eB+YE+qKEYBtIXnm6ibXZHfmDPYKcFWRNQm9Dyw44lxyBQ8T44D2zqhMaxrH71aNJPR731Sn9xvMJbHXDRZapcJO+K2+9KqZ+QJFr8Aw49dC1+M2HNqo2C5//3H3V1h7Qr1uXHTkYPsSnPnBblEGMcsR0N+GGrXzhLTcRGHvvLadOolmmpXqi7msnYlsaPcczsBZloU3szosR1lbMZls2APBF6dngYL3/tiEeVLDz910yil3gQhM1XCi33bm8D82Si7fL+dORaCDT2cGDWSpS8lT17gU/JcEdrlAqYO/NIyiAVzfzcGRHwtGi/e0gUuRo= X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MWHPR04MB0511: X-MS-Office365-Filtering-Correlation-Id: 7e9873d4-6316-4664-83bc-08d49ee51c51 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(8251501002)(2017030254075)(201703131423075)(201703031133081); SRVR:MWHPR04MB0511; X-Microsoft-Exchange-Diagnostics: 1; MWHPR04MB0511; 3:5qGCXl+S9ONDSOQAZRBOZOJm4RNHY2xmlguWlQtiIHeH3vCXdzZiWkCSinOfLaUGXRptkhCcSmBcr6MkNswv01zIbcjvGHRwFVWQ43Cu4cnABEU+k7PScKyNNytNpFxZDZFwNkbgTe+9+VvK0A7du8syk2w8ypl0IAKcNf9bYVPCf0Xd+mHGX1ZeiuORdJ42SO7SnqdevwAQt3hqXUmDq2a8VkvuYgNX9uyG7fPGGPdUgBJ8w285yUrTkLiBeRywd7GOq1qW6mMGAOD2yycvbTigokoqI6UVWBna8FwCu0grPvYEGkFQCkiostTotOOn+o247gP9CMabl7sCRJoJvHtqln7kAkcieqmvZllSXUsdsOPnAKpQllAeHQgCc5PmrR9THCb6eewH8h49dTpHGXWJ0dwx82d6Q/pivWWP1OTaHMqR6744iuY54OaRgNCCjHmYyM8asxzUNyXk52vom87xrQ9sfI0u/IU6lPNC6iQRk/l0g4jZc+7f3MpwQNy0 X-Microsoft-Exchange-Diagnostics: 1; MWHPR04MB0511; 25:RlIxHrGQj98tGl+fmexeAXxC1wCFgajLYUdMiQTeuvTFX9/fjBGqKKgvXH45Tr3k11JrqSyQ5CxSZevuYgy9TJxzPnDgaQphlOC7c0FRjThs9XeRhYxteggWOyc3RYpJ3uqBxt7BX5WHuuI7IjsNqVGi3DGaIWFfA0XbxM/yU53n4KtKVsYfubGIAkzDvTrrqh09/FYNwTAOYOrgLgoaOcWbJ6+Tn21/5i+IEItGpbET04to1ZI9u99iEnSQdLmvzAsQ0cAzXWZGD4dvrk12rPOKlB0DexW71e54w9uMVxSulaHrx1KZXvZ24bQVG+tfHBexOZvg2sARTE87Eolsh+CtOcGYeCLmsF4x/b9KqmiiJ3qHfQAqHv/2pW5lUqUgYNYLvB2fYRPVgQg3Sj73eiKeP1ogg1QMErsKJ/j+b9pp/KucZgAtrvEo0u6cbbpasLp3/goBV3FMoGqbrzvinZG8X+ELFvey2lG1KUEf3fA=; 31:R1YxCVYRzPvv5sxWEuGBZsLeYsZVcMvd88JK0Bkuw6NXllWNtG+EPqOlmgWo5/7LVIlNs16J+58vBdDdO3zx96tnMz+Ees/m6h8VlXtvTlWZC3zDlZhPLycyJA+yiGSsRhb8ELn0eek54y134nu1xU9LvzJmqjcFe1QTaDqa1hTfclj3NpmB4P9ysKVCNQICpqR51XTclQQhdHUzH8KGch0+xKmEEbxypS8OZ/eQxOh5rbQWP9b09o4L/89bw1uwvNfVmrcfKFnKY52n7zVbWg== WDCIPOUTBOUND: EOP-TRUE X-Microsoft-Exchange-Diagnostics: 1; MWHPR04MB0511; 20:X5H1XZej3WUDrTR2mzV1g9LDhvOJ0lgLnnigKnHz8yrhgav4RgAfWoOB+Ez5zY3yfqb9YUVT+PLVHjTS6Qwt8z8ZM0TLU/mZ69twjSrjweJuPxIA5Vi/l5zLXkS64U2pQAi+PUx5uocwW+A3khYw9cHPvuCLveVDTAId9oGmFKI0zko33vXJgrs3Ipjpum1obIjyAJeujtCfjO9SVmYAJRs6PPfcRHWgyrneWSPMr2c3ya0MnLNUCp56mi75gdStZAtg+5W0PvyQ8N4Ej9+pJy3hme8FFlTUVasuzqbQ8/LDBZmnwu0WvwhSbyusfzN+EsuYAlhVlm6YGJjLkEjZJ4kpyj7Z3M6Rx1lc1mZ2I48Hxw2nywGo6fpXS0GrbaCil5DJll50rRUBIKoj5D51tb9A7q0ymqWmEqGNU6MoXNOomXJ8WKA37oJPAbmkYbPvjkqqEiVeqYkU/FPCpdHl6p8XBO4lgZkJ4UKm6ISvYpU9V4wU0a90bOp+kSdUu8+s X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(9452136761055)(67672495146484)(42932892334569); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(13018025)(8121501046)(13016025)(5005006)(93006095)(93004095)(10201501046)(3002001)(6055026)(6041248)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123558100)(20161123555025)(20161123564025)(20161123560025)(6072148); SRVR:MWHPR04MB0511; BCL:0; PCL:0; RULEID:; SRVR:MWHPR04MB0511; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR04MB0511; 4:Z3JLl9upuhyj+IavyBPhHGiKJUdOKjjpHDB/JZmw2r?= =?us-ascii?Q?/h2G1qE7tqIQUyyuLans0ltHPXag+1BGHXIMuh088UTGbXDZ4TyrxAAwwZOz?= =?us-ascii?Q?7q5KI/qtX1fymqeIjriv9hbGaOI6Niw9pAiaIPxoPKGsJzClV3yD/mOcvkfR?= =?us-ascii?Q?hVZc/UY91cFCofkBd989ofJevalcV6qNH72dW4M0CU1RbRDCof+rFNnq+7P0?= =?us-ascii?Q?GGMBvO65LxePOJAGkcTIRebPQ30NGxON4cpi4QzRlspp6xpC4gC+psd631u+?= =?us-ascii?Q?HNOz5xyXGWISvs6JtIMLruE/8TYCxSP0+2MZ3a0EU+nExxt2rRw95AvhBXl0?= =?us-ascii?Q?IAIrQXo69eM2lxBGoG7hypEMxpNInqWsjzsX4SRhh1KJE9zGR6AsFZMu9qTv?= =?us-ascii?Q?9VaZfHbBOgWIdFi9MIgkryZtoXhsXaqtoBzXNK70jCKAXfjrHaAVpyy7mHnC?= =?us-ascii?Q?PtnF2tytR8TlFMmjpEjFA/CkFHOwIyUufRS9auZ+rgD9hpBIvZE8Y0OrdtBe?= =?us-ascii?Q?RqPSj/6j6/cYMTG7uj+HL9eo8Ooj0X5fPnVyBUiaRgSeSWCAbd/ddBSbRNxv?= =?us-ascii?Q?O50al6h2n5yM1VsmzPfT646jvpyUzCsaRxqtjc7aQCTN6AdJsYB/wbvvCKdi?= =?us-ascii?Q?x1p9/I3nyg3NJvbBF8s28kSlR7/Mh9nvbJBncaO5hw+v3l8RgWjA4JLHQ2eM?= =?us-ascii?Q?R4cdgfiS2cdxbfPXOSx66JdyEpYwfT8au4icw7bgFhjKrXtcW9rRYi3F10hP?= =?us-ascii?Q?gHqYdWFR7ogEf9a1xIecH/ylXEg2FHkOy7D/hXxnCaEqgnP82+BauRyxFwFJ?= =?us-ascii?Q?NcrUyctixowrFoAc9jMw1te9KlqgQHgmAmSHL6+CuDih2hq+xMG023Do3LT3?= =?us-ascii?Q?kwfL83cnhBs3PViELFtPMDrtLpGCI0X4DP0vEQftvsT+/RKWC/1zDoukERKH?= =?us-ascii?Q?nxGncfXtHtS2x+3+C/JBiMXH7EDdIEgWG9nGdLWA=3D=3D?= X-Forefront-PRVS: 031257FE13 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; MWHPR04MB0511; 23:4l87SY13LqAAIP7HkZao9BmJ0W42fzQ/FQPKfd+c0?= =?us-ascii?Q?shl7acAC+ruziS2eZAI6KsSYHHnMA3NTCyeXxcb9yJ4WfA3iRu6i8uGGZnJH?= =?us-ascii?Q?5CpZ/1NLCm6236XVNpORnijx13huSOT8YNpLwqzPwSTsDBz80RbQLIEMrrv8?= =?us-ascii?Q?Vi3neACiZFQyARCT4g+V8V5UtqPNUZrKn+My6UbVECdl4AnGIy90A3wuD8H/?= =?us-ascii?Q?YlW4x67T4RB6RsK+3cpn7dnNsejehUy2SqKby7nB6cZpXszmNWxldybzZVyW?= =?us-ascii?Q?Zjf3zK8sbEwON6754SaT3LVzxyLWEpodRKQbnev6T+upX+DBtxrgqAbG92JJ?= =?us-ascii?Q?vwyXIhZE+vN7zpkqUdDUjx6jVaL6wE2HaKMdBzikknS6fdgetmRBVnzrPBb2?= =?us-ascii?Q?WOm6QCP41iZtXorexSyYQQ8UnteA19PAUoNtqJvzCTQfbSiIRww/0Wv9Alep?= =?us-ascii?Q?mW7+juW83iGM9Nzvu+iKgqL4+RPnKCPN31ZIYqsAitWuW/AvjuGkAVrFfXs9?= =?us-ascii?Q?2mEZAwV29Wi0l+JOu/bGvZ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ginalArrivalTime: 19 May 2017 18:30:21.8073 (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: MWHPR04MB0511 Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This function will be used by later patches in this series. Signed-off-by: Bart Van Assche Cc: Jens Axboe Cc: Christoph Hellwig Cc: Omar Sandoval Cc: Hannes Reinecke Cc: linux-block@vger.kernel.org Reviewed-by: Christoph Hellwig --- block/blk-core.c | 10 ++++++++++ include/linux/blkdev.h | 1 + 2 files changed, 11 insertions(+) diff --git a/block/blk-core.c b/block/blk-core.c index c7068520794b..a69d420b7ff0 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -601,6 +601,16 @@ static void free_request_simple(void *element, void *data) kmem_cache_free(request_cachep, element); } +/** + * blk_queue_cmd_size - size in bytes of driver-private request data + * @q: request queue pointer + */ +int blk_queue_cmd_size(struct request_queue *q) +{ + return q->mq_ops ? q->tag_set->cmd_size : q->cmd_size; +} +EXPORT_SYMBOL_GPL(blk_queue_cmd_size); + static void *alloc_request_size(gfp_t gfp_mask, void *data) { struct request_queue *q = data; diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index b5d1e27631ee..75b71374e1ba 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -1212,6 +1212,7 @@ extern int blk_rq_map_sg(struct request_queue *, struct request *, struct scatte extern void blk_dump_rq_flags(struct request *, char *); extern long nr_blockdev_pages(void); +int blk_queue_cmd_size(struct request_queue *q); bool __must_check blk_get_queue(struct request_queue *); struct request_queue *blk_alloc_queue(gfp_t); struct request_queue *blk_alloc_queue_node(gfp_t, int);