From: Rusty Russell <rusty@rustcorp.com.au>
To: Andrey Borzenkov <arvidjaar@mail.ru>
Cc: greg@kroah.com, linux-kernel@vger.kernel.org
Subject: Re: module-init-tools - input devices id support
Date: Sat, 09 Aug 2003 03:20:01 +1000 [thread overview]
Message-ID: <20030808193441.510142C252@lists.samba.org> (raw)
In-Reply-To: Your message of "Sat, 02 Aug 2003 20:26:08 +0400." <200308022026.08906.arvidjaar@mail.ru>
In message <200308022026.08906.arvidjaar@mail.ru> you write:
> On Saturday 02 August 2003 03:13, Rusty Russell wrote:
> > Hi Andrey,
> >
> > For 2.6 you should not be using the maps generated by depmod.
> > You should be adding to scripts/file2alias.c, and using those aliases
> > to insert modules. This is much more flexible.
>
> well ... file2alias assumes scalar fields with "is equal" or "do not care"
> values. Input handler matching requires bit (sub-)fields matching (with
> longest filed being 512 bits). I od not see how it can be implemented using
> standard alias syntax.
Sorry for the slow response; am on holidays.
I'm confused. This is the first time I've looked at the input code,
so please bear with me.
So, you hotplug in a device that has a suspend key, and you want the
power.ko module to match it? Hmm, cool.
How about a mneumonic for each type? Like so for
drivers/input/power.c:
/* B: bus, V: Vendor, P: Product, R: Version.
* E: evbit, K: keybit, A: absbit, M: mscbit, L: ledbit,
* S: sndbit, F: ffbit. */
/*
input:B*V*P*R*E*key*K*suspend*A*M*L*S*F*
input:B*V*P*R*E*key*K*power*A*M*L*S*F*
input:B*V*P*R*E*K*power*A*M*L*S*F*
You could use "p" instead of power, but the full names are probably
better since they are clear and most drivers only seem to have a
handful from my casual grepping.
> This syntax fails even for some PCI entries already
> (while using pcimap allows for more elaborate matching)
Not in practice, at least so I was assured by Greg. Do you know of a
counter example?
I really prefer generating aliases to hold this meta-information where
possible, because it's so simple for anyone to use them.
> Can you name some current users of module.alias?
Well, noone uses it directly: it's an internal detail of modprobe.
But it's designed for the hotplug stuff. I'll eventually get around
to converting them if Greg doesn't first, because sooner or later
those map files are going to break.
Hope that clarifies!
Rusty.
--
Anyone who quotes me in their sig is an idiot. -- Rusty Russell.
next prev parent reply other threads:[~2003-08-08 19:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-01 21:29 module-init-tools - input devices id support Andrey Borzenkov
2003-08-01 23:13 ` Rusty Russell
2003-08-02 16:26 ` Andrey Borzenkov
2003-08-08 17:20 ` Rusty Russell [this message]
2003-08-08 21:07 ` Andrey Borzenkov
2003-08-15 12:08 ` Rusty Russell
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=20030808193441.510142C252@lists.samba.org \
--to=rusty@rustcorp.com.au \
--cc=arvidjaar@mail.ru \
--cc=greg@kroah.com \
--cc=linux-kernel@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