linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jann Horn <jannh@google.com>
To: "Tautschnig, Michael" <tautschn@amazon.co.uk>
Cc: "x86@kernel.org" <x86@kernel.org>,
	"linux-api@vger.kernel.org" <linux-api@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
	Jaswinder Singh <jaswinder@infradead.org>,
	Andi Kleen <ak@linux.intel.com>
Subject: Re: [PATCH] x86: always use SYSCALL_DEFINE*
Date: Tue, 13 Mar 2018 14:16:01 -0700	[thread overview]
Message-ID: <CAG48ez1RBhBbH8jHwseeZMQwdKciLdjYhoy3O9yDs8WEpMk2TQ@mail.gmail.com> (raw)
In-Reply-To: <14A5C8D0-3F9D-486F-A20C-55849D70FC80@amazon.com>

On Sat, Mar 10, 2018 at 12:55 PM, Tautschnig, Michael
<tautschn@amazon.co.uk> wrote:
> All syscall arguments are passed in as types of the same byte size as
> unsigned long (width of full registers). Using a smaller type without a
> cast may result in losing bits of information. SYSCALL_DEFINE* introduce
> adequate type casts. All definitions of syscalls in x86 except for those
> patched here have already been using the appropriate SYSCALL_DEFINE*.
[...]
> diff --git a/arch/x86/kernel/ioport.c b/arch/x86/kernel/ioport.c
> index 2f72330..d98b2a3 100644
> --- a/arch/x86/kernel/ioport.c
> +++ b/arch/x86/kernel/ioport.c
> @@ -23,7 +23,8 @@
>  /*
>   * this changes the io permissions bitmap in the current task.
>   */
> -asmlinkage long sys_ioperm(unsigned long from, unsigned long num, int turn_on)
> +SYSCALL_DEFINE3(sys_ioperm, unsigned long, from, unsigned long, num, int,
> +               turn_on)

Shouldn't this be "SYSCALL_DEFINE3(ioperm, [...]", without the "sys_"?

  parent reply	other threads:[~2018-03-13 21:16 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-10 20:55 [PATCH] x86: always use SYSCALL_DEFINE* Tautschnig, Michael
2018-03-10 20:59 ` Tautschnig, Michael
2018-03-11  9:43 ` [PATCH v2] " Tautschnig, Michael
2018-03-13 21:16 ` Jann Horn [this message]
2018-03-13 23:18   ` [PATCH] " Andy Lutomirski
2018-03-14  5:48     ` Dominik Brodowski
2018-03-14  9:43       ` Tautschnig, Michael

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=CAG48ez1RBhBbH8jHwseeZMQwdKciLdjYhoy3O9yDs8WEpMk2TQ@mail.gmail.com \
    --to=jannh@google.com \
    --cc=ak@linux.intel.com \
    --cc=hpa@zytor.com \
    --cc=jaswinder@infradead.org \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=tautschn@amazon.co.uk \
    --cc=tglx@linutronix.de \
    --cc=x86@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;
as well as URLs for NNTP newsgroup(s).