1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-11-01 09:21:11 +03:00
Commit Graph

54 Commits

Author SHA1 Message Date
Kay Sievers
c70560feef logging: add trailing newline to all strings 2008-04-20 21:07:06 +02:00
Kay Sievers
544c2923db sysfs: depend on "subsystem" link 2008-03-14 23:32:45 +01:00
Kay Sievers
d438c80e57 fix debug output string 2007-09-25 13:45:49 +02:00
Michael Morony
1f7a36f2c0 set buffer size if strlcpy/strlcat indicate truncation 2007-08-24 08:14:21 +02:00
Kay Sievers
fd80719273 sysfs: skip unknown sysfs directories 2007-06-04 11:20:18 +02:00
Kay Sievers
96d3d86145 sysfs: handle bus/class top-level directories 2007-06-04 10:50:05 +02:00
Kay Sievers
03178b0cce sysfs: change order of subsystem lookup 2007-06-02 22:00:10 +02:00
Kay Sievers
4722274ca0 sysfs: add device lookup by $SUBSYSYTEM:$KERNEL 2007-06-02 09:43:57 +02:00
Kay Sievers
eb5b86405b update %n on netif name change 2007-03-19 09:56:53 +01:00
Kay Sievers
66ec64e9ad first try "subsystem" link at a parent device, before guessing 2006-10-08 16:04:54 +02:00
Kay Sievers
82c60ce572 udev_sysfs: unify symlink resolving 2006-09-19 17:46:04 +02:00
Kay Sievers
492e76c9c1 udevinfo: do not show symlinks as attributes in --attribute-walk 2006-09-05 13:54:08 +02:00
Kay Sievers
eef5447934 let $attr{symlink} return the last element of the path
Example for /block/sda:
  SUBSYSTEMS="scsi", ENV{COMMENT}="$attr{driver}"
sets COMMENT=sd
  SUBSYSTEMS="pci", ENV{COMMENT}="$attr{driver}"
sets COMMENT=ata_piix
2006-09-05 02:18:06 +02:00
Kay Sievers
27b77df44d update source file headers 2006-08-28 00:29:11 +02:00
Kay Sievers
95776dc6ec consistent key naming to match only the event device or include all parent devices
This scheme is more consistent and makes it obvious if a match happens
against the event device only, or the full chain of parent devices.

The old key names are now:
  BUS -> SUBSYSTEMS
  ID -> KERNELS
  SYSFS -> ATTRS
  DRIVER -> DRIVERS

Match keys for the event device:
  KERNEL
  SUBSYSTEM
  ATTR
  DRIVER (in a future release, for now the same as DRIVERS)

Match keys for all devices along the parent device chain:
  KERNELS
  SUBSYSTEMS
  ATTRS
  DRIVERS

ID, BUS, SYSFS are no longer mentioned in the man page but still work.
DRIVER must be converted to DRIVERS to match the new scheme. For now,
an error is logged, if DRIVER is used. In a future release, the DRIVER
key behaviour will change.
2006-08-19 16:06:25 +02:00
Kay Sievers
254efc14a4 udevd: read DRIVER from the environment 2006-08-13 05:32:09 +02:00
Kay Sievers
7e75cfa6fe add debug output to sysfs operations
Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2006-01-30 08:39:55 +01:00
Kay Sievers
34f55103c5 optimize sysfs device and attribute cache
Add negative cache for attributes and look for device in cache before doing
any sysfs access. (Three times speed up for a stupid 1000 rules SYSFS file).

Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2006-01-29 02:09:35 +01:00
Kay Sievers
d8a57e7c26 Makefile: remove dynamic config file generation
Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2006-01-23 03:24:16 +01:00
Olivier Blin
aaa14841de fixes udev build with -fpie
Add missing includes and environ declaration.
2006-01-20 23:18:23 +01:00
Kay Sievers
6ecd4d1e36 scsi_id, usb_id: request device parent by subsystem
Request specific parents identified by subsystem and don't rely on
a predefined sequence.
Also let the devpath be longer than 72 chars, tsss ...

Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2006-01-18 04:24:48 +01:00
Kay Sievers
ea48d4d7fb prepare moving of /sys/class devices to /sys/devices
Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2006-01-16 06:14:26 +01:00
Kay Sievers
1aa1e24848 replace libsysfs
We never used any of the libsysfs convenience features. Here we replace
it completely with 300 lines of code, which are much simpler and a bit
faster cause udev(d) does not open any syfs file for a simple event which
does not need any parent device information.

Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2006-01-09 21:18:00 +01:00
Kay Sievers
c86be870ce remove all built-in wait_for_sysfs logic
Most of the issues are fixed with the kernel we depend on, for the
remaing ones see the RELEASE-NOTES for a special rule to add.

Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2005-11-12 04:17:48 +01:00
Kay Sievers
2a4ce70925 remove no longer needed waiting for "dev" file
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
2005-10-29 21:13:43 +02:00
Kay Sievers
bcd9fc8f47 add pci_express to bus list
Hopefully that wait_for_sysfs crap can go away some day...

Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2005-08-25 03:37:38 +02:00
Kay Sievers
c9b8dbfb65 fix the fix and change the file to wait for to the "bus" link
Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2005-06-22 02:11:59 +02:00
Kay Sievers
bf5d296473 prepare for module loading rules and add MODALIAS key
Signed-off-by: Kay Sievers <kay.sievers@suse.de>
2005-06-20 00:29:38 +02:00
kay.sievers@vrfy.org
63f61c5cf6 [PATCH] replace strncpy()/strncat() by strlcpy()/strlcat() 2005-04-26 23:51:00 -07:00
kay.sievers@vrfy.org
75bc9b086f [PATCH] kill stupid gcc4 warning 2005-04-26 23:39:48 -07:00
kay.sievers@vrfy.org
9c020c6016 [PATCH] wait_for_sysfs: add joydev 2005-04-26 23:39:48 -07:00
kay.sievers@vrfy.org
9f6f8859b0 [PATCH] add "serio" to bus list 2005-04-26 23:36:13 -07:00
kay.sievers@vrfy.org
7e720bd4ad [PATCH] switch major/minor to dev_t 2005-04-26 23:36:13 -07:00
kay.sievers@vrfy.org
1134a81b98 [PATCH] fix -Wsign-compare warnings 2005-04-26 23:24:19 -07:00
tklauser@access.unizh.chbk
5178355672 [PATCH] I tried to compile udev 050plus with the GCC 4.0 snapshot 200412119 and 2005-04-26 23:21:58 -07:00
kay.sievers@vrfy.org
4be25ce1d0 [PATCH] add class specific files for class/spi_transport and class/spi_host 2005-04-26 23:13:48 -07:00
kay.sievers@vrfy.org
5ce120d366 [PATCH] prevent udev node creatinon for "class" registration
I've found a /dev/video4linux node and just realized, that libsysfs
searches all subdirs for an attribute name.
So it found /class/video4linux/video0/dev for the videodev class
creation event /class/video4linux and created a node.

Just ignore the SUBSYSTEM="class" events now.
2005-04-26 23:13:47 -07:00
kay.sievers@vrfy.org
0dfbe9451b [PATCH] add a class/fc_host file to the list of what to wait for 2005-04-26 23:13:47 -07:00
kay.sievers@vrfy.org
e1b7e62a26 [PATCH] add net/atml and class/ppdev to the wait_for_sysfs exception list 2005-04-26 23:06:10 -07:00
kay.sievers@vrfy.org
f2503c9792 [PATCH] add net/nlv* devices to the exception list 2005-04-26 23:05:03 -07:00
kay.sievers@vrfy.org
d2fe701e9c [PATCH] add "pcmcia" and "fc_transport" to the wait_for_sysfs lists 2005-04-26 23:00:29 -07:00
kay.sievers@vrfy.org
9af5bb2f8f [PATCH] rename udev_lib to udev_utils and dev_d to udev_multiplex 2005-04-26 22:44:02 -07:00
kay.sievers@vrfy.org
cc0e9bfc35 [PATCH] remove my test code 2005-04-26 22:35:00 -07:00
kay.sievers@vrfy.org
7a0643a93f [PATCH] add support for /devices-devices without any file to wait for 2005-04-26 22:30:28 -07:00
kay.sievers@vrfy.org
a4f0cc793a [PATCH] Patch from Alex Riesen <raa.lkml@gmail.com>
> I just put const's at some places. It cut down data segments, but
> increased code size.
> Overall still smaller:
> 
> -rwxr-xr-x  1 user users 50420 Nov 19 10:53 ../udev-046/udev
> -rwxr-xr-x  1 user users 49556 Nov 19 10:53 udev
>    text    data     bss     dec     hex filename
>   47245     968   22480   70693   11425 ../udev-046/udev
>   48089     104   22064   70257   11271 udev
> 
> Also, the instance of utsname in udev_lib.c is used only once.
2005-04-26 22:30:28 -07:00
kay.sievers@vrfy.org
8474ff500f [PATCH] add a bunch of busses to the list of what to wait for 2005-04-26 22:30:28 -07:00
kay.sievers@vrfy.org
4bee999405 [PATCH] add ippp and bcrypt to the exception lists of wait_for_sysfs 2005-04-26 22:27:34 -07:00
kay.sievers@vrfy.org
d402af7d71 [PATCH] don't wait for sysfs if the kernel(2.6.10-rc2) tells us what not to expect
Newer kernels will tell us if we should wait for the "device" or
the "bus" link. So don't waste the time with our lists or wait
for the timeout.
2005-04-26 22:27:34 -07:00
kay.sievers@vrfy.org
a258d159f4 [PATCH] add i2c-dev to the list of devices without a bus 2005-04-26 22:09:26 -07:00
kay.sievers@vrfy.org
56b979e00d [PATCH] Add a bunch of devices without "device" symlinks. 2005-04-26 22:09:26 -07:00