Problem
atop crashes with the error failed to parse numa bitmap on systems with more than 512 CPUs.
Root Cause
CPUMASK_SZ is hardcoded to 64 * 8 = 512 in photosyst.c:190:
#define CPUMASK_SZ (64 * 8)
This limits the maximum number of CPU bits that can be parsed from /sys/devices/system/node/nodeX/cpumap. On systems with more than 512 CPUs, the numa_parse_bitmap_v2() function fails at the bounds check if (i >= CPU_LONGS(ncpus)) and returns -1, which triggers mcleanstop(54, "failed to parse numa bitmap\n").
Suggested Fix
Increase CPUMASK_SZ from (64 * 8) to (64 * 64) (4096 bits), which aligns with the existing MAXCPU definition in photosyst.h:
#define CPUMASK_SZ (64 * 64)
No other code changes are required — numa_allocate_cpumask(), numa_parse_bitmap_v2(), and all callers already use CPUMASK_SZ / mask->size dynamically.
Problem
atop crashes with the error failed to parse numa bitmap on systems with more than 512 CPUs.
Root Cause
CPUMASK_SZ is hardcoded to 64 * 8 = 512 in photosyst.c:190:
#define CPUMASK_SZ (64 * 8)This limits the maximum number of CPU bits that can be parsed from /sys/devices/system/node/nodeX/cpumap. On systems with more than 512 CPUs, the numa_parse_bitmap_v2() function fails at the bounds check if (i >= CPU_LONGS(ncpus)) and returns -1, which triggers mcleanstop(54, "failed to parse numa bitmap\n").
Suggested Fix
Increase CPUMASK_SZ from (64 * 8) to (64 * 64) (4096 bits), which aligns with the existing MAXCPU definition in photosyst.h:
#define CPUMASK_SZ (64 * 64)No other code changes are required — numa_allocate_cpumask(), numa_parse_bitmap_v2(), and all callers already use CPUMASK_SZ / mask->size dynamically.