chiark / gitweb /
cdrom_id: add and use ID_CDROM_MEDIA to decide if we run vol_id
[elogind.git] / rules / rules.d / 60-persistent-storage.rules
index 23c21f8..4095488 100644 (file)
@@ -55,7 +55,7 @@ ENV{DEVTYPE}=="partition", ENV{ID_PATH}=="?*", SYMLINK+="disk/by-path/$env{ID_PA
 ENV{DEVTYPE}=="disk", KERNEL!="sd*|sr*", ATTR{removable}=="1", GOTO="persistent_storage_end"
 
 # probe filesystem metadata of optical drives which have a media inserted
-KERNEL=="sr*", ENV{ID_CDROM_MEDIA_TRACK_COUNT}=="?*", IMPORT{program}="vol_id --export --skip-raid --offset=$env{ID_CDROM_MEDIA_SESSION_LAST_OFFSET} $tempnode"
+KERNEL=="sr*", ENV{ID_CDROM_MEDIA}=="?*", IMPORT{program}="vol_id --export --skip-raid --offset=$env{ID_CDROM_MEDIA_SESSION_LAST_OFFSET} $tempnode"
 
 # probe filesystem metadata of disks
 KERNEL!="sr*", IMPORT{program}="vol_id --export $tempnode"