Bryan Kadzban wrote:
Alexander E. Patrakov wrote:
Mark Rosenstand wrote: ("---" = upstream, "+++" = LFS)

# sysfs is populated after the event is sent
-ACTION=="add", DEVPATH=="/devices/*", ENV{PHYSDEVBUS}=="?*",
WAIT_FOR_SYSFS="bus" +ACTION=="add", DEVPATH=="/devices/*", SUBSYSTEMS=="?*", WAIT_FOR_SYSFS="bus"

Upstream updated their rule.

Er, actually, I updated our rule to use SUBSYSTEMS instead of
ENV{PHYSDEVBUS} after re-reading the -098 RELEASE-NOTES.  ;-)
Well, that's what happens when I attempt to answer questions without the whole udev thing at hands :) Please ignore the rest of my original mail then.
-KERNEL=="hd*[0-9]", ATTRS{removable}=="1",
GOTO="persistent_storage_end"
+KERNEL=="hd*[0-9]", ATTRS{../removable}=="1",
GOTO="persistent_storage_end"

Looks like a conversion error on LFS end: the "removable" attribute applies to the whole disk (or maybe even to the CF card which appears
as a controller), but not partitions. However, the LFS form should
also work.

OK, I was wondering about that one.  Before the conversion to -098
syntax, it was SYSFS{../removable} (presumably because it's looking at a
partition, and ../ is the disk).  I wasn't sure if the disk was actually
on the "ancestor" chain of the partition, so I left it as-is instead of
converting to ATTRS{removable}.

It should probably be changed to the upstream version though.
Test and report.
-KERNEL=="sd*[!0-9]|sr*|st*", ATTRS{ieee1394_id}=="*", ENV{ID_SERIAL}="$attr{ieee1394_id}", ENV{ID_BUS}="ieee1394" +KERNEL=="sd*[!0-9]|sr*|st*", ATTRS{ieee1394_id}=="?*", ENV{ID_SERIAL}="$attr{ieee1394_id}", ENV{ID_BUS}="ieee1394"

Same. "*" matches any value, "?*" matches any non-empty value.

Not having any Firewire devices, I was guessing here.  Do you know if
ATTRS{ieee1394_id}=="*" matches if the ieee1394_id attribute is missing
entirely?
It doesn't.
  If so, we probably don't want to use it.  If not, and if the
attribute is sometimes empty, then we should probably get rid of the
question mark and match upstream.
I don't have any IEEE1394 device either.
-KERNEL=="*[!0-9]", ATTR{removable}=="1",
GOTO="persistent_storage_end"
+KERNEL=="*[!0-9]", ATTRS{removable}=="1",
GOTO="persistent_storage_end"

This rule matches whole-disk devices, although there is indeed some inconsistency in ATTR vs ATTRS upstream.

It was SYSFS before, so I made it ATTRS to match.  Sounds like that
doesn't work right?  Although I'm not sure whether there's value in
persistent storage symlinks for whole-disk devices, we can obviously
change it to match upstream.
There is no value in persistent storage symlinks for removable devices with buggy drivers. Anyway, Kay already gave his opinion on linux-hotplug-devel: "KERNEL=="hd*[!0-9]", ATTRS{removable}=="1" could be ATTR I think, cause it will not run for a partition anyway cause of the KERNEL match."
As far as 95-udev-late goes:  That's just for udevmonitor, correct?  I
think we should probably still have it, just wondering what uses it.
udevmonitor is a debugging tool shipped with udev.

--
Alexander E. Patrakov
--
http://linuxfromscratch.org/mailman/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to