1 |
On Sunday 21 August 2011 20.26:40 Dan Johansson wrote: |
2 |
> Hi, |
3 |
> |
4 |
> I need some help with writing udev-rules for capi. |
5 |
> After playing around some I decided to ask for help here as can't really |
6 |
> get it to work. |
7 |
> |
8 |
> What I want ist the following: |
9 |
> /dev/capi20 68,0 |
10 |
> /dev/capi/capi# 191,# |
11 |
> |
12 |
> 68,0 = Major 68, Minor 0 |
13 |
> 191,# = Major 191, Minor 0 untill 31 |
14 |
> |
15 |
> If I have no udev-rule I get the following: |
16 |
> /dev/capi 68,0 |
17 |
> /dev/capi# 191,# |
18 |
> |
19 |
> with 'ATTR{dev}="68:0", NAME="capi20" ' added I only get the following: |
20 |
> /dev/capi20 191,32 |
21 |
> |
22 |
> and with 'ATTR{dev}="191:[0-9]*", NAME="capi/capi%n" ' the following: |
23 |
> /dev/capi/capi 68,0 |
24 |
> /dev/capi/capi# 191,# |
25 |
> |
26 |
> And with both '"ATTR{dev}="68:0", NAME="capi20" ' and 'ATTR{dev}="191: |
27 |
> [0-9]*", NAME="capi/capi%n" ' this: |
28 |
> /dev/capi/capi 68,0 |
29 |
> /dev/capi/capi# 191,# |
30 |
> (No change in comparison with only the 'ATTR{dev}=191:...' rule) |
31 |
> |
32 |
> And if I change the order in the rules-file: |
33 |
> /dev/capi20 191,31 |
34 |
> |
35 |
> |
36 |
> Can some udev-crack (or someone else) tell my what I am doing wrong? |
37 |
> |
38 |
> Regards, |
39 |
Hi again, |
40 |
|
41 |
I found the problem (me). The correct syntax should be: |
42 |
ATTR{dev}=="68:0", NAME="capi20" |
43 |
ATTR{dev}=="191:[0-9]*", NAME="capi/capi%n" |
44 |
|
45 |
Notice the '==' instead of '=' after ATTR{dev}. |
46 |
|
47 |
Cheers, |
48 |
-- |
49 |
Dan Johansson, <http://www.dmj.nu> |
50 |
*************************************************** |
51 |
This message is printed on 100% recycled electrons! |
52 |
*************************************************** |