Message ID | 1476772835-18541-5-git-send-email-damien.lemoal@wdc.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-block-owner@kernel.org> 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 CE8D960487 for <patchwork-linux-block@patchwork.kernel.org>; Tue, 18 Oct 2016 06:41:47 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BD1CD28C99 for <patchwork-linux-block@patchwork.kernel.org>; Tue, 18 Oct 2016 06:41:47 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B1C0D293D9; Tue, 18 Oct 2016 06:41:47 +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 4561728C99 for <patchwork-linux-block@patchwork.kernel.org>; Tue, 18 Oct 2016 06:41:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757874AbcJRGlq (ORCPT <rfc822;patchwork-linux-block@patchwork.kernel.org>); Tue, 18 Oct 2016 02:41:46 -0400 Received: from esa2.hgst.iphmx.com ([68.232.143.124]:6972 "EHLO esa2.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757845AbcJRGlk (ORCPT <rfc822;linux-block@vger.kernel.org>); Tue, 18 Oct 2016 02:41:40 -0400 X-IronPort-AV: E=Sophos;i="5.31,508,1473091200"; d="scan'";a="22753075" 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; 18 Oct 2016 14:41:39 +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=8CsNm8rDz2vYJvZ/VqzzvJ3OR+RQutAVk+djWOIQ4n8=; b=EKe634tRCppnMzBLlJd6qqF7BJj0rkpgrM/DLl1osLAQtpHki4fKp4E/AVW3M9UHPkubDhdrLyDGHcZyzEKD6De4DNyrY5NjwpK2cwcSEbiEfbIIaQ5Fyj5TeANsuArBVpPvVTkn2kieHcsMiUPl6zknMKj8h2tJ/FpdqCKKl2I= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Damien.LeMoal@wdc.com; Received: from washi.fujisawa.hgst.com (199.255.47.8) by SN1PR04MB1982.namprd04.prod.outlook.com (10.166.69.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.659.11; Tue, 18 Oct 2016 06:41:36 +0000 From: Damien Le Moal <damien.lemoal@wdc.com> To: Jens Axboe <axboe@kernel.dk> CC: <linux-block@vger.kernel.org>, <linux-scsi@vger.kernel.org>, Christoph Hellwig <hch@lst.de>, "Martin K . Petersen" <martin.petersen@oracle.com>, Hannes Reinecke <hare@suse.de>, Shaun Tancheff <shaun@tancheff.com>, Shaun Tancheff <shaun.tancheff@seagate.com>, Damien Le Moal <damien.lemoal@hgst.com> Subject: [PATCH v8 4/7] block: Define zoned block device operations Date: Tue, 18 Oct 2016 15:40:32 +0900 Message-ID: <1476772835-18541-5-git-send-email-damien.lemoal@wdc.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1476772835-18541-1-git-send-email-damien.lemoal@wdc.com> References: <1476772835-18541-1-git-send-email-damien.lemoal@wdc.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [199.255.47.8] X-ClientProxiedBy: CO2PR06CA014.namprd06.prod.outlook.com (10.141.242.14) To SN1PR04MB1982.namprd04.prod.outlook.com (10.166.69.142) X-MS-Office365-Filtering-Correlation-Id: 3e0326d0-a8db-4fbf-9f8e-08d3f721cfe3 X-Microsoft-Exchange-Diagnostics: 1; SN1PR04MB1982; 2:jxLUaqwvy+4FNfAo7hKsSLj0+/0Ckx8P+bRYS22Kwe6H5sNo87/m4YEq2LH8TAyxOVGh1E2+dHWOGpDbA0Xslny0h2H51oFew5UC+Pvug8SpCfPeIj0CTLzYIobPm7WTp63A+Do+AV67+85T8Z8pdi+dH7R7KCd6xpy2JEqgRDleVv5fcMYtvQ15X0qfCpwZ9DrE3aBXPtduH3Vzk4u5WQ==; 3:/NXt+dfDYr+oO97sHQ4xL/B1zw8Pt+/A80ayo6YkPE+U/2F0ZHNwzXwYlPyy6ftEs7uoQEoo5BqTlAsBSfuW45NRgchzSEdz5o1piZE3Y3fVsirBhLiX2ESveU2gx9EViiEvCGp8RK6TSn3m/3xU+A==; 25:XKgRlGAQom3pvmUeALtt4gCvGgplPeeY18/ScJEP88DBDjEw0mNkhD5FhItZjxbtPnp1L+OM+5kt4HIUxxyuJgyrwopqF9JWWYhw01ROADTkFDzEW9glW30wCTURyR7Ul2/QXur7tYCMs8qrpn8WwLNv0p0PTKZILq50J/8l2FAdYpxXW1as8b+TkTNSN7OdPp1KcAHDFeuy2iT2zEulvjVEQOazD8mSXRKhpGckby8Gg4eC/R2qHMsTRRQDoyjMgGK2sJEVIFCcIWuxTKBx19t44ClNmcFgxb5aFThKLmhGYbjfAO/y0qfpSBzzD5VlHFp9a+S4NGrlkMn8wmAb6yuIpfTjWAjlqelI2PT5yeAtFW+xm6AIAMccdcXQezIB8GM+q3zQ4K8hD1wbu/rZiqEZRngRmGym08qs9j/X+uPCDX6TzXnAyo1gu2hA7vxD X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:SN1PR04MB1982; X-Microsoft-Exchange-Diagnostics: 1; SN1PR04MB1982; 31:eQA+F02vNsDns5uzKqHCkgLCnfJ9C9llpG4Gnu88jqKLAsMOrQG9JtHDKeug1E2l2rrQKqQAvHwjVdOfaMsjXVqUk/BXRevcLdVc1WWoBPza+L7kpoiVuDtWzRJdETzSwHMfIng9eGWFqdGwiPTDTwHdWkwMBdTQa+s0qBdTIY2DhAWTZRyi44G3xp0JRBIT5ZV55FSGzsRDH6A1nMXrkUxskeENpV22p4yydS0wpP7q+BkjbX4EC9clPxChhJ3H; 20:wnn1mBWjGkjXEVKQ+oWFoTlbDO4Dhw5anRHhWs12SEch9M4oqThLKQxiW6EE0KlkvS+q/VLEYKqZ7ePmCg7tHoigXSkIAVjQZHIDklRLg6g+IX+L4+XuCBYoQ3ciEx8wE0CGdLc7Z2htX057X8TAghz+R1/hH6wiOALfcszAX2vMEWJVzLVdBfVkxV8ZSc68Ya18q1bPFniGg0T+eSKpCzaPPIl5QWBANdiGIlxCoEb77FtxmKD2Jd+x0tPumSS0iynDYoAO8gR2LOId36/NRj/YpESWvKvp61bd1PYZdlz60bo0Xp4HGvKhfNZ4ywnrXlOW0n9w9ki2riu4I7rNovkNwAZTc4lBmjtWJyKFjg+VpZRJVKPlOwSKbS6oPrCRive0WIZvZnoo9MWH81+p2fB7ZvKPzBJY5d3PTixtoExFcXwhscNQGZrQYfDe+0qo45ocsl+yqt+fDcHXsZwUIYTn5jdvSK3fBYUTn71LukNl57V7XuaZhrZeyOGF+g8j X-Microsoft-Antispam-PRVS: <SN1PR04MB19824E76CAB810B89697A803E7D30@SN1PR04MB1982.namprd04.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(79135771888625)(146099531331640); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040176)(601004)(2401047)(5005006)(8121501046)(10201501046)(3002001)(6055026); SRVR:SN1PR04MB1982; BCL:0; PCL:0; RULEID:; SRVR:SN1PR04MB1982; X-Microsoft-Exchange-Diagnostics: 1; SN1PR04MB1982; 4:JJqxBfNkH8gM1GySc679XB19VTtK3aURVQrNf0dQE1IZOJtpTNLaTDy1683Z8RL+VHAD/VGWFG1jOCvkb7Qr6JtgVR6jX87XB9Q9VP880Acw9+52MiGMbJm/++eQJc9j+sga5b/4E6Ypjv1HlGJuyVgVMZBWGEMNGyjn18J4I2ObCquD40ou6OXpFngT8xxn+RQKw7hiwvlN/XHkvZuXJBIznNG0D3UhDCrzk5RRwaFf/rYe6pY7pHlnsoVKjr2Or9Mn6lKX5RbW9G70LtPRApl2cPFxVa0OHoL/vrppThVrlqMWLmPrxGyOaRXBJlbuUidCzsSAGbtFyK15bJLcphq6iJMHZUWBQOfhGr3iTBIDrueaye5U10PSH4ErLz0i3JP9Eonn8BpK5bWq/HWCOTSEsuZP+kV+jRHdhFnR72X/aEaEIe7FhDXhztvHk7znuiEpR1MENLZXPlnwju26BwsHBM3zzEDBHGl7sbLmJWj0iwdCD46YPnGn5whdUze0 X-Forefront-PRVS: 00997889E7 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(4630300001)(6009001)(7916002)(189002)(199003)(81166006)(81156014)(97736004)(3846002)(586003)(19580395003)(19580405001)(105586002)(4326007)(6116002)(68736007)(42186005)(106356001)(50226002)(2906002)(8676002)(33646002)(2950100002)(66066001)(47776003)(189998001)(7736002)(5003940100001)(7846002)(5660300001)(101416001)(229853001)(6916009)(110136003)(6666003)(50986999)(36756003)(76176999)(86362001)(48376002)(50466002)(92566002)(305945005)(107886002)(4001430100002)(77096005)(7099028); DIR:OUT; SFP:1102; SCL:1; SRVR:SN1PR04MB1982; H:washi.fujisawa.hgst.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: wdc.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN1PR04MB1982; 23:6AS0z6ylnFKIutnSP7IYaLsh5SIAq4DUyTdTISRje?= =?us-ascii?Q?yJHq2EkfInD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GgA3nie09/1wGrQKf3RZPxv1Vgg2NvRVcRC6wKaelXH4Hlp+upBbkWHt+ASh389LnwpyugKBjPBg7w0n3BTzRGifNfBPOV9tgjkUx7U4gKc2MZqm1mf9SxKF2a5IrPcJs1I8al+QwO69KcYEkSS77JBuCOwdz/PR7ONyoIzbSkJFegJrPv4+bL184X/d2xpbr+qEXGzwrMgFma8RvmrsUhUXQB7lxBV3zNfIGKK8N83+yi2KdlA5cvrKcRyYo+dVUF6Mc3Y2GnLdG+Vd+6eLPF5LxQuY5FAcJhsoGF5glgaOvcWtUiYdAosGxrQwo8JSa7qO+etmnkzLSAaiSrVM=; 20:G3V6vzwLRUR8BcoH30vODeAVmXUVENHa6WjX2isiEkHFcCZWDHAFMarSu6HwFje+WNPCC0/9Ww7hkd13bHQccTPap3TIq4c4A4uQxfdBE4jyvumHTDSv7eg2ccafYge43r4lpzT6YLnmfa/zM+Oy3Kt/ibEdHyHPhFQ+U4I61pry4ZbaRk0wlwtf/3/NjJVyeDPdjz4XSTcVrlTFgmtHw2DCZJirXi3nfBhBhuAkYnQR8skBAkVovh/r2wj8FBBG X-OriginatorOrg: wdc.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 18 Oct 2016 06:41:36.5497 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN1PR04MB1982 Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: <linux-block.vger.kernel.org> X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/block/blk-core.c b/block/blk-core.c index 14d7c07..e4eda5d 100644 --- a/block/blk-core.c +++ b/block/blk-core.c @@ -1941,6 +1941,10 @@ generic_make_request_checks(struct bio *bio) case REQ_OP_WRITE_SAME: if (!bdev_write_same(bio->bi_bdev)) goto not_supported; + case REQ_OP_ZONE_REPORT: + case REQ_OP_ZONE_RESET: + if (!bdev_is_zoned(bio->bi_bdev)) + goto not_supported; break; default: break; diff --git a/include/linux/blk_types.h b/include/linux/blk_types.h index cd395ec..dd50dce 100644 --- a/include/linux/blk_types.h +++ b/include/linux/blk_types.h @@ -243,6 +243,8 @@ enum req_op { REQ_OP_SECURE_ERASE, /* request to securely erase sectors */ REQ_OP_WRITE_SAME, /* write same block many times */ REQ_OP_FLUSH, /* request for cache flush */ + REQ_OP_ZONE_REPORT, /* Get zone information */ + REQ_OP_ZONE_RESET, /* Reset a zone write pointer */ }; #define REQ_OP_BITS 3