mirror of
https://github.com/opnsense/src.git
synced 2026-04-20 21:59:20 -04:00
Ignore absent CPUs when listing the current state of PMC hardware.
This commit is contained in:
parent
7dada26401
commit
5d09484b2a
1 changed files with 4 additions and 1 deletions
|
|
@ -256,9 +256,12 @@ pmcc_do_list_state(void)
|
|||
(logical_cpus_mask & (1 << cpu)))
|
||||
continue; /* skip P4-style 'logical' cpus */
|
||||
#endif
|
||||
if (pmc_pmcinfo(cpu, &pi) < 0)
|
||||
if (pmc_pmcinfo(cpu, &pi) < 0) {
|
||||
if (errno == ENXIO)
|
||||
continue;
|
||||
err(EX_OSERR, "Unable to get PMC status for CPU %d",
|
||||
cpu);
|
||||
}
|
||||
|
||||
printf("#CPU %d:\n", c++);
|
||||
npmc = pmc_npmc(cpu);
|
||||
|
|
|
|||
Loading…
Reference in a new issue