Permalink
Browse files

devices/sensors - hwmon: added support for cpu_vid

  • Loading branch information...
ocerman authored and lpereira committed Nov 6, 2018
1 parent 01da9b5 commit 335687f8d11626225b7a1b6d38e75af9f2da6282
Showing with 12 additions and 0 deletions.
  1. +12 −0 modules/devices/sensors.c
@@ -235,6 +235,15 @@ static const struct HwmonSensor hwmon_sensors[] = {
1000.0,
0
},
{
"Voltage",
"%s/cpu%d_vid",
NULL,
"cpu%d_vid",
"V",
1000.0,
0
},
{ }
};
@@ -244,6 +253,9 @@ static gboolean read_raw_hwmon_value(gchar *path_hwmon, const gchar *item_path_f
gchar *full_path;
gboolean file_result;
if (item_path_format == NULL)
return FALSE;
full_path = g_strdup_printf(item_path_format, path_hwmon, item_id);
file_result = g_file_get_contents(full_path, result, NULL, NULL);

0 comments on commit 335687f

Please sign in to comment.