alsa-utils/alsactl/90-alsa-restore.rules.in
Dave Reisner ef0e588c76 alsa-restore.rules: refer to correct attr
$attr{number} in the RUN rule is an empty expansion. This makes sense,
because the path doesn't exist -- i.e., it refers to the path:

/sys/devices/pci0000:00/foo/bar/sound/card0/controlC0/number

Instead, refer to $attr{device/number}, which does exist.

Signed-off-by: Dave Reisner <dreisner@archlinux.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2014-01-13 11:30:43 +01:00

8 lines
329 B
Text

ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
GOTO="alsa_restore_end"
LABEL="alsa_restore_go"
TEST!="@daemonswitch@", RUN+="@sbindir@/alsactl restore $attr{device/number}"
TEST=="@daemonswitch@", RUN+="@sbindir@/alsactl nrestore $attr{device/number}"
LABEL="alsa_restore_end"