From: kay.sievers@vrfy.org Date: Mon, 28 Mar 2005 09:22:17 +0000 (+0200) Subject: [PATCH] read %s{}-sysfs values at any device in the chain X-Git-Tag: 057~21 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=98bbc835f584ed6792e895519326cc637f64f411;p=systemd [PATCH] read %s{}-sysfs values at any device in the chain --- diff --git a/test/udev-test.pl b/test/udev-test.pl index 5d7c5e5b..ed94629d 100644 --- a/test/udev-test.pl +++ b/test/udev-test.pl @@ -1222,6 +1222,15 @@ EOF exp_name => "sane", rules => < "read sysfs value from device down in the chain", + subsys => "block", + devpath => "/class/tty/ttyUSB0", + exp_name => "serial-0000:00:09.0", + rules => <path); + if (find_sysfs_attribute(NULL, parent_device, attr, temp2, sizeof(temp2)) == 0) + break; + parent_device = sysfs_get_device_parent(parent_device); + } + if (!parent_device) + break; } /* strip trailing whitespace of sysfs value */ i = strlen(temp2);