From cfa8beb620ab498081539320665e6bdd6eec610c Mon Sep 17 00:00:00 2001 From: Sooyoung Ha Date: Thu, 6 Jul 2017 11:54:55 +0900 Subject: [PATCH] service: modify emul-setup-audio-volume service This service file uses amixer and amixer uses /dev/snd device. The /dev/snd device has 'audio' gid. If this service file gains audio group permission, it will be able to excute amixer binary. systemd-udevd.service modifies the gid of /dev/snd to audio, so 'After' contents also modified. Change-Id: Ie639d0115b843568af3f97da6944f38d0f4d7cf4 Signed-off-by: Sooyoung Ha --- .../usr/lib/systemd/system/emul-setup-audio-volume.service | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/filesystem/usr/lib/systemd/system/emul-setup-audio-volume.service b/filesystem/usr/lib/systemd/system/emul-setup-audio-volume.service index 31ec4a6..ff633b0 100644 --- a/filesystem/usr/lib/systemd/system/emul-setup-audio-volume.service +++ b/filesystem/usr/lib/systemd/system/emul-setup-audio-volume.service @@ -1,14 +1,15 @@ [Unit] Description=Audio volume setup on emulator DefaultDependencies=no +After=systemd-udevd.service [Service] User=service_fw Group=service_fw -Capabilities=cap_dac_override=i SecureBits=keep-caps Type=oneshot SmackProcessLabel=System +SupplementaryGroups=audio ExecStart=/usr/bin/amixer "cset" "name='Master Playback Switch'" "1" ExecStart=/usr/bin/amixer "cset" "name='Master Playback Volume'" "50" ExecStart=/usr/bin/amixer "cset" "name='PCM Playback Switch'" "1" -- 2.34.1