Skip to content

Commit 3e1e083

Browse files
udev: use ENV{ID_DEBUG_APPLIANCE} instead of GROUP and direct uaccess
GROUP can't be used for * It's not concrete. All users in plugdev groups can use all devices in plugdev group, whatever it's phone, camera, microphone or debugprobe. * It's not flexible. The user list need be maintained manually. And if update, user need to re-login to take effect. * It doesn't work on modern Linux distros. On modern Linux world, only Debian and its derived distros have plugdev group by default. Arch, Fedora and Gentoo have no plugdev group by default at all. And systemd have a behavior: if the group declared in GROUP="" doesn't exist or isn't system group, it will ignore the whole udev rule line (not only the chown operation). So our rule won't work on most modern Linux. Direct uaccess rule shouldn't be used because according to the post of systemd developer[1], the generic device class should be used instead. Since systemd has ID_DEBUG_APPLIANCE generic device class, we use it directly. The hint of probe-rs main program also need to be updated, to fix the issue mentioned in [2]. [1]: https://lists.freedesktop.org/archives/systemd-devel/2012-March/004792.html [2]: probe-rs/probe-rs#3577 Signed-off-by: Celeste Liu <[email protected]>
1 parent a684d3f commit 3e1e083

File tree

1 file changed

+109
-109
lines changed

1 file changed

+109
-109
lines changed

0 commit comments

Comments
 (0)