IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
This crops up in my threaded udevd profiles from time to time.
It's not consistent - probably due to variations in the number
of concurrent events - but it can hit 4% user time and higher.
The change halves the user time spent in compare_devpath().
Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
Unfortunately the linux rmdir implementation unhashes the dentry
even when the directory is not removed. This is apparently by
design (for filesystems that don't allow deleting open files).
Results from time(1) and oprofile follow.
Before:
0.35user 0.90system
samples % image name symbol name
608 9.6738 vmlinux shrink_dcache_parent
293 4.6619 vmlinux copy_page_c
271 4.3119 vmlinux copy_page_range
257 4.0891 udevd udev_rules_iter_next
After:
0.31user 0.67system
samples % image name symbol name
361 5.0419 vmlinux copy_page_range
322 4.4972 udevd udev_rules_iter_next
300 4.1899 vmlinux copy_page_c
Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
"Hello world!" linked against libselinux parses /proc/mounts and
whatever else on startup, even when the lib is not needed at all.
Not funny! Get rid of that thing where it's not absolutely needed.
strerror() is not threadsafe. It uses a buffer to build messages of the form
"Unknown error 387689".
syslog() provides a %m format which is equivalent to strerror(errno).
As a GNU extension, this is also accepted by printf and friends.
At least in the current implementation, it is correctly threadsafe.
Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
This was needed in the old days, where all the hotplug scripts did
nothing better than sleep for seconds to work around timing issues.
It made sure, that w continued to fork processes, while the machine
was doing nothing than sleeping, but the maximim number of childs
was already reached. This is no longer needed today, we do not run
many of these scripts anymore.
envp is not standardized, and may become invalid when environment variables
are modified. Since udev never actually uses it, we can simply remove it.
Should anyone miss it in future, they can use the standardized environ
variable - like udev_rules.c does already.