1
0
mirror of https://github.com/systemd/systemd.git synced 2024-10-28 20:25:38 +03:00
Commit Graph

3007 Commits

Author SHA1 Message Date
Kay Sievers
dacea9ff6b libudev: monitor - switch to filter_add_match_subsystem_devtype() 2009-04-23 03:24:38 +02:00
Kay Sievers
c7dff03e05 libudev: monitor - use simpler hash 2009-04-22 18:38:16 +02:00
John Wright
a947e5eaae edd_id: add cciss devices
Since cciss devices can be BIOS boot devices just as well as sd* and
hd*, the edd_id program should be run on them so that the later
/dev/disk/by-id/edd-* rules will work.
2009-04-22 14:53:35 +02:00
Kay Sievers
a9550eb11f udevadm monitor - add --subsystem-match= 2009-04-22 05:00:15 +02:00
Kay Sievers
4277453fd2 update TODO 2009-04-22 04:32:25 +02:00
Kay Sievers
3111a33e95 udevadm: monitor - print error if we can not bind to socket 2009-04-22 04:11:18 +02:00
Kay Sievers
e14bdd88e9 libudev: monitor - add client socket filter for subsystem value
Messages send back by the udev daemon to the netlink socket are
multiplexed by the kernel and delivered to multiple clients. The
clients can upload a socket filter to let the kernel drop messages
not belonging to a certain subsystem. This prevent needless wakeups
and message processing for users who are only interested in a
subset of available events.

Recent kernels allow untrusted users to listen to the netlink
messages.

The messages send by the udev daemon are versioned, to prevent any
custom software reading them without libudev. The message wire format
may change with any udev version update.
2009-04-22 03:50:11 +02:00
Kay Sievers
f907449eee cdrom_id: add and use ID_CDROM_MEDIA to decide if we run vol_id
Some broken mobile phones offer a faked cdrom drive with a media
without any tracks.
2009-04-21 03:27:14 +02:00
Kay Sievers
540f46698d udevd: at startup create /dev/null, /dev/console, /dev/kmsg 2009-04-19 03:25:04 +02:00
Kay Sievers
ccc87b0e99 update NEWS 2009-04-18 13:24:20 +02:00
Kay Sievers
cc2c6d6ad9 TODO: add packet filter 2009-04-18 13:23:55 +02:00
Kay Sievers
f1986e09fc test-libudev: update monitor source 2009-04-18 13:23:10 +02:00
Kay Sievers
55d8f5e208 cdrom_id: add Xen cdrom support 2009-04-17 00:29:56 +02:00
Ian Campbell
09b2999210 path_id: support identification of Xen virtual block devices 2009-04-16 22:46:18 +02:00
Kay Sievers
e2151b00e9 update NEWS 2009-04-16 22:36:26 +02:00
Kay Sievers
7a87d34f8a rules: remove DVB shell script 2009-04-16 22:35:59 +02:00
Kay Sievers
b44b7f8841 udevd: log error for too old kernels or CONFIG_SYSFS_DEPRECATED 2009-04-16 22:34:26 +02:00
Kay Sievers
ff109b8ded libudev: monitor - clarify socket handling documentation 2009-04-16 01:49:16 +02:00
Kay Sievers
3e5bafc98a libudev: path_encode - always return 0 if encoded string does not fit into size 2009-04-15 21:47:04 +02:00
Kay Sievers
9b144b8857 version bump 2009-04-14 21:02:39 +02:00
Kay Sievers
dbf4ba73c2 release 141 2009-04-08 16:35:53 -07:00
Scott James Remnant
e86a923d50 libudev: monitor - ignore messages from unusual sources
For added protection, ignore any unicast message received on the
netlink socket or any multicast message on the kernel group not
received from the kernel.

Signed-off-by: Scott James Remnant <scott@ubuntu.com>
2009-04-08 16:16:14 -07:00
Kay Sievers
e2b362d9f2 libudev: monitor - unify socket message handling 2009-04-08 07:46:54 -07:00
Kay Sievers
662c311080 path_encode: fix max length calculation
Sebastian Krahmer wrote:
> it should reserve 4 times not 3 times len :)
2009-04-08 06:06:01 -07:00
Alan Jenkins
4b09a2fc43 avoid leaking netlink socket fd to external programs
The netlink socket is now used by udev event processes. We should take
care not to pass it to the programs they execute. This is the same way
the inotify fd was handled.

Signed-off-by: Alan Jenkins <alan-jenkins@tuffmail.co.uk>
2009-04-06 07:23:35 -07:00
Kay Sievers
52761bb0a9 IMPORT: 2048 -> 4096 bytes buffer 2009-03-30 20:09:08 +02:00
Kay Sievers
f2b937440c "UDEV_MONITOR_KERNEL/UDEV" -> "kernel/udev" 2009-03-29 20:08:52 +02:00
Kay Sievers
116254097a send monitor events back to netlink socket
Instead of of our own private monitor socket, we send the
processed event back to our netlink socket, to the multicast
group 2 -- so any number of users can listen to udev events,
just like they can listen to kernel emitted events on group 1.
2009-03-29 04:24:39 +02:00
Kay Sievers
241e5a21f9 usb_id: remove unused variable 2009-03-28 20:57:01 +01:00
Kay Sievers
4061ab9f4b libudev: GPL -> LGPL 2009-03-26 19:29:36 +01:00
Kay Sievers
9ae847f420 usb_id: add ID_VENDOR_ID, ID_MODEL_ID, ID_USB_INTERFACE_NUM, ID_USB_DRIVER
$ extras/usb_id/usb_id -x /class/tty/ttyUSB1
ID_VENDOR=HUAWEI_Technology
ID_VENDOR_ENC=HUAWEI\x20Technology
ID_VENDOR_ID=12d1
ID_MODEL=HUAWEI_Mobile
ID_MODEL_ENC=HUAWEI\x20Mobile
ID_MODEL_ID=1003
ID_REVISION=0000
ID_SERIAL=HUAWEI_Technology_HUAWEI_Mobile
ID_TYPE=generic
ID_BUS=usb
ID_USB_INTERFACES=:ffffff:080650:
ID_USB_INTERFACE_NUM=01
ID_USB_DRIVER=option
2009-03-25 21:24:21 +01:00
Kay Sievers
a0aa1d76d0 rules: replace IDE driver with media match 2009-03-25 13:40:55 +01:00
Kay Sievers
65336f8614 rules: serial - support ttyACM devices 2009-03-24 01:55:47 +01:00
Kay Sievers
c4390e0711 rules: remove ram* from persisten disk links blacklist 2009-03-23 21:09:02 +01:00
David Brownell
684028b5be rules: exclude mtd* from persistent disk links 2009-03-23 21:03:00 +01:00
Borislav Petkov
c51446e893 rules: rename ide-floppy to ide-gd
The driver's name changed in the 2.6.28 timeframe.
2009-03-22 15:10:06 +01:00
Kay Sievers
498c2750bf udevadm: monitor - clarify printed header 2009-03-18 18:47:23 +01:00
Kay Sievers
f454f6708a udevadm: test - handling trailing '/' in devpath
On Wed, Mar 18, 2009 at 16:00, Matthias Schwarzott <zzam@gentoo.org> wrote:
found out how the error occurs:
It is a difference between
A. udevadm test /sys/class/mem/null/
and
B. udevadm test /sys/class/mem/null

Case A was the case that showed the error behaviour. It seems udevadm is
confused by the trailing slash. This behaviour seems to be there since ages.
2009-03-18 18:42:16 +01:00
Kay Sievers
b25d8cfa93 version bump 2009-03-18 17:54:00 +01:00
Kay Sievers
3b8103d45f rules: fix extra quote in 50-udev-default.rules
Patch from Gerardo Exequiel Pozzi.
2009-03-18 02:32:12 +01:00
Robby Workman
1d59ba4077 udevadm: trigger - add "--action" to --help 2009-03-17 10:31:32 +01:00
Adam Buchbinder
977f6f4b3d vol_id: fix language in manpage
The documentation for the --offset option wasn't in complete
sentences.

Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
2009-03-16 23:11:02 +01:00
Adam Buchbinder
9a2773c4a4 create_floppy_devices: expand manpage
Include a table of what the CMOS types are, and note that nothing
will be created unless the -t option is specified. Also clean up
the formatting and bump the date.

Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
2009-03-16 23:10:15 +01:00
Adam Buchbinder
57a9e68eb7 cdrom_id: update manpage
Include usage information on the -d/--debug flag. Also bump the date.

Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
2009-03-16 23:09:52 +01:00
Adam Buchbinder
57df0207aa usb_id: add manpage
Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
2009-03-16 23:09:32 +01:00
Michal Soltys
376f0a1ef5 rules: md-raid.rules fix
md/array_state in case of partition doesn't exist, so all uevents
for partitions didn't execute any SYMLINK rules

Signed-off-by: Michal Soltys <soltys@ziu.info>
2009-03-16 01:29:19 +01:00
Kay Sievers
3d8599873a release 140 2009-03-13 13:17:31 +01:00
Scott James Remnant
bb38678e3c udevadm: settle - synchronise with the udev daemon
There's still a slight race condition when using udevadm settle, if the
udev daemon has a pending inotify event but hasn't yet generated the
"change" uevent for it, the kernel and udev sequence numbers will match
and settle will exit.

Now udevadm settle will send a control message to udevd, which will
respond by sending SIGUSR1 back to the waiting udevadm settle once it
has completed the main loop iteration in which it received the control
message.

If there were no pending inotify events, this will simply wake up the
udev daemon and allow settle to continue.  If there are pending inotify
events, they are handled first in the main loop so when settle is
continued they will have been turned into uevents and the kernel
sequence number will have been incremented.

Since the inotify event is pending for udevd when the close() system
call returns (it's queued as part of the kernel handling for that system
call), and since the kernel sequence number is incremented by writing to
the uevent file (as udevd does), this solves the race.

When the settle continues, if there were pending inotify events that
udevd had not read, they are now pending uevents which settle can wait
for.

Signed-off-by: Scott James Remnant <scott@ubuntu.com>
2009-03-12 10:02:37 +00:00
Kay Sievers
c2c24d4d3c udevadm: settle - use timeout signal, instead of loop counter 2009-03-11 15:06:14 +01:00
Kay Sievers
89d080c3ae libudev: ctrl - return error after sending ctrl message 2009-03-11 13:32:39 +01:00