Changeset ab4a595 for libcfa/src


Ignore:
Timestamp:
Nov 3, 2021, 11:48:26 AM (3 years ago)
Author:
Thierry Delisle <tdelisle@…>
Branches:
ADT, ast-experimental, enum, forall-pointer-decay, master, pthread-emulation, qualifiedEnum
Children:
49599a3
Parents:
a1574e2
Message:

cpu.cfa now correctly uses "online" instead of "present" to check cpus.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/device/cpu.cfa

    ra1574e2 rab4a595  
    144144// Count number of cpus in the system
    145145static int count_cpus(void) {
    146         const char * fpath = "/sys/devices/system/cpu/present";
     146        const char * fpath = "/sys/devices/system/cpu/online";
    147147        int fd = open(fpath, 0, O_RDONLY);
    148148        /* paranoid */ verifyf(fd >= 0, "Could not open file %s", fpath);
Note: See TracChangeset for help on using the changeset viewer.