Remove Wakeups API

System Internals / UPower - Benjamin Berg [redhat.com] - 24 March 2022 16:02 UTC

The API relied on /proc/timer_stats which has been removed from the kernel in 2017. Since then, the API has been non-functional (yet incorrectly reporting support because the support test was buggy).

Just remove it completely. The debian codesearch does not uncover any API users. Also, I doubt that any new API (based on tracing scheduler events as perf would do) would map well to what exists now. i.e. if something like this is re-implemented in UPower or elsewhere, then the API should likely look different.

And, realistically, if this does need root privileges (i.e. can't be moved to use BPF programs or so on user units), then we can also create a new small daemon that is launched on-demand just for that.

9058d45 Remove Wakeups API
dbus/meson.build | 1 -
dbus/org.freedesktop.UPower.Wakeups.xml | 131 ------
doc/man/upower.xml | 1 -
doc/upower-docs.xml | 1 -
libupower-glib/meson.build | 4 -
libupower-glib/up-autocleanups.h | 2 -
libupower-glib/up-wakeup-item.c | 452 --------------------
libupower-glib/up-wakeup-item.h | 78 ----
libupower-glib/up-wakeups.c | 296 -------------
libupower-glib/up-wakeups.h | 83 ----
libupower-glib/upower.h | 2 -
src/meson.build | 2 -
src/org.freedesktop.UPower.conf.in | 4 -
src/up-main.c | 5 -
src/up-self-test.c | 14 -
src/up-wakeups.c | 726 --------------------------------
src/up-wakeups.h | 57 ---
tools/up-tool.c | 65 ---
18 files changed, 1924 deletions(-)

Upstream: cgit.freedesktop.org


  • Share