From patchwork Wed Feb 28 13:36:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 129989 Delivered-To: patch@linaro.org Received: by 10.46.66.2 with SMTP id p2csp1033751lja; Wed, 28 Feb 2018 05:37:24 -0800 (PST) X-Google-Smtp-Source: AH8x224RCXo7gkrchoRDCavljJytfDsU4ShWVGTKFlsRNpEFP7zPz4Fz1W2D41FGXFRkXHz4Q42p X-Received: by 2002:a17:902:12e:: with SMTP id 43-v6mr18026181plb.77.1519825043894; Wed, 28 Feb 2018 05:37:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519825043; cv=none; d=google.com; s=arc-20160816; b=qT2fwE6gDQR8c7xo1AZq82NmZjoeSharvDr3f5g+FYGgoQRbBWcaI0plh7dg7lWP/w q5T0VzxcNaoymCAvFWh/EVrPHSFaqcvRbV3beuk7QS3fdtyjwYKAue4iczX1A7aIzd6R jChKOqIJ8QVlm04/ljW7IbDekPf+w36WILsjvEeRO3ou/tTYl/NT5ABJPW6+5ewVkzAi nR9menEzcrXPwgOI6/f96qZB7yNABpkCPe/16GhBXsZNUfnCQQKjAdMwVVFeB8/33knq 9Ob308yhU2oRxDsCfNWjmnrsCbVpY0A2LOGQIRXi0n2cuBzxhWnhbyeOZTLTEufV+xYD 9U+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=66EAEzxyDyheykQGddiUbUzBjyMkuaz5Z4U1sx/mWiU=; b=kQvX+3EVxarVbTCvbMxlGxjTnJy6bxW83Jz0/4GRgxLd8JpzHhaz9LUQmqddPMETIZ UA1mSRXvJce3UKOKdkpa2fFBKeT+npleYQTl4SUTZYBqvnLyFQA9LYfQzshE/OIEfhz3 JTFoEl5/w7CH1pC5PEPf15YY9I/+bP/Hex20LIH7YR0N7pke9UiddPDQHW/iNHOc/Gqn W1pH17kRQsayPXOLgT/j8ARwqsGMSbc7X/Esk8T4jk4guR23Sjs34DJ5FSyBGZYCsOUB 4ZOAXIhQAeM/Y83kTJ/wBUwjOM5pYzEA5AQv0Ka5KdgOZ9DeTdLMt3reFYgCewaYICQD 6LiQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b5si1050901pgc.139.2018.02.28.05.37.23; Wed, 28 Feb 2018 05:37:23 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752607AbeB1NhU (ORCPT + 28 others); Wed, 28 Feb 2018 08:37:20 -0500 Received: from mout.kundenserver.de ([217.72.192.74]:43375 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752213AbeB1NhS (ORCPT ); Wed, 28 Feb 2018 08:37:18 -0500 Received: from wuerfel.lan ([95.208.111.237]) by mrelayeu.kundenserver.de (mreue103 [212.227.15.145]) with ESMTPA (Nemesis) id 0MUlX2-1fE9r73VGu-00YEBz; Wed, 28 Feb 2018 14:37:01 +0100 From: Arnd Bergmann To: Jan Kara Cc: Arnd Bergmann , Dan Williams , =?utf-8?q?Ernesto_A=2E_Fern?= =?utf-8?b?w6FuZGV6?= , Andreas Dilger , Andreas Gruenbacher , Tejun Heo , linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] ext2: fix FS_IOMAP dependency Date: Wed, 28 Feb 2018 14:36:46 +0100 Message-Id: <20180228133659.1933887-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:QLgoVtqwo+OE9Zuf9mowFLDKV5iWIlW9HOA1em3McnlLF3lU4Km dCYtwuC/P9AJA8w689lWfFbM0x/sdzCJBVku5MKlUkJzrW6XkrNr5mysw5MGFgKQ0bmqWG5 ZjCxEQ8QaaeK/18OHA4LeQo+1pEBQmivcVEdTGCaMwvoml+nJDviohWOYP3Z69+37/uxd77 GlOa2Oqfcbl4GKHXTkzJg== X-UI-Out-Filterresults: notjunk:1; V01:K0:6A5+WzYm0XE=:reiuR2Vt6axJUZQosR2pLL vYLQKPhfOzWcfEFerS2BdaMoq9CUABzn5O7spC65xLeWcoozzUB5yV3e9Z0tODG6h7mZvWLDW vmkIh1eKndQvAqXXnlw7xIVh1YkM0bKBbSMkhXxkR2RUhaxTH8D3WCiilk+v5Zjcv/AF5YT79 5fVXpv/DzLOlOWNJUNGVI+sE9zXXRZzmd2RBLg4AXDXFQiLXdY+asKZ1g06Pic3X0XvxnbT+K CortUVmU37rk1V2s9p4OUQozfn/fvYsf9xGA4QgCJNMjYw2ONTWntfOC5wb18YVpTLaT4HFLI 3wgZvoFqaiFRrYvPM7aQyxcPHjElc+v3VOPm+wQKzB4/CxGVa8uSF08c+bJdvfMQAzTjUbbdx GT8+k4ufnd6gVW3MIe95r/LtmAUTZPXeZxAYzMZq/cn/wE9iuZ98ve7CKkRW1PdO+zjek/l0n cM1v0xR477iXteX2DEa9FBDL36qA9+g34J347rgCbeWNJlUPa4XyIEcnOk55nLNGkYFfvzeb4 DqRrpuDuikH+IR8hOWsbPnFMTzm2kNGCMP6FUqktiWjDBzn8iSvtkYcyu2mIwbAUS3CZ/yTGI r/hB00GPruKGyaR7b7Wqu52XgbrV0PdFPMP2ZsAaISORj1TD1agYULLS/a2bgf/FlBrTmTe/a XG3KFTRATk38xhwwea/phnc1E4UxRNgaisWxa4hHVRef3fxocdagwS/OrtudZqGmSgzhA8JuV KJjtdebXKCkN0bgKxjp75+zTM3GP9TR0Ezthjw== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org I ran into a randconfig link error on next-20180228 that appears to have been caused by an older patch: fs/ext2/inode.o: In function `ext2_setattr': inode.c:(.text+0x19eb): undefined reference to `iomap_zero_range' This adds a compile-time conditional around the code path so the compiler can optimize out the reference in configurations that don't need it anyway. Fixes: 00697eed386d ("ext2: use iomap_zero_range() for zeroing truncated page in DAX path") Signed-off-by: Arnd Bergmann --- fs/ext2/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.9.0 diff --git a/fs/ext2/inode.c b/fs/ext2/inode.c index 5d5e9f7b98d6..6e6db0ab3bd6 100644 --- a/fs/ext2/inode.c +++ b/fs/ext2/inode.c @@ -1296,7 +1296,7 @@ static int ext2_setsize(struct inode *inode, loff_t newsize) inode_dio_wait(inode); - if (IS_DAX(inode)) { + if (IS_ENABLED(CONFIG_FS_DAX) && IS_DAX(inode)) { error = iomap_zero_range(inode, newsize, PAGE_ALIGN(newsize) - newsize, NULL, &ext2_iomap_ops);