HomeFreeBSD

smp_topo(): make it idempotent

Description

smp_topo(): make it idempotent

If more than one call to the function occurs, it currently allocates the
same amount from the group[] array, eventually leading to the memory
corruption.

Noted and reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D39981

Details

Provenance
kibAuthored on May 7 2023, 6:37 PM
Differential Revision
D39981: Eliminate MAXCPU from subr_smp.c
Parents
rG9801e7c275f6: smp_topo: dynamically allocate group array
Branches
Unknown
Tags
Unknown