dahdi-tools/dahdi.rules
Oron Peled 791a596c07 dahdi.rules: add persistent channel names as well
Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com>
Acked-by: Russ Meyerriecks <rmeyerriecks@digium.com>
2013-11-24 16:39:33 +02:00

19 lines
738 B
Plaintext

ACTION!="add", GOTO="dahdi_add_end"
# DAHDI devices with ownership/permissions for running as non-root
SUBSYSTEM=="dahdi", OWNER="asterisk", GROUP="asterisk", MODE="0660"
# Backward compat names: /dev/dahdi/<channo>
SUBSYSTEM=="dahdi_channels", SYMLINK+="dahdi/%m"
# Add persistant names as well
SUBSYSTEM=="dahdi_channels", SYSFS{hardware_id}!="", SYMLINK+="dahdi/devices/%s{hardware_id}/%s{local_spanno}/%n"
SUBSYSTEM=="dahdi_channels", SYSFS{location}!="", SYMLINK+="dahdi/devices/@%s{location}/%s{local_spanno}/%n"
LABEL="dahdi_add_end"
# hotplug scripts
SUBSYSTEM=="dahdi_devices", RUN="%E{DAHDI_TOOLS_ROOTDIR}/usr/share/dahdi/handle_device"
SUBSYSTEM=="dahdi_spans", RUN="%E{DAHDI_TOOLS_ROOTDIR}/usr/share/dahdi/span_config"