1

I am using udev version 197. I write a rule /etc/udev/rules.d/00-test.rules It's content is :

SUBSYSTEMS=="usb", ATTRS{bInterfaceClass}=="e0", ATTRS{bInterfaceSubClass}=="01", OPTIONS+="last_rule"

SUBSYSTEMS=="usb", ATTRS{bDeviceClass}=="e0", ATTRS{bDeviceSubClass}=="01", OPTIONS+="last_rule"

According to udev manual, last_rule means no other rule will execute for the underlying subsystem or device

But problem here is that, later rule is getting executed.

How am I supposed to debug it ?

But the problem here is that,

1 Answer 1

3

udev hasn't supported the "last_rule" option since version 147.

http://code.metager.de/source/xref/linux/udev/ChangeLog#1509

2
  • 1
    Ohh !! I wasn't aware of that. If the said option is not available in Udev since 148 version, how can I achieve the same goal then ?
    – SHW
    Mar 24, 2015 at 6:54
  • 1
    You can use GOTO and LABEL to achieve something similar. GOTO and LABEL doesn't work across files, so the best you could do it to have a LABEL at the end of your rules file and replace all the OPTIONS+="last_rule" with GOTO="end_of_file". Instead of being the last rule, this will make it the last rule executed within this file. Rules in other files can be executed after yours.
    – cmtm
    Mar 25, 2015 at 20:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .