From b821257f271ae6bea1bf828c514772256f5f57b6 Mon Sep 17 00:00:00 2001 From: ivan-boikov Date: Thu, 29 Feb 2024 20:49:23 +0100 Subject: Revert CPU count define --- components/cpu.c | 4 ---- configure | 3 --- 2 files changed, 7 deletions(-) diff --git a/components/cpu.c b/components/cpu.c index bbebdfc..a78f17a 100644 --- a/components/cpu.c +++ b/components/cpu.c @@ -14,11 +14,7 @@ unsigned int cores = 0; uintmax_t freq, freq_sum = 0; -#ifdef N_CORES - for (cores = 0; cores < N_CORES;) { -#else while (1) { -#endif sprintf(cpu, "/sys/devices/system/cpu/cpu%d/cpufreq/scaling_cur_freq", cores); if (pscanf(cpu, "%ju", &freq) != 1) break; diff --git a/configure b/configure index f133f15..4664f2b 100755 --- a/configure +++ b/configure @@ -1,9 +1,6 @@ #!/bin/sh git checkout config.h -git checkout components/cpu.c - -sed -i "2i #define N_CORES $(nproc --all)" components/cpu.c for BAT in /sys/class/power_supply/BAT* do -- cgit v1.2.3