lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250720065045.2859105-7-hpa@zytor.com>
Date: Sat, 19 Jul 2025 23:50:43 -0700
From: "H. Peter Anvin" <hpa@...or.com>
To: 
Cc: "H. Peter Anvin" <hpa@...or.com>,
        Eugenio Pérez <eperezma@...hat.com>,
        Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>,
        "Michael S. Tsirkin" <mst@...hat.com>,
        Al Viro <viro@...iv.linux.org.uk>, Alexei Starovoitov <ast@...nel.org>,
        Alexey Dobriyan <adobriyan@...il.com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Andrii Nakryiko <andrii@...nel.org>, Arnd Bergmann <arnd@...nel.org>,
        Borislav Petkov <bp@...en8.de>,
        Dan Williams <dan.j.williams@...el.com>,
        Daniel Borkmann <daniel@...earbox.net>,
        Dave Hansen <dave.hansen@...ux.intel.com>,
        David Laight <David.Laight@...LAB.COM>,
        David Lechner <dlechner@...libre.com>,
        Dinh Nguyen <dinguyen@...nel.org>,
        Eduard Zingerman <eddyz87@...il.com>,
        Gatlin Newhouse <gatlin.newhouse@...il.com>,
        Hao Luo <haoluo@...gle.com>, Ingo Molnar <mingo@...hat.com>,
        Linus Torvalds <torvalds@...ux-foundation.org>,
        Jakub Sitnicki <jakub@...udflare.com>,
        Jan Hendrik Farr <kernel@...rr.cc>, Jason Wang <jasowang@...hat.com>,
        Jiri Olsa <jolsa@...nel.org>,
        John Fastabend <john.fastabend@...il.com>,
        Jonathan Cameron <Jonathan.Cameron@...wei.com>,
        Josh Poimboeuf <jpoimboe@...nel.org>, KP Singh <kpsingh@...nel.org>,
        Kees Cook <kees@...nel.org>,
        Luc Van Oostenryck <luc.vanoostenryck@...il.com>,
        Marc Herbert <Marc.Herbert@...ux.intel.com>,
        Martin KaFai Lau <martin.lau@...ux.dev>,
        Mateusz Guzik <mjguzik@...il.com>, Michal Luczaj <mhal@...x.co>,
        Miguel Ojeda <ojeda@...nel.org>, Mykola Lysenko <mykolal@...com>,
        NeilBrown <neil@...wn.name>, Peter Zijlstra <peterz@...radead.org>,
        Przemek Kitszel <przemyslaw.kitszel@...el.com>,
        Sami Tolvanen <samitolvanen@...gle.com>, Shuah Khan <shuah@...nel.org>,
        Song Liu <song@...nel.org>, Stanislav Fomichev <sdf@...ichev.me>,
        Thomas Gleixner <tglx@...utronix.de>,
        Thorsten Blum <thorsten.blum@...ux.dev>,
        Uros Bizjak <ubizjak@...il.com>,
        Xuan Zhuo <xuanzhuo@...ux.alibaba.com>,
        Yafang Shao <laoar.shao@...il.com>, Ye Bin <yebin10@...wei.com>,
        Yonghong Song <yonghong.song@...ux.dev>,
        Yufeng Wang <wangyufeng@...inos.cn>, bpf@...r.kernel.org,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-kselftest@...r.kernel.org, linux-sparse@...r.kernel.org,
        virtualization@...ts.linux.dev, x86@...nel.org
Subject: [PATCH v2 6/7] selftests/bpf: replace "__auto_type" with "auto"

Replace instances of "__auto_type" with "auto" in:

	tools/testing/selftests/bpf/prog_tests/socket_helpers.h

This file does not seem to be including <linux/compiler_types.h>
directly or indirectly, so copy the definition but guard it with
!defined(auto).

Signed-off-by: H. Peter Anvin (Intel) <hpa@...or.com>
---
 tools/testing/selftests/bpf/prog_tests/socket_helpers.h | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/tools/testing/selftests/bpf/prog_tests/socket_helpers.h b/tools/testing/selftests/bpf/prog_tests/socket_helpers.h
index e02cabcc814e..0d59503a0c73 100644
--- a/tools/testing/selftests/bpf/prog_tests/socket_helpers.h
+++ b/tools/testing/selftests/bpf/prog_tests/socket_helpers.h
@@ -17,11 +17,16 @@
 #define VMADDR_CID_LOCAL 1
 #endif
 
+/* include/linux/compiler_types.h */
+#if __STDC_VERSION__ < 202311L && !defined(auto)
+# define auto __auto_type
+#endif
+
 /* include/linux/cleanup.h */
 #define __get_and_null(p, nullvalue)                                           \
 	({                                                                     \
-		__auto_type __ptr = &(p);                                      \
-		__auto_type __val = *__ptr;                                    \
+		auto __ptr = &(p);					       \
+		auto __val = *__ptr;                                           \
 		*__ptr = nullvalue;                                            \
 		__val;                                                         \
 	})
-- 
2.50.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ