governor: add daemon API and helpers to set CPU governor

This commit is contained in:
Christian Hergert
2019-06-14 08:03:37 -07:00
parent c46ac1374b
commit fc745767d4
4 changed files with 199 additions and 0 deletions

View File

@ -99,5 +99,14 @@ gboolean sysprof_helpers_perf_event_open (SysprofHelpers
gint *out_fd,
GError **error);
#endif
void sysprof_helpers_set_governor_async (SysprofHelpers *self,
const gchar *governor,
GCancellable *cancellable,
GAsyncReadyCallback callback,
gpointer user_data);
gboolean sysprof_helpers_set_governor_finish (SysprofHelpers *self,
GAsyncResult *result,
gchar **old_governor,
GError **error);
G_END_DECLS