diff options
Diffstat (limited to 'alsactl/90-alsa-restore.rules.in')
-rw-r--r-- | alsactl/90-alsa-restore.rules.in | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/alsactl/90-alsa-restore.rules.in b/alsactl/90-alsa-restore.rules.in index fe0e1ed..3ce9a65 100644 --- a/alsactl/90-alsa-restore.rules.in +++ b/alsactl/90-alsa-restore.rules.in @@ -1,2 +1,8 @@ -ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS=="card*", \ - RUN+="@sbindir@/alsactl nrestore $attr{number}" +ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go" +GOTO="alsa_restore_end" + +LABEL="alsa_restore_go" +TEST!="/etc/alsa/state-daemon.conf", RUN+="@sbindir@/alsactl restore $attr{number}" +TEST=="/etc/alsa/state-daemon.conf", RUN+="@sbindir@/alsactl nrestore $attr{number}" + +LABEL="alsa_restore_end" |