I had also discovered a problem with the 18.104.22.168 kernel. I had udev rules so that 'udevd' would signal pup_event_frontend_d whenever a block device is added or removed. However, as the 22.214.171.124 kernel uevents do not set the DEVTYPE variable, I cannot specify that in the rules, which resulted in multiple signals being sent to pup_event_frontend_d, which confuses the script.
On top of that, pup_event_frontend_d has a complex structure. It has to wait on block events from udevd, but it also has to have its own four-second loop as some devices (ex., CD/DVD media) need to be polled periodically. For sometime now I have realised that it would be better to abandon some of the sophistication and just have a simple polling loop. That is, uedevd no longer has rules to signal pup_event_frontend_d. The script is just in a simple two-second loop monitoring /sys/block for changes, and also performing four-second probes.
This has greatly simplified the script, and it now handles multiple simultaneous hotplug events. I think that I may have fixed other potential anomalies also.
So, score a point for the old-fashioned way of doing things. Primitive and simple. I don't think that it uses much more system resources either.
No comments posted yet.