Re: speed up udev-acl.mk [was: Re: CK.OpenSession(): Do not block on run-seat.d scripts?]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Dec 21, 2009 at 16:18, Martin Pitt <martin.pitt@xxxxxxxxxx> wrote:
> It currently runs for about half a second (on a Dell Mini 10 anyway
> [1]), which is really quite a lot. udev-acl uses udev_enumerate()
> which always walks the entire /sys tree. In this case this isn't even
> conceptually necessary since all we do is a property match (finding
> ACL_MANAGE devices), and properties are stored in udev itself (rather,
> /dev/.udev/db/) instead of the sysfs tree.
>
> I just committed a slight optimization which cuts down the number of
> readlink() and stat() by a third in this case. Completely avoiding the
> /sys traversal is more difficult, but I'm still working on that.

If it's only about the ACL stuff, we could change the udev-acl logic
to maintain hidden symlinks in:
  /dev/.udev/acl/c116:32 -> ../../snd/controlC1

then the udev-acl program would just need to apply the same ACL to all
nodes found in this directory. :)

Cheers,
Kay
--
To unsubscribe from this list: send the line "unsubscribe linux-hotplug" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel]     [Linux DVB]     [Asterisk Internet PBX]     [DCCP]     [Netdev]     [X.org]     [Util Linux NG]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux