summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2008-10-24fix uninitialized variable warningsKay Sievers
2008-10-24rules: let empty strings added to buffer always return offset 0Kay Sievers
2008-10-23skip SYMLINK rules for devices without a device nodeKay Sievers
2008-10-23udevd: fix WAIT_FOR_SYSFS execution orderAlan Jenkins
The wait should be ordered after matching KERNEL, ENV, etc. but before ATTR. Without this, WAIT_FOR_SYSFS rules will be applied unconditionally to all events. Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-23rule_generator: fix netif NAME= value extraction regexKay Sievers
$ sed -n -r \ -e 's/^#.*//' \ -e 's/[[:space:],]NAME="(eth[0-9]*)"[[:space:]]*(,.*|\\|)$/\1/p' \ /dev/null /etc/udev/rules.d/70-persistent-net.rules SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:16:41:e2:8d:c7", ATTR{type}=="1", KERNEL=="eth*",eth4 $ sed -n -r \ -e 's/^#.*//' \ -e 's/.*[[:space:],]NAME="(eth[0-9]*)".*/\1/p' \ /dev/null /etc/udev/rules.d/70-persistent-net.rules eth4
2008-10-23udevd: fix memory leakAlan Jenkins
Re: b99028c96307e729303be8f6750418979a7488b9 shrink struct udev_event TEST 136: test multi matches 2 device '/devices/pci0000:00/0000:00:1d.7/usb5/5-2/5-2:1.0/tty/ttyACM0' expecting node 'right' ==15011== ==15011== 7 bytes in 1 blocks are definitely lost in loss record 1 of 1 ==15011== at 0x47F9AB8: malloc (vg_replace_malloc.c:207) ==15011== by 0x489CB5F: strdup (in /lib32/libc-2.7.so) ==15011== by 0x8050F40: udev_rules_apply_to_event (udev-rules.c:1973) ==15011== by 0x804A658: udev_event_execute_rules (udev-event.c:549) ==15011== by 0x805A636: main (test-udev.c:100) add: ok ==15012== ==15012== 7 bytes in 1 blocks are definitely lost in loss record 1 of 1 ==15012== at 0x47F1AB8: malloc (vg_replace_malloc.c:207) ==15012== by 0x4898B5F: strdup (in /lib32/libc-2.7.so) ==15012== by 0x8050F40: udev_rules_apply_to_event (udev-rules.c:1973) ==15012== by 0x804A9DF: udev_event_execute_rules (udev-event.c:658) ==15012== by 0x805A636: main (test-udev.c:100) remove: ok Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-23shrink struct udev_eventKay Sievers
2008-10-23shrink struct udev_eventKay Sievers
2008-10-23do not create temporary node ($tempnode) if node already existsKay Sievers
2008-10-23replace in-memory rules array with match/action token listKay Sievers
The in-memory rule array of a common desktop distro install took: 1151088 bytes with the token list: 109232 bytes tokens (6827 * 16 bytes), 71302 bytes buffer
2008-10-22handle numerical owner/group string in lookup_user/group()Kay Sievers
2008-10-22use re-entrant variants of getpwnam and getgrnamAlan Jenkins
Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-22add util_resolve_subsys_kernel()Kay Sievers
2008-10-22volume_id: swap - larger PAGE_SIZE supportMatthias Koenig
2008-10-21replace strncpy() with strlcpy()Alan Jenkins
The problem was strncpy() doesn't stop after writing the terminating NUL; by definition it goes on to zero the entire buffer. I spy another use of strncpy in udev_device_add_property_from_string(), which is responsible for another ~1% user cpu time... Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-21libudev: device - 128 -> ENVP_SIZEKay Sievers
2008-10-21libudev: allocate udev_device->envp[] dynamicallyAlan Jenkins
Measured 2% _user_ cpu time reduction on EeePC coldplug. Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-21libudev: util - optimize path_encode()Alan Jenkins
Since we already know the length, use memcpy() instead. Measured 2% _user_ cpu time reduction on EeePC coldplug. Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-21use more appropriate alternatives to malloc()Alan Jenkins
Use calloc to request cleared memory instead. Kernel and libc conspire to make this more efficient. Also, replace one malloc() + strcpy() with strdup(). Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2008-10-21do not use the new work-in-progress parser rule matcherKay Sievers
2008-10-21add "root" == 0 shortcuts to lookup_user/group()Kay Sievers
2008-10-21replace missing get_attr_value() -> get_sysattr_value()Kay Sievers
2008-10-21cdrom_id: remove ARRAY_SIZE() declarationKay Sievers
2008-10-20libudev: device - get_attr_value() -> get_sysattr_value()Kay Sievers
2008-10-18pass make distcheckKay Sievers
2008-10-18prefix udev-util.c functions with util_*Kay Sievers
2008-10-18selinux_init(udev) -> udev_selinux_init(udev)Kay Sievers
2008-10-18udev_list_cleanup() -> udev_list_cleanup_entries()Kay Sievers
2008-10-18move udev_rules_apply_format() to udev-event.cKay Sievers
2008-10-18udev_rules_run() -> udev_event_execute_run();Kay Sievers
2008-10-18udev_event_run() -> udev_event_execute_rules()Kay Sievers
2008-10-18udevd: avoid overhead of calling rmdir on non-empty directoriesAlan Jenkins
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>
2008-10-18move run_program to utilKay Sievers
2008-10-18make struct udev_rules opaqueKay Sievers
2008-10-18merge udev-rules.c and udev-rules-parse.cKay Sievers
2008-10-17delete list.hKay Sievers
2008-10-17collect: use udev_listKay Sievers
2008-10-17udevd: use udev_list_nodeKay Sievers
2008-10-17libudev: make list_node functions availableKay Sievers
2008-10-17libudev: ctrl - change magic to integerKay Sievers
2008-10-17libudev: monitor - add set_receive_buffer_size()Kay Sievers
2008-10-17test: fix a few unintentially wrongly written rules which cause parse errorsKay Sievers
2008-10-17libudev: add sysnum to test programKay Sievers
2008-10-17libudev: fix sysnum logic for digit-only device namesAlan Jenkins
2008-10-17libudev: list - prepend udev_* to all functionsKay Sievers
2008-10-17delete udev-util-file.cKay Sievers
2008-10-17update rules file parsingKay Sievers
2008-10-16update IMPORT= file/stdout property parsingKay Sievers
2008-10-16run_program: prevent empty last argv entryKay Sievers
2008-10-16fix sorting of rules filesKay Sievers