summaryrefslogtreecommitdiff
path: root/cpufreq/src/cpufreq-monitor-factory.c
diff options
context:
space:
mode:
authorrbuj <[email protected]>2020-11-28 20:26:22 +0100
committerraveit65 <[email protected]>2020-12-09 21:16:36 +0100
commit4cb6f915b1a91497df1b13cdab887df1bdaed101 (patch)
treeef32f9e4d6f6f75de2e15da5bff69562ac7581dc /cpufreq/src/cpufreq-monitor-factory.c
parent66b18c097d5ae6e7bcf712820bc3e6594c8cb79a (diff)
downloadmate-applets-4cb6f915b1a91497df1b13cdab887df1bdaed101.tar.bz2
mate-applets-4cb6f915b1a91497df1b13cdab887df1bdaed101.tar.xz
cpufreq: Remove /proc/cpufreq support (Linux 2.4)
Diffstat (limited to 'cpufreq/src/cpufreq-monitor-factory.c')
-rw-r--r--cpufreq/src/cpufreq-monitor-factory.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/cpufreq/src/cpufreq-monitor-factory.c b/cpufreq/src/cpufreq-monitor-factory.c
index 2c6bf0b6..0c809671 100644
--- a/cpufreq/src/cpufreq-monitor-factory.c
+++ b/cpufreq/src/cpufreq-monitor-factory.c
@@ -28,13 +28,13 @@
#include "cpufreq-applet.h"
#include "cpufreq-utils.h"
-#include "cpufreq-monitor-sysfs.h"
-#include "cpufreq-monitor-procfs.h"
-#include "cpufreq-monitor-cpuinfo.h"
+#include "cpufreq-monitor-factory.h"
#ifdef HAVE_LIBCPUFREQ
#include "cpufreq-monitor-libcpufreq.h"
+#else
+#include "cpufreq-monitor-sysfs.h"
+#include "cpufreq-monitor-cpuinfo.h"
#endif
-#include "cpufreq-monitor-factory.h"
CPUFreqMonitor *
cpufreq_monitor_factory_create_monitor (guint cpu)
@@ -44,10 +44,8 @@ cpufreq_monitor_factory_create_monitor (guint cpu)
#else
CPUFreqMonitor *monitor = NULL;
- if (g_file_test ("/sys/devices/system/cpu/cpu0/cpufreq", G_FILE_TEST_EXISTS)) { /* 2.6 kernel */
+ if (g_file_test ("/sys/devices/system/cpu/cpu0/cpufreq", G_FILE_TEST_EXISTS)) {
monitor = cpufreq_monitor_sysfs_new (cpu);
- } else if (g_file_test ("/proc/cpufreq", G_FILE_TEST_EXISTS)) { /* 2.4 kernel (Deprecated)*/
- monitor = cpufreq_monitor_procfs_new (cpu);
} else if (g_file_test ("/proc/cpuinfo", G_FILE_TEST_EXISTS)) {
/* If there is no cpufreq support it shows only the cpu frequency,
* I think is better than do nothing. I have to notify it to the user, because