Re: [PATCH] libkmod-module: fix return code in error path

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Jun 14, 2015 at 7:55 AM, David Herrmann <dh.herrmann@xxxxxxxxx> wrote:
> Hi
>
> On Sat, Jun 13, 2015 at 11:45 PM, Lucas De Marchi
> <lucas.de.marchi@xxxxxxxxx> wrote:
>> From: Lucas De Marchi <lucas.demarchi@xxxxxxxxx>
>>
>> ENOSYS is the wrong errno to return when we don't find a module in
>> kmod_module_insert_module(). Why is it there in the first place?  This
>> goes back to kmod v1 when we couldn't load modules by names, but we
>> should give a path instead.
>>
>> 708624a ("ELF: initial support for modinfo and strip of modversions and
>> vermagic.") changed that so we do a lazy-search by the module path in
>> this function. Later  f304afe ("Change error message to reflect
>> reality") fixed the log message but the return coded remained the same.
>> ---
>>
>> CC'ing here people from systemd who were bitten by this bug in kmod:
>> https://github.com/systemd/systemd/pull/166
>>
>> I'm not sure about changing the return code since it was returning ENOSYS since
>> v1 :-/.  However maybe the best thing to do is just treat it as a bug and let
>> the patch to be backported by distros that want it.  Thoughts?
>
> Looks all good to me. Treating this as a bugfix is probably the best
> thing to do. I'll revert the systemd patch once this is pushed.

Applied.  The next release will take a while but I do recommend all
distros to cherry-pick this patch.


thanks.

-- 
Lucas De Marchi
--
To unsubscribe from this list: send the line "unsubscribe linux-modules" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux