Files
linuxSmartie/include/cpu.h
2026-05-10 00:48:17 +02:00

31 lines
470 B
C

#ifndef CPU_H
#define CPU_H
#include <stdint.h>
enum cpu_module_t : uint8_t {
unknown,
k10temp,
zenpower
};
struct cpu_sensors_t {
enum cpu_module_t module;
uint8_t num_cores;
int16_t tdie;
int16_t tctl;
int16_t tccd1;
// double pcore;
// double psoc;
float ptotal;
// double vcore;
// double vsoc;
uint32_t avg_freq;
char hwmon[128];
};
void cpu_detect(struct cpu_sensors_t* t, const char* pci_dev);
void cpu_update(struct cpu_sensors_t *c);
#endif