Message ID | 1474320454-5264-4-git-send-email-damien.lemoal@hgst.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 1F7D0607D0 for <patchwork-linux-block@patchwork.kernel.org>; Mon, 19 Sep 2016 21:28:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 112A029909 for <patchwork-linux-block@patchwork.kernel.org>; Mon, 19 Sep 2016 21:28:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0547A29906; Mon, 19 Sep 2016 21:28:41 +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 8E47029906 for <patchwork-linux-block@patchwork.kernel.org>; Mon, 19 Sep 2016 21:28:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932565AbcISV2j (ORCPT <rfc822;patchwork-linux-block@patchwork.kernel.org>); Mon, 19 Sep 2016 17:28:39 -0400 Received: from esa2.hgst.iphmx.com ([68.232.143.124]:34625 "EHLO esa2.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932329AbcISV2g (ORCPT <rfc822;linux-block@vger.kernel.org>); Mon, 19 Sep 2016 17:28:36 -0400 X-IronPort-AV: E=Sophos;i="5.30,363,1470672000"; d="scan'208";a="15969632" Received: from mail-bn3nam01lp0180.outbound.protection.outlook.com (HELO NAM01-BN3-obe.outbound.protection.outlook.com) ([216.32.180.180]) by ob1.hgst.iphmx.com with ESMTP; 20 Sep 2016 05:27:59 +0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sharedspace.onmicrosoft.com; s=selector1-hgst-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=WIBMaGwskpFb3cs19XwWtPQWOJm0joWtF08wwiE7/iM=; b=UIVDid9bv3dkbjV5IXLcqZcvoGV+Y1FmxqBB6pXajXXeG3h7Xi4ta2K+YI4K4h3ff3L4nPAgA8rwwTcd4bZFum8vfU6Fsf+NbxGp/gF3bzNvJlCpixZjtOMWJT15SOtNfPfd10ag0m0qw7p6M62Teupy1HAyLhQpclnuDS9GZEI= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Damien.LeMoal@hgst.com; Received: from localhost.localdomain.localdomain (4.28.11.153) by BY2PR04MB1975.namprd04.prod.outlook.com (10.166.111.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.629.8; Mon, 19 Sep 2016 21:27:56 +0000 From: Damien Le Moal <damien.lemoal@hgst.com> To: <linux-scsi@vger.kernel.org>, <linux-block@vger.kernel.org> CC: <martin.petersen@oracle.com>, <axboe@kernel.dk>, <hare@suse.de>, <shaun.tancheff@seagate.com>, Hannes Reinecke <hare@suse.com>, Damien Le Moal <damien.lemoal@hgst.com> Subject: [PATCH 3/9] block: update chunk_sectors in blk_stack_limits() Date: Tue, 20 Sep 2016 06:27:28 +0900 Message-ID: <1474320454-5264-4-git-send-email-damien.lemoal@hgst.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1474320454-5264-1-git-send-email-damien.lemoal@hgst.com> References: <1474320454-5264-1-git-send-email-damien.lemoal@hgst.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [4.28.11.153] X-ClientProxiedBy: BY2PR12CA0038.namprd12.prod.outlook.com (10.160.121.48) To BY2PR04MB1975.namprd04.prod.outlook.com (10.166.111.15) X-MS-Office365-Filtering-Correlation-Id: 90bd6f38-df02-4516-f97d-08d3e0d3d271 X-Microsoft-Exchange-Diagnostics: 1; BY2PR04MB1975; 2:TtcfByPaDgC1K+4WzWSWPGYOdTwePBqwK+0omHY7V7/DjVteTk9ziDT0el/hYdGBh20c0mV40qKTeXRRQzaF5jckkB6mmImAKqpmXHwlLcLU9NtdUBY4BQKRLy9cI2ndsbCH2zDR89ISWXfvw36BPomI08LXIsPdRzt9+rp2+lY0x8Vkt+q4GRT7WDbYd5kV; 3:HBtOgF7Zi8JJkcty7r/E2YLfW/dKHYxlGl+gCBQhKPejNG/nOHomlgPj8FRVi5QE+fsIvXffn6c4HfmIcSEZY7dqIraY3c0og1Qc7K+2lM2ywFDS1BYPk7aoAzuUOYUy; 25:Kd+PCGJOAwCBcP1j/cnAQlLF90haxuLO8JXaA7fF757gpnFHAe6Me9ErZzhOBgGo6ut1rjU1kpiIQY/pfTotTbzBGK8ZBEV3QIiaFPO80vJVWx+iOS9jLrrm6b6pG7hR++98NL8FkZkttvYXyST6Jywoi9ZWz55muJvuqJTn8XSTiMdn82uAg6CFiYlV5DVcWpo08QVmstXwapZuEnV0eGkHHRmW+85JeGz6qhnzGHsEy7aaHtZATBwo1RJ9pnQ2LG98g4lxyct+8539TKzQbXu6kBOVauI6Pm4TrX5m5vrGK5bTMFY8IE9wtCQ8sMBrSZYwSfAnXrGPMtKj7Q7qN54x+NHDaQf6biw0XcLDW1rEtr9x7/fy10tad9a8LT4MbO8d5l3qfZ3eK/irESqwH1XH/tfKOieIDqAroGZJsyU= X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY2PR04MB1975; X-Microsoft-Exchange-Diagnostics: 1; BY2PR04MB1975; 31:Gk+9WcJP4M8rv20mqMsa/WBOpL3umrW4xPN/kLA2NzcbS2kQPVRfKUI8xg1TEirJOK0fdjXeaj60UyOkMIS5qPsaw0SyQpF4Gqe9sHhQhAhxKNzVEnxLXL5JKJJ7FKuXmwc14d87D2qpWiRhQd3lJyNZfSdHjwGYf8ibt82j46AcCVz+XmYKC+l7HocacrUVE7+4/NRl4QTJKpGzznLzPzLZRNN2mElSqWjV6X74tzQ=; 20:SZQF/FQlxb88JBdyoadxvBXFp8W9ijlot7izfVK3p/Kv9nO3c2UzRrgtnQL2BhpWoBpZWAebdOI3nz5fj0Rx6ZpjdZ0FwlRPsIEK7tHN68IpE2mlj6pHQbeTi3+NwznlYMcsyB+czuVi2DNdpL7t+tR6aMkkZNiXSQBrVQx1A5nfIY64jlQukcU3f/laN3e5w2RHV8zSn9WLO1ZRsN0UtnOHlNrHOuuUPLEZWgvIlvD8qbtgS7niEAb+ycB7Z0Gtjgm4Cw1fxdgH4SmwMsd8JBy1qJ2OrzWtiZbXi0Br0QDMpLeByDIuRDa2VNBgmzkkdMUy6ioZR9m7c5M+10ncDbP/inX4qKAgFlrdMuFoBwydDKeiwD1NyrM9ZcqvpmoKPUq2ixmYj07QtsC5Vw6m3xGGHAIyQZ7M3eA0o6i/VAs77fII4beww3diWiL+/MdgrWCyAAur1TDqXuR7/9ORBwpUsig4wiMSNdZDvjtEFaLbs2YvBIUdT3urO4ZtCu/M X-Microsoft-Antispam-PRVS: <BY2PR04MB1975FBB2B051AA325385FCC69FF40@BY2PR04MB1975.namprd04.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(79135771888625); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040176)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046)(6055026); SRVR:BY2PR04MB1975; BCL:0; PCL:0; RULEID:; SRVR:BY2PR04MB1975; X-Microsoft-Exchange-Diagnostics: 1; BY2PR04MB1975; 4:QAdAsRzxhJSpBG4iSzr2icJ5l5ziI86wAT4FGfDAZ0yKD/Kk59gDluL2pZViyJ6DpOuIw8s0eJjmnyYsVcV1bON8q7Fk1tDTYMT3HEIvfbUKkvPbdvfkX7gTR0HtE+Ssq1Xg78I8SXgMVDdl+5ud4z5AnPVrBTT5S/Sjf4qbK+AVmX4dWrgrP/GgXMLr54ebxFNffDKyV/Uvwcub++fJ78EnGeO3em9cxpitnhcmc76oFEIGxG9Mzu+a3/8Ojfsc6ZEMwW1L9ab6RQABcrhVYZdVhbvmgr7CfMetoFIa9Vtni52rVSSMbDy+k95euS8rT2Q6OSW0t5nBpLxnerYCHurRMXNX/WiTc0UeDZhPszNhxpMEEaIG/sqTN0HXMgW1+0liDf4CDnJOdmo1Cpj0731gr+iP0qRQ1auNSUFtA1ybANFzOGi5Bwr6TBii+GUQbvQHnfwqgd3bkNA3MuJaRw== X-Forefront-PRVS: 0070A8666B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(4630300001)(6009001)(6069001)(7916002)(199003)(189002)(4001430100002)(305945005)(5660300001)(2950100001)(5003940100001)(86362001)(47776003)(33646002)(66066001)(97736004)(5001770100001)(50986999)(2906002)(229853001)(6116002)(4326007)(3846002)(76176999)(189998001)(101416001)(106356001)(105586002)(586003)(42186005)(77096005)(36756003)(50466002)(48376002)(19580405001)(81166006)(37156001)(92566002)(7736002)(8676002)(50226002)(68736007)(19580395003)(81156014)(7846002)(107886002); DIR:OUT; SFP:1102; SCL:1; SRVR:BY2PR04MB1975; H:localhost.localdomain.localdomain; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: hgst.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BY2PR04MB1975; 23:N2/ZZrt89auaSNbPQm96SNyC+5MNsfHXoLwM+z2c3?= =?us-ascii?Q?C/dP1OOR9L9SbPaqeS4pzfSlbO3cotRg0ECwnr9FXd50mTJ999vU5mj93Wkf?= =?us-ascii?Q?VqnSqQ0iMovtVqIab1y1HVH0RnbBK6X8oiOQnKNYxyVl/zqOrIRPxafGehFB?= =?us-ascii?Q?4nuruF3RbVBWAcp/p3L9lQ22Z23RGJn/0RWv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1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BY2PR04MB1975; 20:CgNFUe/pZ2JnB47o4k48D5pC07EPwAjX2NYqDAtBMoFCvhorEVyF9HrwnpU2VQHI7I/y074br5fG9tmKyZUMh69ANN5ctMEI5LSiS0XnXfsBWRByFBBmcR6BWvecPm3bTaRlzSybcrwNQ3W5CWx1RAa1tzUJ0fZDBooIx4xgTar0XRvI2wYwIcZmgbq88OQfExIuICuG9Oph3uyUoUWjsn/UpFk9RYD+OmvHZ3rc+0Nde0vRkivwSsdNawdrg68B X-OriginatorOrg: hgst.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Sep 2016 21:27:56.0225 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY2PR04MB1975 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-settings.c b/block/blk-settings.c index b1d5b7f..55369a6 100644 --- a/block/blk-settings.c +++ b/block/blk-settings.c @@ -631,6 +631,10 @@ int blk_stack_limits(struct queue_limits *t, struct queue_limits *b, t->discard_granularity; } + if (b->chunk_sectors) + t->chunk_sectors = min_not_zero(t->chunk_sectors, + b->chunk_sectors); + return ret; } EXPORT_SYMBOL(blk_stack_limits);