Skip to content

doc: fix udev rule in calibration-helper.bash

Pekka Paalanen requested to merge pq/weston:mr/calibhelp into master

This used a cargo-culted form of the ACTION check. Kernel is allowed to invent new ACTIONs and IIRC there are already actions like bind and unbind.

Udev events before rule processing always start with a clean property list. This means that if you only match ACTION==add to add some value to the event, then that value will not be present for ACTION==bind. Udev event consumers do not accumulate values, so inconsistent value setting may confuse them.

Therefore one needs to match ACTION!=remove, not ACTION==add|change, to keep the device properties consistent for every event. It doesn't hurt to set them on remove either, but it's a habit to try to avoid processing when not strictly needed.

This issue came up in #476 (comment 841430)

Merge request reports