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: <72a2744a-debc-4d8f-b418-5d6a595c2578@app.fastmail.com>
Date: Mon, 19 Jan 2026 13:45:04 +0100
From: "Arnd Bergmann" <arnd@...db.de>
To: Thomas Weißschuh <thomas.weissschuh@...utronix.de>,
 "David Laight" <david.laight.linux@...il.com>
Cc: "David S . Miller" <davem@...emloft.net>,
 "Andreas Larsson" <andreas@...sler.com>, "Andy Lutomirski" <luto@...nel.org>,
 "Thomas Gleixner" <tglx@...nel.org>, "Ingo Molnar" <mingo@...hat.com>,
 "Borislav Petkov" <bp@...en8.de>,
 "Dave Hansen" <dave.hansen@...ux.intel.com>, x86@...nel.org,
 "H. Peter Anvin" <hpa@...or.com>, "Heiko Carstens" <hca@...ux.ibm.com>,
 "Vasily Gorbik" <gor@...ux.ibm.com>,
 "Alexander Gordeev" <agordeev@...ux.ibm.com>,
 "Christian Borntraeger" <borntraeger@...ux.ibm.com>,
 "Sven Schnelle" <svens@...ux.ibm.com>, sparclinux@...r.kernel.org,
 linux-kernel@...r.kernel.org, Linux-Arch <linux-arch@...r.kernel.org>,
 linux-s390@...r.kernel.org
Subject: Re: [PATCH 4/4] asm-generic/bitsperlong.h: Add sanity checks for
 __BITS_PER_LONG

On Mon, Jan 19, 2026, at 11:56, Thomas Weißschuh wrote:
> On Mon, Jan 19, 2026 at 10:37:58AM +0000, David Laight wrote:
>> 
>> Don't you need a check that it isn't wrong on a user system?
>> Which is what I thought it was doing.
>
> Not really. The overrides defined by arch/*/include/uapi/asm/bitsperlong.h are
> being tested here. If they work in the kernel build I assume they also work
> in userspace.

I think You could just move check into include/asm-generic/bitsperlong.h
to make this more obvious with the #ifdef __KERNEL__, and remove the
disabled check from my original version there.

      Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ