Kay Sievers
372b9bffa7
udevadm: test - use printf() instead of info() for non-debug output
2011-04-17 22:09:08 +02:00
Kay Sievers
578cd5101d
udevadm: monitor - use epoll
2011-04-15 11:58:17 +02:00
Kay Sievers
7459bcdc8d
udevd: get netlink socket from systemd
2011-04-14 23:46:44 +02:00
Kay Sievers
7f2d3a3fc8
require explicit "db_persist" to exclude device info from --db-cleanup
2011-04-14 14:44:56 +02:00
Kay Sievers
8b4631362f
udevd: move OOM disable into --daemon option
2011-04-14 14:43:22 +02:00
Kay Sievers
d3990a576a
"db_persist=" -> "db_persist"
2011-04-14 12:42:59 +02:00
Kay Sievers
02bf3e13e0
udevd: do not nice processes
2011-04-14 12:25:19 +02:00
Kay Sievers
9ead662791
udevadm: info --cleanup-db
...
Most of the udev database from initramfs should be deleted before
starting udev in the real root. udevadm: info --cleanup-db deletes
all database entries in /run/udev. Events that processed IMPORT{db},
or mark devices explicitely as persistent, will be excluded.
2011-04-13 22:33:01 +02:00
Kay Sievers
a3eca08b19
udevadm: settle - watch queue file
2011-04-13 18:44:28 +02:00
Kay Sievers
2903820a62
udevd: log warning if /run is not writable
2011-04-13 15:01:00 +02:00
Kay Sievers
e48e291202
trivial cleanups
2011-04-13 01:47:56 +02:00
Kay Sievers
ff2c503df0
udevadm: control - add --exit
2011-04-13 01:17:09 +02:00
Michael Witten
620da34de2
Docs: udev.xml: Fix dangling modifier
2011-04-11 05:49:41 +00:00
Michael Witten
d0878effb9
Docs: udev.xml: Improved word order
2011-04-11 05:49:41 +00:00
Michael Witten
2d74bc7579
Docs: udev.xml: Clarify through a change in word ordering
2011-04-11 05:49:41 +00:00
Michael Witten
e8b5e4e590
Docs: udev.xml: `comma-separated' is a better description
2011-04-11 05:49:40 +00:00
Michael Witten
509c02f160
Docs: udev.xml: char' ->
character'
2011-04-11 05:49:40 +00:00
Michael Witten
21188522ae
Docs: udev.xml: Add comma
2011-04-11 05:49:40 +00:00
Michael Witten
f61501b0f8
Docs: udev.xml: Actually make a separate paragraph
2011-04-11 05:49:40 +00:00
Michael Witten
f2db23cd0d
Docs: udev.xml: Use normal sentence structure
2011-04-11 05:49:39 +00:00
Michael Witten
57e804843b
Docs: udev.xml: Clean up introduction to substitutions.
...
For one thing, they are not at all like printf conversion specifications.
2011-04-11 05:49:39 +00:00
Michael Witten
0fbda083a2
Docs: udev.xml: a' ->
the'
2011-04-11 05:49:39 +00:00
Michael Witten
793681cb55
Docs: udev.xml: Clean up WAIT_FOR description
2011-04-11 05:49:39 +00:00
Michael Witten
ad9c70a836
Docs: udev.xml: commandline' ->
command line'
2011-04-11 05:49:38 +00:00
Michael Witten
b6a49cd681
Docs: udev.xml: which' ->
content of which'
2011-04-11 05:49:38 +00:00
Michael Witten
2f16de298f
Docs: udev.xml: Add missing `.'
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:38 +00:00
Michael Witten
c24dfc80c6
Docs: udev.xml: Clean up description of LABEL assignment key
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:38 +00:00
Michael Witten
1d14abe61f
Docs: udev.xml: Clean up description of RUN assignment key
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:37 +00:00
Michael Witten
ed9c5fb721
Docs: udev.xml: Clean up description of ENV assignment key
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:37 +00:00
Michael Witten
9f38b806d2
Docs: udev.xml: Clean up description of SYMLINK assignment key
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:37 +00:00
Michael Witten
ac1ba8e487
Docs: udev.xml: Clean up description of NAME assignment key
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:37 +00:00
Michael Witten
2c47027b31
Docs: udev.xml: Clean character range description
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:36 +00:00
Michael Witten
954e9c52d1
Docs: udev.xml: Clean `*' description
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:36 +00:00
Michael Witten
401e59e9ae
Docs: udev.xml: a shell style' ->
shell-style'
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:36 +00:00
Michael Witten
2e9820e374
Docs: udev.xml: Clarify PROGRAM key
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:36 +00:00
Michael Witten
65e039c2e2
Docs: udev.xml: Use `unless' for clarity
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:35 +00:00
Michael Witten
2e7f69ebbf
Docs: udev.xml: Add a few more words for context
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:35 +00:00
Michael Witten
2bf11540cf
Docs: udev.xml: Remove unnecessary repitition
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:35 +00:00
Michael Witten
55f5037ce8
Docs: udev.xml: `comma-separated' is a better description
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:34 +00:00
Michael Witten
b834042f05
Docs: udev.xml: Use `assignment' consistently
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:34 +00:00
Michael Witten
57c0409fce
Docs: udev.xml: ,' ->
:'
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:34 +00:00
Michael Witten
feedf8f3ee
Docs: udev.xml: key value' ->
key-value'
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:34 +00:00
Michael Witten
c3cba32f18
Docs: udev.xml: ,' ->
;'
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:33 +00:00
Michael Witten
d4a7bf2583
Docs: udev.xml: Clarification through proper wording
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:33 +00:00
Michael Witten
933b56237d
Docs: udev.xml: Use present tense
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:33 +00:00
Michael Witten
17fd0f60f2
Docs: udev.xml: are' ->
is'; the subject is `Access'
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:33 +00:00
Michael Witten
0e846301f4
Docs: udev.xml: Remove commas (and unnecessary repetition)
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:32 +00:00
Michael Witten
0e4fa2abfe
Docs: udev.xml: Offset daemon name with commas
...
Signed-off-by: Michael Witten <mfwitten@gmail.com>
2011-04-11 05:49:32 +00:00
Kay Sievers
51f43b5329
selinux: do not label files in runtime dir
...
Do not label any files in the udev runtime directory, but only nodes,
links and directories below /dev.
In case the runtime directory falls back to /dev/.udev, label this
directory once at udevd startup, but never anything below it.
2011-04-08 01:09:20 +02:00
Thomas Egerer
6ee9b2cb8c
udevd: add 'N:' to optstring in getopt_long
2011-03-31 17:26:37 +02:00
Kay Sievers
864fde8a08
man: remove trigger --type=failed handling
2011-03-23 23:56:15 +01:00
Kay Sievers
fc1de713f5
systemd: bind udev control socket in systemd and split udev.service
...
We should bind the udev socket from systemd, so we are sure
that the abstract namespace socket is always bound by a root
process and there is never a window during an update where
an untrusted process can steal our socket.
Also split the udev.service file, so that the daemon can be
updated/restarted without triggering any coldplug events.
2011-03-23 16:40:23 +01:00
Kay Sievers
4ec9c3e797
use /run/udev/ if possible and fall back to /dev/.udev/
2011-03-23 02:31:09 +01:00
Kay Sievers
3c6ee19027
udevd: initialize fds, for proper close() on exit
2011-03-23 01:45:21 +01:00
Kay Sievers
cf3b3fbcd5
udevd: use facility == LOG_DAEMON when writing to /dev/kmsg
...
Syslog wants to distinguish the sorce of messages. We should
indicate that this is a userspace message (LOG_DAEMON) and not
a kernel message (LOG_KERNEL).
2011-03-23 01:41:25 +01:00
Kay Sievers
b7822bc498
update sd-daemon.[ch]
2011-03-23 01:34:29 +01:00
Kay Sievers
5f59fa0900
move /dev/.udev/ to /dev/.run/udev/ and convert old udev database at udevd startup
2011-03-15 17:26:08 +01:00
Thomas Egerer
74e8a45ed4
udevadm: info - make attribute array static and const
2011-03-08 13:14:44 +01:00
Kay Sievers
20bee04c19
libudev: udev_device_get_sysattr_list_entry() update
2011-03-04 23:00:52 +01:00
Thomas Egerer
95ce1875d7
libudev: use sysfs attr ilist interface for attribute walk
...
Signed-off-by: Thomas Egerer <thomas.egerer@secunet.com>
2011-03-04 21:51:32 +01:00
Kay Sievers
0c19cc73da
update some comments
2011-02-15 22:28:31 +01:00
Kay Sievers
50863e4a23
update gitignore
2011-02-09 22:12:15 +01:00
Kay Sievers
378380397c
man: fix typo
...
Found by: Minh Ha-Duong.
2011-01-04 18:32:46 +01:00
Kay Sievers
9c6a11b1c6
libudev: record and export "age" of device record
2010-12-15 08:58:46 +01:00
Kay Sievers
48a0170b11
libudev: enumerate - allow to filter-out not-already-initialized devices
2010-12-14 14:18:32 +01:00
Kay Sievers
ff0e1f4e5d
check ifindex > 0 instead of subsystem == "net"
2010-12-14 11:27:02 +01:00
Kay Sievers
cad40a5fe7
udevd: switch to common id_filename functions
2010-12-12 20:07:15 +01:00
Kay Sievers
24d1076696
udevd: simplify udev database and fix DEVNAME handling
2010-12-11 14:00:46 +01:00
Kay Sievers
2713e6ab0a
udevd: always create /dev/{char,block}/$major:$minor
2010-12-10 13:27:03 +01:00
Kay Sievers
4281da1fa6
udevd: use dev_t or netif ifindex as database key
...
We need to preserve the database of network interfaces while we
rename them. Use the kernel's numbers wherever possible, instead
of the device names.
Fix wrong database filenames which contain a '/', translated
from '!' in the kernel name.
Fix segfault for kobject pathes where the subsystem can not be
determined from sysfs.
2010-12-10 01:18:15 +01:00
Kay Sievers
dc1791a9e6
udevadm: info - honor --export, --export-prefix=
2010-12-10 01:18:15 +01:00
Kay Sievers
88163971b9
udevadm: info - honor --export and --export-prefix for property query
...
The output will always be quoted:
$ udevadm info --export --export-prefix=MY_ --query=property --name=sda
MY_UDEV_LOG='3'
MY_DEVPATH='/devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/block/sda'
MY_MAJOR='259'
MY_MINOR='0'
MY_DEVNAME='sda'
MY_DEVTYPE='disk'
MY_SUBSYSTEM='block'
2010-12-10 01:18:14 +01:00
Michal Soltys
1a6ab67030
udevd: create static nodes before /dev/null is needed
2010-11-22 13:55:20 +01:00
Harald Hoyer
851dd4ddc5
udev-rules.c: change import property buffer to 16384 bytes
...
import_program_into_properties() should have the same line length as
import_file_into_properties()
see also https://bugzilla.redhat.com/show_bug.cgi?id=652318
2010-11-12 14:42:35 +01:00
Jakub Wilk
b8015eea2d
man: udev - workaraound -> workaround
2010-11-10 01:30:53 +01:00
Kay Sievers
1c2311c556
return proper error code in rename_netif()
...
<Md> kay: can you look at rename_netif()? it returns -errno in a place,
but I think that it may by changed by err() (at least)
<kay> Md: yeah, that doesn't look correct
2010-10-18 12:55:06 +02:00
Kay Sievers
fc416258f3
udevd: do not wrongly delay events for devices with swapped names
...
Renaming network devices might delay events for the other device, which has
the same devpath in the meantime as the original event. Causing a delay until
the timout of the event is reached.
Look at the ifindex/devnum of the devices to check if they are really
the same devices.
2010-10-13 13:08:29 +02:00
Kay Sievers
392ef7a28a
udevd: add sd-daemon.c
2010-10-07 14:59:11 +02:00
Martin Pitt
1079014420
Clarify WAIT_FOR documentation
...
The path is relative to the sysfs device, so this provides an easy way to wait
for an attribute to appear.
2010-09-21 12:12:01 +02:00
Kay Sievers
326c5fc3ea
set SELinux context on 'add' but not on 'change' events
2010-08-31 21:29:21 +02:00
Martin Pitt
83184d008b
udev(7) manpage: Fix description of $attr
...
Fix the manpage to describe the real behaviour of $attr: It doesn't search all
parent devices any more, just the one selected by KERNELS etc.
https://launchpad.net/bugs/348513
2010-08-27 16:56:32 +02:00
Luca Tettamanti
c61eea9459
Add support for oom_score_adj
...
/proc/<pid>/oom_adj has been deprecated (kernel v2.6.36) due to the
rework of the badness heuristic; oom_score_adj is the replacement.
Keep a fallback to the old interface for compatibility with older
kernels.
See http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commitdiff;h=a63d83f427fbce97a6cea0db2e64b0eb8435cd10
Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-25 16:50:30 +02:00
Kay Sievers
13f90be7a3
udevd: remove unneeded credential passing from init_notify()
2010-08-25 16:26:54 +02:00
Martin Pitt
6593e8961a
udev(7): Point out required extension, and remove some confusion
...
Rules files must end in .rules.
Also drop the redundant and confusing sentence about "file names must be
unique". What is really meant is explained in a better way in the paragraph
above.
https://launchpad.net/bugs/616108
2010-08-20 12:19:23 +02:00
Kay Sievers
c25bfbfb1b
udevd: add pid to kmsg logs
2010-08-19 08:49:43 +02:00
Kay Sievers
ebd189621f
do not rename the database on device rename
...
Harald Hoyer discovered some incorrect behavior while debugging
problems with network interface renaming:
Udev events might be queued for devices which are renamed. A new
device registered the same time may claime the old name and create
a database entry for it. The current rename logic would move over
this databse entry to the wrong device.
2010-08-11 14:34:32 +02:00
Kay Sievers
ce9a42bec4
always log error when renaming a network interface fails
2010-08-11 14:29:49 +02:00
Harald Hoyer
09c0310302
udev-event.c: rename interface to <src>-<dest>, if <dest> taken
...
e.g. if eth0 should be eth3 and eth3 is waiting to be renamed,
eth0 was renamed to eth0_rename. The kernel would take eth0 as the name
for a new interface and this new eth0 could also become eth0_rename, if
the target name is also taken. To prevent this name clash, the
interfaces are now renamed to <src>-<dest> and the rename is logged.
2010-08-10 16:46:48 +02:00
Yin Kangkai
08f11597f2
udevd: create static device links only when the target exists
...
For example, not all systems have PROC_KCORE enabled. Avoid a broken symbolic
link in those cases.
Signed-off-by: Yin Kangkai <kangkai.yin@intel.com>
Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 20:35:46 +02:00
Yin Kangkai
40929a0222
udevd: fix unref'ing of device in error path
...
Signed-off-by: Yin Kangkai <kangkai.yin@intel.com>
Signed-off-by: Martin Pitt <martin.pitt@ubuntu.com>
2010-08-08 20:29:13 +02:00
Kay Sievers
8e5a620b17
call util_delete_path() only when we actually deleted stuff
2010-08-03 12:13:53 +02:00
Yin Kangkai
4ab3c463d4
udevd: fix short options in getopt()
2010-08-03 08:11:43 +02:00
Yin Kangkai
27f4528b9a
malloc()+memset() -> calloc()
2010-08-03 08:10:26 +02:00
Yin Kangkai
1851332c08
udevd: fix some memory leaks in error path
...
Signed-off-by: Yin Kangkai <kangkai.yin@intel.com>
2010-08-02 12:37:55 +02:00
Yin Kangkai
163c0365ff
udevadm: fix short options in getopt()
2010-07-28 06:56:13 +02:00
Kay Sievers
35df38c36a
udevd: init_notify() fix abstract namespace name handling
2010-07-11 23:57:11 +02:00
Kay Sievers
3b529da425
allow final assignment for OPTIONS:="nowatch"
...
A final assignemnt operator will disable any device watching by
inotify, and any possible later rules setting "watch" again will
be ignored.
2010-07-07 11:35:40 +02:00
Kay Sievers
a65aa40f8a
udevd: in case we don't daemonize, send READY message to /sbin/init
2010-06-17 21:52:15 +02:00
Kay Sievers
7d2b68b734
IMPORT{cmdline}: start at first char after '='
2010-05-31 11:04:42 +02:00
Kay Sievers
c4f6dcc4a5
add IMPORT{cmdline}
2010-05-31 01:13:03 +02:00