Message ID | ZbJv9fGF_k2xXEdr@kernel.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-38722-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:6359:bb0:b0:176:abc2:f11e with SMTP id gf48csp270297rwb; Thu, 25 Jan 2024 06:28:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IFvuyziSeo2OewbEKFjvcyp51kBGZQyjn1kdh2ucD1MLB6TG3BUcxLZZWeiTxCGSmjhAJY/ X-Received: by 2002:a05:6214:e65:b0:686:9de1:7015 with SMTP id jz5-20020a0562140e6500b006869de17015mr1288343qvb.61.1706192903512; Thu, 25 Jan 2024 06:28:23 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706192903; cv=pass; d=google.com; s=arc-20160816; b=sDXuX48Uw5MlNUA8lwgiGVLvcNG0YlisA/w3GS9/lOYsn1KaO+Q7oWCFVwYXw2KfON +AKUSUeLJcCzczG9kfMAqc9NvaFAJfr4ARGPuN5J7tnYmMgiGKslPEI6mkqcdBqr9I88 e05xhdYsQCObz+P0i803tFwSEV+srHwQvvv+S7wFN6tI7+nRZHeW74fhfyufnPiB3flS rlla4YF2m+JAxQgy63Ih7m9fAijnszQlsE740jA56zUevVvO235UFm/mbThfELTuYEIl 2B3xHfdKJ52SeSC32lkF44zk3WIBNdRVv/1Hdx+MkkCFs/K75sDhImlgUJc61PDy7Ogr Sq9w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-disposition:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:message-id:subject:cc:to:from:date :dkim-signature; bh=9J0/wHtYHzSMjJ/hbsIti8KsCBgzFb/0fH/eWGyGcxU=; fh=7LskONGI4eFuWnsdQelUEhELTr1iqGUcU4e7h5agU+s=; b=mcn105Jo4z3AP0U/r4jVQqFE8uc3ddeWNHfFk11FK+p6vRe4g0e4iqIhdheRDEH13v 6LvR8JT1f+tCmnvAYl9i7dAiYSaS6r3YV7eLy7A69lqhrmyEZT6M6ZReLZAnB7Fx4pSO X4OZdIApd4BNWgFFh+J9GNynrQXR+9b8LKPLH7tTTdWoDhy6o5ZQSb9mEaAx4oU0tkA4 GNbiiJDOZnZxl0+fwL9friU6m+h7lflMzo3AtMcKPPFafHhS9+DJzARqANWqcMivw30X 5DqOinZuNRMdaDTCDbhlmopf1l1kt469mq8AV8+h2BOZW2ArHOMD5tQYZB8zXHKTZUFG SEGA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="LXrrbR/J"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-38722-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-38722-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id h10-20020a05620a13ea00b007811aafa5dasi12592818qkl.45.2024.01.25.06.28.23 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Jan 2024 06:28:23 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-38722-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="LXrrbR/J"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-38722-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-38722-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 3C7B91C2291A for <ouuuleilei@gmail.com>; Thu, 25 Jan 2024 14:28:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 68336634F7; Thu, 25 Jan 2024 14:28:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="LXrrbR/J" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id CDBC563414 for <linux-kernel@vger.kernel.org>; Thu, 25 Jan 2024 14:28:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706192888; cv=none; b=iul+GMNzhF7uI6uQFV6lZn0p/F0b5LvfBkRixoAQvcZj9JnNu4yuNIo44obswTR/rI8n4eojyagy4ikQLpXEyU38/LoJzfUfR0HXl1h379sRqIpOBBezg7FKS5ySdma0IW3h1TLt9zgBeNB6chcsJrCWko/NTKAS+GdWI9/YNYs= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706192888; c=relaxed/simple; bh=iPJKR2ahlCuH15QtcPi5dZ2G0gzOR5bBrxcXevu9pFw=; h=Date:From:To:Cc:Subject:Message-ID:MIME-Version:Content-Type: Content-Disposition; b=Z1t2TBUDGX2QrCK3J3UTO94vj3GMS6wKO49a29lP3aMC1vdKle9csw8wddzvE5SL27iAgYN5QLvrtccHxmotm9phX1a3uOi5/OsISfDY94UVDY+bhkGzb3X3lBi1AG8Bz9fQVGo+kRy1incQyox6WkRNP579hqv/I3Qio4sVK/4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=LXrrbR/J; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0C4D6C433F1; Thu, 25 Jan 2024 14:28:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706192888; bh=iPJKR2ahlCuH15QtcPi5dZ2G0gzOR5bBrxcXevu9pFw=; h=Date:From:To:Cc:Subject:From; b=LXrrbR/JiOy+fzpX/QXPjTYXceRBsokqK+Ul+9fiYWtMjEdZVDtn3kkzIS6/X0Dtm sVGJP1e4I4qXd1ZDn8OVypiORL6M6oIGqvZMuemkdI91puh/XM9L/LQyKJYwwrQsdR tOcbQ5TUU3eneIBXdG621t5kRL1/EQApS0SSJLVkQBjrqGc9dGlEBDUggR3w4JFD/1 cOZR/Iri1oapEhYXbxFYlQ0zFOjTGef24GjQSSG7QfhUVE29CyFmb2TC+dAKKmvhOI u3fkChoN1rAwrOUF6D5uAemZM1Is+AkhmBEYHwT2p0H19Kw8s7gRkjp9f+JTtBYRkI 9w3O7mYxkoKDA== Received: by quaco.ghostprotocols.net (Postfix, from userid 1000) id 41A15405B2; Thu, 25 Jan 2024 11:28:05 -0300 (-03) Date: Thu, 25 Jan 2024 11:28:05 -0300 From: Arnaldo Carvalho de Melo <acme@kernel.org> To: linux-kernel@vger.kernel.org Cc: Stefan Berger <stefanb@linux.ibm.com>, Christian Brauner <brauner@kernel.org>, Adrian Hunter <adrian.hunter@intel.com>, Ian Rogers <irogers@google.com>, Jiri Olsa <jolsa@kernel.org>, Namhyung Kim <namhyung@kernel.org> Subject: [PATCH 1/1 FYI] tools headers UAPI: Sync linux/fcntl.h with the kernel sources Message-ID: <ZbJv9fGF_k2xXEdr@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1789072929905230695 X-GMAIL-MSGID: 1789072929905230695 |
Series |
[1/1,FYI] tools headers UAPI: Sync linux/fcntl.h with the kernel sources
|
|
Commit Message
Arnaldo Carvalho de Melo
Jan. 25, 2024, 2:28 p.m. UTC
tldr; Just FYI, I'm carrying this on the perf tools tree.
- Arnaldo
Full explanation:
There used to be no copies, with tools/ code using kernel headers
directly. From time to time tools/perf/ broke due to legitimate kernel
hacking. At some point Linus complained about such direct usage. Then we
adopted the current model.
The way these headers are used in perf are not restricted to just
including them to compile something.
There are sometimes used in scripts that convert defines into string
tables, etc, so some change may break one of these scripts, or new MSRs
may use some different #define pattern, etc.
E.g.:
$ ls -1 tools/perf/trace/beauty/*.sh | head -5
tools/perf/trace/beauty/arch_errno_names.sh
tools/perf/trace/beauty/drm_ioctl.sh
tools/perf/trace/beauty/fadvise.sh
tools/perf/trace/beauty/fsconfig.sh
tools/perf/trace/beauty/fsmount.sh
$
$ tools/perf/trace/beauty/fadvise.sh
static const char *fadvise_advices[] = {
[0] = "NORMAL",
[1] = "RANDOM",
[2] = "SEQUENTIAL",
[3] = "WILLNEED",
[4] = "DONTNEED",
[5] = "NOREUSE",
};
$
The tools/perf/check-headers.sh script, part of the tools/ build
process, points out changes in the original files.
So its important not to touch the copies in tools/ when doing changes in
the original kernel headers, that will be done later, when
check-headers.sh inform about the change to the perf tools hackers.
---
To get the changes in:
8a924db2d7b5eb69 ("fs: Pass AT_GETATTR_NOSEC flag to getattr interface function")
That don't add anything that is handled by existing hard coded tables or
table generation scripts.
This silences this perf build warning:
Warning: Kernel ABI header differences:
diff -u tools/include/uapi/linux/fcntl.h include/uapi/linux/fcntl.h
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Christian Brauner <brauner@kernel.org>
Cc: Ian Rogers <irogers@google.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Stefan Berger <stefanb@linux.ibm.com>
Link: https://lore.kernel.org/lkml/
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
---
tools/include/uapi/linux/fcntl.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/tools/include/uapi/linux/fcntl.h b/tools/include/uapi/linux/fcntl.h index 6c80f96049bd07d1..282e90aeb163c028 100644 --- a/tools/include/uapi/linux/fcntl.h +++ b/tools/include/uapi/linux/fcntl.h @@ -116,5 +116,8 @@ #define AT_HANDLE_FID AT_REMOVEDIR /* file handle is needed to compare object identity and may not be usable to open_by_handle_at(2) */ +#if defined(__KERNEL__) +#define AT_GETATTR_NOSEC 0x80000000 +#endif #endif /* _UAPI_LINUX_FCNTL_H */