[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAFULd4bEE=HSRhRGgSVik87maNCqV4TcW5q5HHvfgOp1_NwGdw@mail.gmail.com>
Date: Wed, 27 Aug 2025 10:28:52 +0200
From: Uros Bizjak <ubizjak@...il.com>
To: Borislav Petkov <bp@...en8.de>
Cc: linux-kernel@...r.kernel.org, linux-tip-commits@...r.kernel.org,
x86@...nel.org
Subject: Re: [tip: x86/asm] x86/vdso: Fix output operand size of RDPID
On Wed, Aug 27, 2025 at 10:19 AM Borislav Petkov <bp@...en8.de> wrote:
>
> On Wed, Aug 27, 2025 at 09:53:17AM +0200, Uros Bizjak wrote:
> > The 1/2 patch is intended to be backportable
>
> Is it fixing an actual, real life bug?
No, because ".byte 0xf3,0x0f,0xc7,0xf8" encodes "RDPID %rax" on 64-bit
targets and we are only interested in the lower 32-bits anyway.
So, the change only matters on the 64-bit target when mnemonic is used
(there is no RDPID %eax" instruction), but the patch should not be
backported for the reasons outlined in my previous message. OTOH, "LSL
%eax,%eax" zero-extends to the full 64-bit register width on 64-bit
targets even when 32-bit register form is used.
Thanks,
Uros.
Powered by blists - more mailing lists