From f05635015f9a7b4db5448789a47a4bc225137963 Mon Sep 17 00:00:00 2001 From: Alexandre Pujol Date: Mon, 15 Nov 2021 00:04:35 +0000 Subject: [PATCH] Add power-profiles-daemon. --- apparmor.d/profiles-m-r/power-profiles-daemon | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 apparmor.d/profiles-m-r/power-profiles-daemon diff --git a/apparmor.d/profiles-m-r/power-profiles-daemon b/apparmor.d/profiles-m-r/power-profiles-daemon new file mode 100644 index 00000000..0059da5f --- /dev/null +++ b/apparmor.d/profiles-m-r/power-profiles-daemon @@ -0,0 +1,32 @@ +# apparmor.d - Full set of apparmor profiles +# Copyright (C) 2021 Alexandre Pujol +# SPDX-License-Identifier: GPL-2.0-only + +abi , + +include + +@{exec_path} = /{usr/,}lib/power-profiles-daemon +profile power-profiles-daemon @{exec_path} { + include + include + + capability sys_nice, + capability dac_read_search, + + network netlink raw, + + @{exec_path} mr, + + /var/lib/power-profiles-daemon/{,**} rw, + + @{sys}/bus/ r, + @{sys}/class/ r, + @{sys}/class/power_supply/ r, + @{sys}/devices/**/power_supply/*/uevent r, + @{sys}/devices/system/cpu/*_pstate/no_turbo r, + @{sys}/devices/system/cpu/cpufreq/ r, + @{sys}/devices/system/cpu/cpufreq/policy[0-9]*/energy_performance_preference rw, + + include if exists +} \ No newline at end of file