]> err.no Git - systemd/commit
[PATCH] udev - program to query all device attributes to build a rule
authorkay.sievers@vrfy.org <kay.sievers@vrfy.org>
Tue, 20 Jan 2004 03:46:26 +0000 (19:46 -0800)
committerGreg KH <gregkh@suse.de>
Wed, 27 Apr 2005 04:13:17 +0000 (21:13 -0700)
commitbe9b51f6638d66025ebde1ca154ae9180383409c
tree86b66fd8da31c21c63d27fde454af1c5a33d1253
parent765cbd97599d943adc73d03f4c91bd7cf7ef7fab
[PATCH] udev - program to query all device attributes to build a rule

On Sun, Jan 18, 2004 at 07:30:50AM +0100, Kay Sievers wrote:
> Hi,
> here is a small program to query all attributes of a device and
> print these in the udev key format. It may help to get the keys to
> define a rule.

Fixed a typo - the sysfs_device is right now.

USB FLash Reader:
    kay@pim:~/src/udev.kay$ extras/udevinfo/udevinfo /sys/block/sda/sda1

    device '/sys/block/sda/sda1' has major:minor 8:1

    looking at class device '/sys/block/sda/sda1':
      SYSFS_dev="8:1"
      SYSFS_start="32"
      SYSFS_size="160"
      SYSFS_stat="       0        0        0        0"

    follow class device's "device" link '/sys/block/sda':
      BUS="scsi"
      ID="57:0:0:0"
      SYSFS_detach_state="0"
      SYSFS_type="0"
      SYSFS_device_blocked="0"
      SYSFS_queue_depth="1"
      SYSFS_scsi_level="3"
      SYSFS_vendor="SMSC    "
      SYSFS_model="USB 2 HS-CF"
      SYSFS_rev="1.25"
      SYSFS_online="1"
extras/udevinfo/Makefile [new file with mode: 0644]
extras/udevinfo/udevinfo.c [new file with mode: 0644]