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] [day] [month] [year] [list]
Date: Wed, 26 Jun 2024 07:43:19 -0700 (PDT)
From: Palmer Dabbelt <palmer@...belt.com>
To: Evan Green <evan@...osinc.com>
CC: cyy@...self.name, linux-riscv@...ts.infradead.org, enh@...gle.com,
  Charlie Jenkins <charlie@...osinc.com>, corbet@....net, Paul Walmsley <paul.walmsley@...ive.com>, cleger@...osinc.com,
  Conor Dooley <conor.dooley@...rochip.com>, ajones@...tanamicro.com, linux-kernel@...r.kernel.org,
  linux-doc@...r.kernel.org
Subject:     Re: [PATCH v2 3/3] RISC-V: hwprobe: not treat KEY_CPUPERF_0 as bitmask

On Wed, 29 May 2024 11:33:42 PDT (-0700), Evan Green wrote:
> On Thu, May 23, 2024 at 8:36 PM Yangyu Chen <cyy@...self.name> wrote:
>>
>> Since the value in KEY_CPUPERF_0 is not bitmask, remove the wrong code
>> in hwprobe.h.
>>
>> Signed-off-by: Yangyu Chen <cyy@...self.name>
>
> I'd expect a Fixes tag, and ideally some discussion on the reasoning
> and ramifications of this change.
>
> I posted the other possible fix, declaring a new key, at [1], mostly
> so we could see the two options and discuss. I'm okay with either
> patch.

Just to close the loop here as the discussions are on other threads: 
after a bunch of discussions we're going with the new key version.  
Maybe it's a bit pedantic, but since hwprobe is such a fundamental 
compatibility interface we're just going to be super careful.

> -Evan
>
> [1] https://lore.kernel.org/lkml/20240529182649.2635123-1-evan@rivosinc.com/T/#u
>
>> ---
>>  arch/riscv/include/asm/hwprobe.h | 1 -
>>  1 file changed, 1 deletion(-)
>>
>> diff --git a/arch/riscv/include/asm/hwprobe.h b/arch/riscv/include/asm/hwprobe.h
>> index 630507dff5ea..f24cad22bbe1 100644
>> --- a/arch/riscv/include/asm/hwprobe.h
>> +++ b/arch/riscv/include/asm/hwprobe.h
>> @@ -20,7 +20,6 @@ static inline bool hwprobe_key_is_bitmask(__s64 key)
>>         switch (key) {
>>         case RISCV_HWPROBE_KEY_BASE_BEHAVIOR:
>>         case RISCV_HWPROBE_KEY_IMA_EXT_0:
>> -       case RISCV_HWPROBE_KEY_CPUPERF_0:
>>                 return true;
>>         }
>>
>> --
>> 2.45.1
>>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ