summaryrefslogtreecommitdiffstats
path: root/rules.d/60-persistent-media-controller.rules
blob: 8c2175c5bacd2758fabdc62661ba2167a344f54a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
# do not edit this file, it will be overwritten on update

# Media controller rules

ACTION=="remove", GOTO="persistent_media_ctl_end"
SUBSYSTEM!="media", GOTO="persistent_media_ctl_end"
ENV{MAJOR}=="", GOTO="persistent_media_ctl_end"

IMPORT{builtin}="path_id"
KERNEL=="media*", ENV{ID_PATH_WITH_USB_REVISION}=="?*", SYMLINK+="media/by-path/$env{ID_PATH_WITH_USB_REVISION}-media-controller"
KERNEL=="media*", ENV{ID_PATH_WITH_USB_REVISION}=="", ENV{ID_PATH}=="?*", SYMLINK+="media/by-path/$env{ID_PATH}-media-controller"

LABEL="persistent_media_ctl_end"