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: <mhng-38FFE919-5F5F-4F1E-A06E-85946E791E4B@palmerdabbelt-mac>
Date: Mon, 23 Jun 2025 16:35:01 -0700 (PDT)
From: Palmer Dabbelt <palmer@...belt.com>
To: Conor Dooley <conor.dooley@...rochip.com>
CC: klarasmodin@...il.com, Paul Walmsley <paul.walmsley@...ive.com>,
  aou@...s.berkeley.edu, Alexandre Ghiti <alex@...ti.fr>, valentina.fernandezalanis@...rochip.com,
  linux-riscv@...ts.infradead.org, linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject:     Re: [PATCH] riscv: export boot_cpu_hartid

On Thu, 19 Jun 2025 03:25:16 PDT (-0700), Conor Dooley wrote:
> On Tue, Jun 17, 2025 at 02:58:47PM +0200, Klara Modin wrote:
>> The mailbox controller driver for the Microchip Inter-processor
>> Communication can be built as a module. It uses cpuid_to_hartid_map and
>> commit 4783ce32b080 ("riscv: export __cpuid_to_hartid_map") enables that
>> to work for SMP. However, cpuid_to_hartid_map uses boot_cpu_hartid on
>> non-SMP kernels and this driver can be useful in such configurations[1].
>> 
>> Export boot_cpu_hartid so the driver can be built as a module on non-SMP
>> kernels as well.
>> 
>> Link: https://lore.kernel.org/lkml/20250617-confess-reimburse-876101e099cb@spud/ [1]
>> Cc: stable@...r.kernel.org
>> Fixes: e4b1d67e7141 ("mailbox: add Microchip IPC support")
>
> I'm not sure that this fixes tag is really right, but I have no better
> suggestions

Seems OK to me, the driver is what causes the symbol to need the 
definition, so that patch is the first place we'd need this (unless some 
other drivers want it, which wouldn't be surprising).

I'm throwing it at the tester, it should show up on fixes soon.

Thanks!

> Acked-by: Conor Dooley <conor.dooley@...rochip.com>
>
>> Signed-off-by: Klara Modin <klarasmodin@...il.com>
>> ---
>>  arch/riscv/kernel/setup.c | 1 +
>>  1 file changed, 1 insertion(+)
>> 
>> diff --git a/arch/riscv/kernel/setup.c b/arch/riscv/kernel/setup.c
>> index f7c9a1caa83e..14888e5ea19a 100644
>> --- a/arch/riscv/kernel/setup.c
>> +++ b/arch/riscv/kernel/setup.c
>> @@ -50,6 +50,7 @@ atomic_t hart_lottery __section(".sdata")
>>  #endif
>>  ;
>>  unsigned long boot_cpu_hartid;
>> +EXPORT_SYMBOL_GPL(boot_cpu_hartid);
>>  
>>  /*
>>   * Place kernel memory regions on the resource tree so that
>> -- 
>> 2.49.0
>> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ