diff options
author | kay.sievers@vrfy.org <kay.sievers@vrfy.org> | 2004-01-19 19:46:26 -0800 |
---|---|---|
committer | Greg KH <gregkh@suse.de> | 2005-04-26 21:13:17 -0700 |
commit | be9b51f6638d66025ebde1ca154ae9180383409c (patch) | |
tree | 86b66fd8da31c21c63d27fde454af1c5a33d1253 /extras/udevinfo/Makefile | |
parent | 765cbd97599d943adc73d03f4c91bd7cf7ef7fab (diff) |
[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"
Diffstat (limited to 'extras/udevinfo/Makefile')
-rw-r--r-- | extras/udevinfo/Makefile | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/extras/udevinfo/Makefile b/extras/udevinfo/Makefile new file mode 100644 index 0000000000..f31c8c11e9 --- /dev/null +++ b/extras/udevinfo/Makefile @@ -0,0 +1,14 @@ +PROG=udevinfo +LD=$(CC) +OBJS=udevinfo.o + +all: $(PROG) + +clean: + rm -f $(PROG) $(OBJS) + +$(PROG): $(OBJS) + $(LD) $(LDFLAGS) -o $(PROG) $(CRT0) $(OBJS) $(SYSFS) + +me: + cd ../..; make EXTRAS=extras/udevinfo |