summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2005-04-26[PATCH] libsysfs 0.4.0 patchdsteklof@us.ibm.com
Ananth released sysfsutils 0.4.0 last night, I'm sure you saw the email. Here's a patch with the latest changes from the pre-patch I already gave you. It includes sysfs_get_device_parent(), which you said you needed. I've run your test scripts and I've built scsi_id. Please play around with this and check it out. There are quite a few changes. Please do not access structure pointers, like sysfs_device's parent, directly like dev->parent. Please use the "get" function to retrieve. The functions load things on demand and refresh views under the covers.
2005-04-26[PATCH] don't overwrite old config on installkay.sievers@vrfy.org
Here is a patch for the Makefile to look for a already installed config and not to overwrite it.
2005-04-26[PATCH] udev-remove.c cleanupskay.sievers@vrfy.org
I've moved the malloc out of the udevdb into udev-remove to free the struct after use and not to allocate a different struct in the case the device is not in the data base. I seems a bit easier to read.
2005-04-26[PATCH] remove unneeded TODO and FIXME entrygreg@kroah.com
Thanks to Kay for pointing it out to me.
2005-04-26[PATCH] clean up the stand-alone tests to work properly on other people's ↵greg@kroah.com
machines.
2005-04-26[PATCH] bug in udev-remove.ckay.sievers@vrfy.org
Uups, we have a bug in udev-remove.c. udev segfaults with NULL-pointer, if the device is not in the database: ./test.block: line 29: 4844 Segmentation fault $BIN block Dec 17 22:47:42 pim udev[4882]: udev_remove_device: '/block/sdy' not found in database, falling back on default name Dec 17 22:47:42 pim udev[4882]: udev_remove_device: name is '(null)'
2005-04-26[PATCH] fix scsi_id segfault with udev-009dsteklof@us.ibm.com
Scsi_id hasn't been changed to use the latest libsysfs changes. The "directory" in the sysfs_class_device is now considered "private" and only should be accessed using functions. Treating the structures as handles lets us only load information when it's needed, reducing caching or stale information and also helping performance. Here's the problem. static inline char *sysfs_get_attr(struct sysfs_class_device *dev, const char *attr) { return sysfs_get_value_from_attributes(dev->directory->attributes, attr); } Please try this quick fix:
2005-04-26[PATCH] add libsysfs docsdsteklof@us.ibm.com
Here's the latest libsysfs doc, you may want to include it in your docs directory.
2005-04-26[PATCH] Allow build with empty EXTRASakropel1@rochester.rr.com
Need to let the shell expand $EXTRAS so it can properly detect an empty list. Without this patch, the build fails whenever $EXTRAS is empty.
2005-04-26[PATCH] add tests to catch whitespace and comment config file parsing errors.greg@kroah.com
2005-04-26[PATCH] fix comment and whitespace handling in config files.Roman.Kagan@itep.ru
This chunk broke parsing of blank lines and comments with blanks before '#'. Please revert it with the patch below. Roman.
2005-04-26[PATCH] mark config files as such in the rpm spec filedhollis@davehollis.com
Got a nasty surprise after upgrading my RPM. The config files weren't marked as configs and were subsequently replaced! DOH! Fortunately, I didn't have much in there yet but that certainly isn't something others will like going forward. Attached is a simple patch to the spec file so they aren't replaced in the future. The config files included in the RPM should wind up as udev.conf.rpmnew, etc if they are different from what is installed.
2005-04-26[PATCH] trivial cleanup parser changeskay.sievers@vrfy.org
o use defines in debug strings o replace my 'xxx' debug :) o shorten line in man page example to not to exceed 80 chars when printed
2005-04-26[PATCH] 009_bk makefile changes.greg@kroah.com
2005-04-26[PATCH] v009 releaseudev/v009greg@kroah.com
2005-04-26[PATCH] signal fixes due to klibc update.greg@kroah.com
2005-04-26[PATCH] sync klibc with release 0.95greg@kroah.com
2005-04-26[PATCH] add mol permissions to the debian permissions file.greg@kroah.com
Info from Mathieu Segaud <matt@minas-morgul.org>
2005-04-26[PATCH] update the FAQ with info about bad modprobe events from the devfs ↵greg@kroah.com
scheme...
2005-04-26[PATCH] dump latest klibc into the udev build treeolh@suse.de
KLIBC is used as an internal makefile variable, it expands to either true or false right now. udev should use something else than KLIBC to allow build against the latest and greatest klibc version.
2005-04-26[PATCH] some cleanups due to the need for LABEL rules to use "SYSFS_" now.greg@kroah.com
2005-04-26[PATCH] don't rely on field order in namedev_parsekay.sievers@vrfy.org
o change the parsing to get a key from the rule and sort it into our list of known keys instead of expecting a special order o the key to match a sysfs file must be prependend by 'SYSFS_' now to match with the new parsing. (The config must be changed, but it's a bit more descriptive too.) o put names of fields in define's, like the name of the methods o update all tests and the man page
2005-04-26[PATCH] remove udev from runlevels on uninstallrml@ximian.com
I guess we should run 'chkconfig --del udev' on removal to clear out the now-stale udev entries, if any.
2005-04-26[PATCH] install initscript in udev rpmrml@ximian.com
Attached patch installs the initscript via 'make install' and adds it to the RPM package. The RPM script then runs chkconfig(8) to setup the initscript to run at the appropriate runlevels.
2005-04-26[PATCH] more extras/multipath changeschristophe.varoqui@free.fr
* Make the HW-specific get_unique_id switch pretty * Prepare to field-test by whitelisting all known fibre array, try to fetch WWID from the standard EVPD 0x83 off 8 for everyone ... we will learn from feedback :) Could you drop a note with the udev-009 release-notes asking for testing this WWID fetching thing ?
2005-04-26[PATCH] get part of callout return stringkay.sievers@vrfy.org
Try this patch if you like, to get special parts of the callout output. This beast works now: CALLOUT, BUS="scsi", PROGRAM="/bin/echo -n node link1 link2", ID="node *", NAME="%1c", SYMLINK="%2c %3c" The callout returned string is separated by spaces and is addressed by the "len" value of the 'c' format char. Since we support symlinks, this my be useful for other uses of callout too. introduce 'len number' for format chars the first use is 'c'-the callout return to select a part of the output string like: CALLOUT, BUS="scsi", PROGRAM="/bin/echo -n node link1 link2", ID="node *", NAME="%1c", SYMLINK="%2c %3c" (note: first part is requested by len=1, len=0 will return the whole string) add a test to udev-test.pl
2005-04-26[PATCH] remove '\n' from end of callout returnkay.sievers@vrfy.org
remove possible newline at end of callout output, for easier matching with ID=
2005-04-26[PATCH] Add restart target to the etc/init.d/udev scriptgreg@kroah.com
Change made by Rolf Eike Beer <eike-hotplug@sf-tec.de>
2005-04-26[PATCH] add init.d/udev to "make install"eike-hotplug@sf-tec.de
adds /etc/init.d/udev to "make install"
2005-04-26[PATCH] add init.d/udev to the spec fileeike-hotplug@sf-tec.de
add /etc/init.d/udev to the SPEC-File and this way to the RPM
2005-04-26[PATCH] pre-libsysfs-0.4.0 patchdsteklof@us.ibm.com
I am sending you a pre-release patch. It's everything that's in our current CVS tree. It adds the functionality you've been looking for. Please play with this before checking it into your tree, I'd like to know if it's ok with you or if you find problems. I have tested this out with test.all and the perl regression test. Let me know what you think. Still need to do more testing for our work and add some more functions related to the changes. I've gone into namedev.c and udev-add.c to make the necessary changes in line with the library. I have not gone and edited any of the "extras". Changes: 1) Libsysfs object structures work more as handles now, their included directories or devices are labeled private. If you need attributes from a sysfs_class_device, call the available function and don't access the directory directly. Same holds true for a sysfs_class_device sysfs_device. Do not access the link directly but call the function sysfs_get_classdev_device() instead. We only populate entries upon request, makes things faster and uses less memory. 2) Added sysfs_get_classdev_parent() as requested. 3) Changed getpagesize to sysconf. 4) Added sysfs_refresh_attributes function for refreshing views of attribute lists. We still need to add refresh for links and subdirs. All udev needs to do is keep calling sysfs_get_classdev_attr() and that will internally call the refresh routine.
2005-04-26[PATCH] tweak the config file generation portion of the Makefile a bit.greg@kroah.com
2005-04-26[PATCH] use udevdir in udev.confolh@suse.de
udevdir is a define, but udev.conf has a hardcoded path. Maybe this config file should be generated on the fly, like shown below.
2005-04-26[PATCH] change devfs disk name rule from 'disk' to 'disc'greg@kroah.com
2005-04-26[PATCH] man-page mention multiple symlinkskay.sievers@vrfy.org
As usual, when the stuff gets in the tree - here is a small man page update and a TODO line removal. mention multiple symlinks update example with silly symlink rule :) shorten example line to have less than 80 chars remove "want symlink support" from TODO
2005-04-26[PATCH] add vc support to udev.rules.devfsgreg@kroah.com
2005-04-26[PATCH] added a devfs udev config file from Marco d'Itri <md@Linux.IT>greg@kroah.com
2005-04-26[PATCH] set default mode to 0600 to be safer.greg@kroah.com
2005-04-26[PATCH] Makefile tweaks for the DBUS build.greg@kroah.com
2005-04-26[PATCH] and more extras/multipath updateschristophe.varoqui@free.fr
* configure the multipath target with round-robin path selector and conservative default for a start : yes it makes this release the first really useful one. * temporarily disable map creation for single path device due to current restrictive defaults in the kernel target. Sistina should work it out. * correct the strncmp logic in blacklist function. Tested on StorageWorks with 2.6.0-test10-udm1 : xa-s03:~# ./multipath -v 60001fe1000bdad0000903507109004b (1 0 1 1) /dev/sda op:1 /dev/sda [HSG80 ] 60001fe1000bdad000090371312100bf (1 0 1 2) /dev/sdb op:1 /dev/sdb [HSG80 ] 60001fe1000bdad000090371312100c2 (1 0 1 3) /dev/sdc op:1 /dev/sdc [HSG80 ] 60001fe1000bdad00009037131210067 (1 0 2 1) /dev/sdd op:1 /dev/sdd [HSG80 ] 60001fe1000bdad000090371312100b3 (1 0 2 2) /dev/sde op:1 /dev/sde [HSG80 ] 60001fe1000bdad00009035071090024 (1 0 2 3) /dev/sdf op:1 /dev/sdf [HSG80 ] 600508b4000156d700012000000b0000 (1 0 3 1) /dev/sdg op:1 /dev/sdg [HSV110 (C)COMPAQ] 600508b4000156c30001200000210000 (1 0 3 2) /dev/sdh op:1 /dev/sdh [HSV110 (C)COMPAQ] 600508b4000156d700012000000b0000 (1 0 6 1) /dev/sdi op:1 /dev/sdi [HSV110 (C)COMPAQ] 600508b4000156c30001200000210000 (1 0 6 2) /dev/sdj op:1 /dev/sdj [HSV110 (C)COMPAQ] 60001fe1000bdad0000903507109004b \_(1 0 1 1) /dev/sda op:1 /dev/sda [HSG80 ] 60001fe1000bdad000090371312100bf \_(1 0 1 2) /dev/sdb op:1 /dev/sdb [HSG80 ] 60001fe1000bdad000090371312100c2 \_(1 0 1 3) /dev/sdc op:1 /dev/sdc [HSG80 ] 60001fe1000bdad00009037131210067 \_(1 0 2 1) /dev/sdd op:1 /dev/sdd [HSG80 ] 60001fe1000bdad000090371312100b3 \_(1 0 2 2) /dev/sde op:1 /dev/sde [HSG80 ] 60001fe1000bdad00009035071090024 \_(1 0 2 3) /dev/sdf op:1 /dev/sdf [HSG80 ] 600508b4000156d700012000000b0000 \_(1 0 3 1) /dev/sdg op:1 /dev/sdg [HSV110 (C)COMPAQ] \_(1 0 6 1) /dev/sdi op:1 /dev/sdi [HSV110 (C)COMPAQ] 600508b4000156c30001200000210000 \_(1 0 3 2) /dev/sdh op:1 /dev/sdh [HSV110 (C)COMPAQ] \_(1 0 6 2) /dev/sdj op:1 /dev/sdj [HSV110 (C)COMPAQ] N|600508b4000156d700012000000b0000 : 0 4194304 multipath 2 2 10 round-robin 2 /dev/sdg 10 2 1 2 /dev/sdi 10 2 1 2 N|600508b4000156c30001200000210000 : 0 20971520 multipath 2 2 10 round-robin 2 /dev/sdh 10 2 1 2 /dev/sdj 10 2 1 2 xa-s03:~# dmsetup ls 600508b4000156c30001200000210000 (254, 1) 600508b4000156d700012000000b0000 (254, 0) xa-s03:~# ll /dev/mapper/ total 0 brw------- 1 root root 254, 1 Dec 9 22:57 600508b4000156c30001200000210000 brw------- 1 root root 254, 0 Dec 9 22:57 600508b4000156d700012000000b0000 crw------- 1 root root 10, 63 Jul 25 22:48 control xa-s03:~# dd if=/dev/mapper/600508b4000156c30001200000210000 of=/dev/null bs=1M count=500 500+0 records in 500+0 records out 524288000 bytes transferred in 5.662530 seconds (92589003 bytes/sec) gee, that pretty fast :)
2005-04-26[PATCH] more extras/multipath updateschristophe.varoqui@free.fr
* update the Makefiles to autodetect libgcc.a & gcc includes "ulibc-style". Factorisation of udevdirs & others niceties * drop a hint about absent /dev/sd? on failed open() for poor Debian users who don't imagine their favorite distro with only 16 preconfigured SCSI device nodes :)
2005-04-26[PATCH] allow multiple symlinkskay.sievers@vrfy.org
Here is a patch to allow the creation of multiple symlinks. The names must be separated by a space character. REPLACE, KERNEL="ttyUSB0", NAME="visor", SYMLINK="first-%n second-%n third-%n" results in: Dec 9 05:28:51 pim udev[12019]: create_node: mknod(udev-root/visor, 020666, 188, 0) Dec 9 05:28:51 pim udev[12019]: create_node: symlink 'udev-root/first-0' to node 'visor' requested Dec 9 05:28:51 pim udev[12019]: create_node: symlink(./visor, udev-root/first-0) Dec 9 05:28:51 pim udev[12019]: create_node: symlink 'udev-root/second-0' to node 'visor' requested Dec 9 05:28:51 pim udev[12019]: create_node: symlink(./visor, udev-root/second-0) Dec 9 05:28:51 pim udev[12019]: create_node: symlink 'udev-root/third-0' to node 'visor' requested Dec 9 05:28:51 pim udev[12019]: create_node: symlink(./visor, udev-root/third-0)
2005-04-26[PATCH] update the FAQ due to the latest devfs mess on lkml and also due to ↵greg@kroah.com
symlinks now working.
2005-04-26[PATCH] cleanup man & remove symlink commentkay.sievers@vrfy.org
remove "want symlinks" text from udev-add.c mention SYMLINK in man page man page format cleanup man page example for SYMLINK
2005-04-26[PATCH] document the different Makefile config options that we have.greg@kroah.com
2005-04-26[PATCH] change USE_DBUS to DBUS in Makefile, and disable it by default as ↵greg@kroah.com
it's still to hard to build on all systems.
2005-04-26[PATCH] fix formatting of udev_dbus.c to use tabs. Also get it to build ↵greg@kroah.com
properly now.
2005-04-26[PATCH] move all of the DBUS logic into one file and remove all of the ↵greg@kroah.com
#ifdef crud from the main code.
2005-04-26[PATCH] D-BUS patch for udev-008david@fubar.dk
Attached is a patch against udev-008 to send out a D-BUS message when a device node is added or removed. Using D-BUS lingo, udev acquires the org.kernel.udev service and sends out a NodeCreated or NodeDeleted signal on the org.kernel.udev.NodeMonitor interface. Each signal carries two parameters: the node in question and the corresponding sysfs path. [Note: the D-BUS concepts of service, interface, object can be a bit confusing at first glance] An example program listening for these messages looks like this #!/usr/bin/python import dbus import gtk def udev_signal_received(dbus_iface, member, service, object_path, message): [filename, sysfs_path] = message.get_args_list() if member=='NodeCreated': print 'Node %s created for %s'%(filename, sysfs_path) elif member=='NodeDeleted': print 'Node %s deleted for %s'%(filename, sysfs_path) def main(): bus = dbus.Bus(dbus.Bus.TYPE_SYSTEM) bus.add_signal_receiver(udev_signal_received, 'org.kernel.udev.NodeMonitor', # interface 'org.kernel.udev', # service '/org/kernel/udev/NodeMonitor') # object gtk.mainloop() if __name__ == '__main__': main() and this is the output when hot-plugging some usb-storage. [david@laptop udev-008]$ ~/node_monitor.py Node /udev/sda created for /block/sda Node /udev/sda1 created for /block/sda/sda1 Node /udev/sda1 deleted for /block/sda/sda1 Node /udev/sda deleted for /block/sda The patch requires D-BUS 0.20 or later while the python example program requires D-BUS from CVS as I only recently applied a patch against the python bindings.
2005-04-26[PATCH] experimental (very simple) SYMLINK creationkay.sievers@vrfy.org
> > here is a experimental symlink creation patch - for discussion, > > in which direction we should go. > > It is possible now to define SYMLINK= after the NAME= in udev.rules. > > The link is relative to the node, but the path is not optimized now > > if the node and the link are in the same nested directory. > > Only one link is supported, cause i need to sleep now :) > > > > 06-simple-symlink-creation.diff > > simple symlink creation > > reorganized udev-remove to have access to the symlink field > > subdir creation/removal are functions now > > udev-test.pl tests for link creation/removal Here is a new version with relative link target path optimization an better tests in udev-test.pl: LABEL, BUS="scsi", vendor="IBM-ESXS", NAME="1/2/a/b/node", SYMLINK="1/2/c/d/symlink" Dec 7 06:48:34 pim udev[13789]: create_node: symlink 'udev-root/1/2/c/d/symlink' to node '1/2/a/b/node' requested Dec 7 06:48:34 pim udev[13789]: create_path: created 'udev-root/1/2/c' Dec 7 06:48:34 pim udev[13789]: create_path: created 'udev-root/1/2/c/d' Dec 7 06:48:34 pim udev[13789]: create_node: symlink(../../a/b/node, udev-root/1/2/c/d/symlink)