On Thu, Mar 14, 2013 at 7:54 AM, Alberto Milone
<alberto.mil...@canonical.com> wrote:
> On 14/03/13 03:39, Lucas De Marchi wrote:
>> Hi Alberto
>>
>> First of all, please inline your patch next time, so we can comment on it.
>>
>
> Sorry about that.
>
>> On Wed, Mar 13, 2013 at 1:15 PM, Alberto Milone
>> <alberto.mil...@canonical.com> wrote:
>>> Hi all,
>>>
>>> I think the problem is that modprobe looks for the module (which in this
>>> case is aliased as "off") in /sys and raises an error if it doesn't find
>>> it (there's no such thing as an "off" module in /sys).
>>>
>>> In the attached patch I check that the module name is not "off" or
>>> "null" before doing assert(kmod_module_get_initstate(m) ==
>>> KMOD_MODULE_BUILTIN).
>>
>> Why is "off" and "null" special?
>>
>
> Let me quote this page:
> http://ccrma.stanford.edu/planetccrma/man/man5/modules.conf.5.html
>
>
> "Note that the line:
>
> alias some_module off
>
> will make modprobe ignore requests to load that module.
>
> Another special alias is:
>
> alias some_module null
>
> which  will make requests for some_module always succeed, but no module
> will actually be installed.  This can be used as  a  base for stacks
> created via the above and below directives."

Do you realize you are quoting the man page of modutils?  It's not
kmod or module-init-tools, which kmod replaced. It's the old modutils
used with Linux 2.4.  kmod is a drop-in replacement to m-i-t, but we
are not putting back the things from modutils if we don't have a
reason to.

>
>>
>>>
>>> This solves the problem on my systems.
>>
>> What are you solving that is not solved by putting /bin/true or
>> blacklisting the module?
>
> As you can see, "blacklist" is different from "off". Furthermore udev
> ignores blacklist but honours "off".

udev uses "kmod_module_probe_insert_module(mod,
KMOD_PROBE_APPLY_BLACKLIST, ...)" - which is the same of calling
modprobe with "-b" option. So, it does hounours the blacklist.

>
> And, as I said, the problem is that we cannot get the initstate (
> /sys/module/$module_name/initstate ) of "off" or "null" because they are


Why do you want to get the initstate of an inexistent module? Why do
you think null and off should be special?  And more important, you
still didn't answer why the available options are not working for you
- you said you cannot get the initstate - but that is a non-issue
since  libkmod shouldn't even try to get the initstate.


> not real modules and using "/bin/true" as the installation command (if
> this is what you're suggesting) won't solve the problem.

Please give some real example of what you are trying to do so we can
figure out a solution.

Lucas De Marchi


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to