Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #93109

Bug#1140651: linux: CONFIG_NR_CPUS=64 too small for 80-core RISC-V hardware

From Aurelien Jarno <aurel32@debian.org>
Newsgroups linux.debian.bugs.dist, linux.debian.kernel
Subject Bug#1140651: linux: CONFIG_NR_CPUS=64 too small for 80-core RISC-V hardware
Date 2026-06-24 19:40 +0200
Message-ID <N9zJT-yrt-3@gated-at.bofh.it> (permalink)
References <N9oYa-rgz-11@gated-at.bofh.it> <N9oYa-rgz-11@gated-at.bofh.it>
Organization linux.* mail to news gateway

Cross-posted to 2 groups.

Show all headers | View raw


Hi,

On 2026-06-24 14:07, Lufei Zheng wrote:
> Package: linux
> Version: 6.12.86-1
> Severity: important
> 
> Dear Maintainer,
> 
> The riscv64 kernel is built with CONFIG_NR_CPUS=64. On hardware with more than 64 harts, the excess CPUs are silently lost at boot.
> 
> Hardware:
> 
>   Board:   SpacemiT V100 (C2201MB1)
>   Vendor:  SpacemiT (mvendorid=0x710)
>   marchid: 0x8000000058000002
>   mimpid:  0x4c4d900
>   Arch:    riscv64, MMU sv48
>   ISA:     rv64imafdcvh_zicbom_zicboz_zicntr_zicond_zicsr_zifencei
>              _zihintntl_zihintpause_zihpm_zimop_zawrs_zfa_zfh_zfhmin
>              _zca_zcb_zcd_zcmop_zba_zbb_zbc_zbs_zkt_zvbb_zvbc_zve32f
>              _zve32x_zve64d_zve64f_zve64x_zvfh_zvfhmin_zvkb_zvkg
>              _zvkned_zvknhb_zvksed_zvksh_zvkt_smaia_smstateen_ssaia
>              _sscofpmf_sstc_svinval_svnapot_svpbmt
>   Physical harts: 80 (hart IDs 0-39, 64-87)
>
> Observed behaviour:
> 
>     $ nproc --all
>     64
> 
>     $ cat /sys/devices/system/cpu/possible
>     0-63
> 
>   16 harts are silently dropped at boot. The kernel only sees 64 CPUs.
> 
>   Boot messages:
> 
>     [    0.000000] NR_CPUS is too small for the number of ACPI tables.
> 
>   This message is repeated 16 times.
> 
>   Kernel config:
> 
>     CONFIG_SMP=y
>     CONFIG_NR_CPUS=64
> 
>   Expected behaviour:
> 
>   All 80 harts should be usable. CONFIG_NR_CPUS should be raised to at least 256 for riscv64, matching the arm64 default.
> 
> Suggested fix:
> 
> In debian/config/riscv64/config, change:
> 
>     CONFIG_NR_CPUS=64
> 
>   to:
> 
>     CONFIG_NR_CPUS=256

No, this can't be changed as you say, because the value is not defined 
here, instead the upstream default is used. Sure we can override it in 
that file, but it would be way better if we can keep using the upstream 
default.

A MR has been submitted to change the value in the Debian kernel [1] (to 
128  instead of 256), but before doing that the default value change 
should be submitted
upstream.

Regards
Aurelien

[1] https://salsa.debian.org/kernel-team/linux/-/merge_requests/1995

-- 
Aurelien Jarno                          GPG: 4096R/1DDD8C9B
aurelien@aurel32.net                     http://aurel32.net

Back to linux.debian.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Bug#1140651: linux: CONFIG_NR_CPUS=64 too small for 80-core RISC-V hardware "Lufei Zheng" <lufei.zheng@spacemit.com> - 2026-06-24 08:10 +0200
  Bug#1140651: linux: CONFIG_NR_CPUS=64 too small for 80-core RISC-V hardware Aurelien Jarno <aurel32@debian.org> - 2026-06-24 19:40 +0200
  Bug#1140651: marked as done (linux: CONFIG_NR_CPUS=64 too small  for 80-core RISC-V hardware) "Debian Bug Tracking System" <owner@bugs.debian.org> - 2026-06-27 16:40 +0200
  Bug#1140651: marked as done (linux: CONFIG_NR_CPUS=64 too small  for 80-core RISC-V hardware) "Debian Bug Tracking System" <owner@bugs.debian.org> - 2026-07-02 22:30 +0200
  Bug#1140651: marked as done (linux: CONFIG_NR_CPUS=64 too small  for 80-core RISC-V hardware) "Debian Bug Tracking System" <owner@bugs.debian.org> - 2026-07-22 20:50 +0200

csiph-web