From patchwork Wed Dec 19 14:00:40 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Anders Roxell X-Patchwork-Id: 154268 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp4967504ljp; Wed, 19 Dec 2018 06:00:57 -0800 (PST) X-Google-Smtp-Source: AFSGD/VXfhyxOJh+GxmVUlcMu3F03wU8xbacYnGtEGWUgDSsXXbrBlffSNPc7eiEJDmE2gxg8ool X-Received: by 2002:a62:3c1:: with SMTP id 184mr20807355pfd.56.1545228057063; Wed, 19 Dec 2018 06:00:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545228057; cv=none; d=google.com; s=arc-20160816; b=aipAhFzGGMkgO8if2hd1iqhOL1py/QgCgUJq2LJYFDAsdSIUOVqyABqpGnMuPT+2Yn fZCivStkEuLzBYJpqri6Ix+1G1eEvE7nqjZ8FC6yeT3uvhDhGvBySnqfFsaO5Sr39Air k+j1ZYKOzfEzkuVK4NJg/dGrUgiOH2QPHj/T4BdP9p945XujGdJyLrPbdSwPrm3fLPWk egdJvmP21o+74zH9t0Qh8Y89PlTND3eoQLYiS+V879WNMqA2g916Z/mvpjBYnrWY2AM1 mMFVGwQEgVL2HFxZ/a9H/4c7ntmXY25tFAw0porn5rhr0DtMRPw4ZPrJLMz/Y9wtkzVl kWDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=VkwhrtHK+/Xs38/nSuArtykjmfNSxZJzJE7YwYf1RrI=; b=o9AHUW8qe0ZU+tAw7BWPexdCKqQt+tFgPYH3i1XSzwJV0/koieR6Z/BZgheCNZoBt9 HZ3827j+9c/5L2MVVl3oCjkyyVeX2qW4gMHjljfgw85kcJ18bklI2RfhKOlgDsbEx2ZN 7D3ARGc56BrybokUSxL8MWYEcZ4lPdlBWmoJMvJR1XCyg4tcZ+ZE5JmikYgWZrsYmu8w eJ1fpY2vsDsygKZwkcEMY9x4FurpcOm85x8LUK32KgtLSjNG7fP+c91CVuEc9EX+xzsl pX9Tb4ctGH4NVtL8ubfQdcmG0M2R4884eOBNyf6/T5Cy639A1EF7epQ/u8VeN07CfCmf JHaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ToEybDjl; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m3si2361394pgs.8.2018.12.19.06.00.56; Wed, 19 Dec 2018 06:00:57 -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; dkim=pass header.i=@linaro.org header.s=google header.b=ToEybDjl; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729221AbeLSOAs (ORCPT + 31 others); Wed, 19 Dec 2018 09:00:48 -0500 Received: from mail-lj1-f193.google.com ([209.85.208.193]:42135 "EHLO mail-lj1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728967AbeLSOAs (ORCPT ); Wed, 19 Dec 2018 09:00:48 -0500 Received: by mail-lj1-f193.google.com with SMTP id l15-v6so17468684lja.9 for ; Wed, 19 Dec 2018 06:00:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=VkwhrtHK+/Xs38/nSuArtykjmfNSxZJzJE7YwYf1RrI=; b=ToEybDjl/6/bBB/EqKzkhQYAN1sOmFdiGH2+2CJQwaLxw4pBrgR+P2nyg5Jrr9hyN+ sdxbqf7ZYyihec/UPQ78SStVQ4bYKV1hiGqX8WnqjDfjtiKDXmqa4zsJ53QF27Xj3IFv 7Qc/8+iejQ60QRP32EK8UqxvrwQYYPnQrGkIo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=VkwhrtHK+/Xs38/nSuArtykjmfNSxZJzJE7YwYf1RrI=; b=iREKf4C2Yl6lA2zPgIOd/uLvCHvdoOwhQfxhTigv56J946OPiYzu5zdLVmFYoy2iK3 9IGUio+r0ktJgr0q6VvVbrTL/jUT17iwRsfhD/Hhfka1I6wzHMuJhIWRoIdw2fU7Uo8G nmyicnhT2Sf0aUodJVIsYrECkxo90Bz7mz4crakZjlQxuO3shvcccqQRKMH5HwnFmd4k MSBGo+Yp9hay4V92dthSoYVP/6CjEbxB1wyypzbq95T6pWTxXqAa8WixC/dePvluNYsD xn7kuSk08sUN5+NIHQWcJIcqV1Cg7VpYtb88TA4uesjr7CmA+jTA9JMBTbJMGzJSrk5h Ryjg== X-Gm-Message-State: AA+aEWaZDOmz6hN06m9x/tQSdgt6/mALQNW1RpDAntzr0LYhfFOaugai FRx3lb6Kes1xf4JaxhfVxG3yHw== X-Received: by 2002:a2e:c41:: with SMTP id o1-v6mr12830581ljd.152.1545228045755; Wed, 19 Dec 2018 06:00:45 -0800 (PST) Received: from localhost (c-573670d5.07-21-73746f28.bbcust.telenor.se. [213.112.54.87]) by smtp.gmail.com with ESMTPSA id t9-v6sm3573224ljj.87.2018.12.19.06.00.44 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 19 Dec 2018 06:00:44 -0800 (PST) From: Anders Roxell To: dhowells@redhat.com, viro@zeniv.linux.org.uk Cc: linux-kernel@vger.kernel.org, Anders Roxell Subject: [PATCH] samples: Kconfig: readd BROKEN to SAMPLE_STATX Date: Wed, 19 Dec 2018 15:00:40 +0100 Message-Id: <20181219140040.8637-1-anders.roxell@linaro.org> X-Mailer: git-send-email 2.19.2 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit c1cae12e6b4a ("vfs: Add a sample program for the new mount API") introduced a build error (regression) when building an allmodconfig kernel. Before that SAMPLE_STATX had a "depends on BROKEN", and it got removed in the patch. When building an allmodconfig kernel, option SAMPLE_VFS gets enabled and produce the following build error: In file included from /usr/include/x86_64-linux-gnu/sys/stat.h:446, from ../samples/vfs/test-statx.c:28: /usr/include/x86_64-linux-gnu/bits/statx.h:25:8: error: redefinition of ‘struct statx_timestamp’ struct statx_timestamp ^~~~~~~~~~~~~~~ In file included from ../samples/vfs/test-statx.c:26: ./usr/include/linux/stat.h:56:8: note: originally defined here struct statx_timestamp { ^~~~~~~~~~~~~~~ In file included from /usr/include/x86_64-linux-gnu/sys/stat.h:446, from ../samples/vfs/test-statx.c:28: /usr/include/x86_64-linux-gnu/bits/statx.h:36:8: error: redefinition of ‘struct statx’ struct statx ^~~~~ In file included from ../samples/vfs/test-statx.c:26: ./usr/include/linux/stat.h:99:8: note: originally defined here struct statx { ^~~~~ ../samples/vfs/test-statx.c:40:9: error: conflicting types for ‘statx’ ssize_t statx(int dfd, const char *filename, unsigned flags, ^~~~~ In file included from /usr/include/x86_64-linux-gnu/sys/stat.h:446, from ../samples/vfs/test-statx.c:28: /usr/include/x86_64-linux-gnu/bits/statx.h:87:5: note: previous declaration of ‘statx’ was here int statx (int __dirfd, const char *__restrict __path, int __flags, ^~~~~ make[3]: *** [scripts/Makefile.host:90: samples/vfs/test-statx] Error 1 make[3]: Target '__build' not remade because of errors. make[2]: *** [../scripts/Makefile.build:492: samples/vfs] Error 2 make[2]: Target '__build' not remade because of errors. make[1]: *** [/srv/src/kernel/testing/Makefile:1065: samples] Error 2 Rework so that SAMPLE_STATX depends on BROKEN, and SAMPLE_VFS enables the newly added test. Signed-off-by: Anders Roxell --- samples/Kconfig | 7 +++++++ samples/vfs/Makefile | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) -- 2.19.2 diff --git a/samples/Kconfig b/samples/Kconfig index dc4eb5355fad..8253c8ce7632 100644 --- a/samples/Kconfig +++ b/samples/Kconfig @@ -147,6 +147,13 @@ config SAMPLE_VFIO_MDEV_MBOCHS Specifically it does *not* include any legacy vga stuff. Device looks a lot like "qemu -device secondary-vga". +config SAMPLE_STATX + bool "Build example extended-stat using code" + depends on BROKEN + depends on SAMPLE_VFS + help + Build example userspace program to use the new extended-stat syscall. + config SAMPLE_VFS bool "Build example programs that use new VFS system calls" help diff --git a/samples/vfs/Makefile b/samples/vfs/Makefile index 4ac9690fb3c4..fe510c6d5e52 100644 --- a/samples/vfs/Makefile +++ b/samples/vfs/Makefile @@ -1,6 +1,7 @@ # List of programs to build hostprogs-$(CONFIG_SAMPLE_VFS) := \ - test-fsmount \ + test-fsmount +hostprogs-$(CONFIG_SAMPLE_STATX) := \ test-statx # Tell kbuild to always build the programs