[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20260121105928.21c5e2de@pumpkin>
Date: Wed, 21 Jan 2026 10:59:28 +0000
From: David Laight <david.laight.linux@...il.com>
To: Borislav Petkov <bp@...en8.de>
Cc: "H. Peter Anvin" <hpa@...or.com>, David Desobry
<david.desobry@...malgen.com>, tglx@...nel.org, mingo@...hat.com,
dave.hansen@...ux.intel.com, x86@...nel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] x86/lib: Fix num_digits() signed overflow for INT_MIN
On Tue, 20 Jan 2026 21:13:46 +0100
Borislav Petkov <bp@...en8.de> wrote:
> On Tue, Jan 20, 2026 at 11:50:41AM -0800, H. Peter Anvin wrote:
> > For negative numbers? Dave Hansen pointed out that we currently don't ever
> > pass negative numbers, in which case it would make more sense to have the
> > function simply take an unsigned int.
>
> Yes, that's why I'm asking what we're even fixing here...
You can certainly just document it doesn't work for INT_MIN.
David
Powered by blists - more mailing lists