[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKgNAkiVxUiqJ1pYNq3wW_yQxcyhqntUzcEWscFOhJ3GaVn1aQ@mail.gmail.com>
Date: Thu, 18 Oct 2012 14:59:46 +0200
From: "Michael Kerrisk (man-pages)" <mtk.manpages@...il.com>
To: Rusty Russell <rusty@...tcorp.com.au>
Cc: "H. Peter Anvin" <hpa@...or.com>,
Kees Cook <keescook@...omium.org>,
linux-kernel@...r.kernel.org,
Lucas De Marchi <lucas.demarchi@...fusion.mobi>,
jonathon@...masters.org
Subject: Re: [PATCH 1/4] module: add syscall to load module from fd
On Thu, Oct 18, 2012 at 5:12 AM, Rusty Russell <rusty@...tcorp.com.au> wrote:
> "Michael Kerrisk (man-pages)" <mtk.manpages@...il.com> writes:
>> Sure. But my point that started this subthread was: should we take the
>> opportunity now to add a 'flags' argument to the new finit_module()
>> system call, so as to allow flexibility in extending the behavior in
>> future? There have been so many cases of revised system calls in the
>> past few years that replaced calls without a 'flags' argument that it
>> seems worth at least some thought before the API is cast in stone.
>
> (CC's trimmed, Lucas & Jon added; please include them in module
> discussions!)
>
> So I tried to think of why we'd want flags; if I could think of a
> plausible reason, obviously we should do it now.
>
> I think it would be neat for the force flags (eg. ignoring modversions
> or ignoring kernel version). These are the only cases where libkmod
> needs to mangle the module.
>
> So here's the patch which adds the flags field, but nothing in there
> yet. I'll add the remove flags soon, so libkmod can assume that if the
> syscall exists, those flags will work.
>
> Thoughts?
> Rusty.
>
> FIX: add flags arg to sys_finit_module()
>
> Thanks to Michael Kerrisk for keeping us honest.
w00t! Thanks, Rusty ;-).
Acked-by: Michael Kerrisk <mtk.manpages@...il.com>
> + if (flags)
> + return -EINVAL;
And thanks for that check. So easy, so obvious, and so often forgotten.
Cheers,
Michael
--
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Author of "The Linux Programming Interface"; http://man7.org/tlpi/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists