linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Josua Dietze <digidietze@draisberghof.de>
To: linux-hotplug@vger.kernel.org
Subject: Udev rule $attr substitution
Date: Tue, 21 Dec 2010 18:47:27 +0000	[thread overview]
Message-ID: <4D10F63F.9030005@draisberghof.de> (raw)

Hi, everyone!

I'm scratching my head over this:

Rule line:
KERNEL="ttyUSB*" RUN+="myprog %p %s{idVendor} %s{idProduct}"

%p expands to something like:
/devices/pci0000:00/0000:00:1d.7/usb1/1-5/1-5:1.2/ttyUSB2/tty/ttyUSB2

But the %s (or $attr) format string will not be substituted with anything when 
using udev version 157. The same rule works fine with version 125.

When doing the attribute walk with "udevadm info", the attributes are of course 
found in the parent chain.

Did I miss something?

             reply	other threads:[~2010-12-21 18:47 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-21 18:47 Josua Dietze [this message]
2010-12-21 20:25 ` Udev rule $attr substitution Josua Dietze
2010-12-22  8:51 ` Martin Pitt
2010-12-22 11:35 ` Josua Dietze
2010-12-22 15:58 ` Martin Pitt
2010-12-22 17:40 ` Josua Dietze
2010-12-22 17:46 ` Kay Sievers
2010-12-26 14:59 ` Kay Sievers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4D10F63F.9030005@draisberghof.de \
    --to=digidietze@draisberghof.de \
    --cc=linux-hotplug@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).