mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Linux List Kernel Mailing <linux-kernel@vger.kernel.org>,
	the arch/x86 maintainers <x86@kernel.org>
Subject: Re: [GIT pull] x86/pti for 5.3-rc1
Date: Mon, 8 Jul 2019 21:48:55 +0200 (CEST)	[thread overview]
Message-ID: <alpine.DEB.2.21.1907082146110.1961@nanos.tec.linutronix.de> (raw)
In-Reply-To: <CAHk-=whhq5RQYNKzHOLqC+gzSjmcEGNJjbC=Psc_vQaCx4TCKg@mail.gmail.com>

On Mon, 8 Jul 2019, Linus Torvalds wrote:

> On Mon, Jul 8, 2019 at 2:22 AM Thomas Gleixner <tglx@linutronix.de> wrote:
> >
> > @@ -643,9 +644,11 @@ static unsigned long ptrace_get_debugreg(struct task_struct *tsk, int n)
> >  {
> >         struct thread_struct *thread = &tsk->thread;
> >         unsigned long val = 0;
> > +       int index = n;
> >
> >         if (n < HBP_NUM) {
> > -               struct perf_event *bp = thread->ptrace_bps[n];
> > +               index = array_index_nospec(index, HBP_NUM);
> > +               struct perf_event *bp = thread->ptrace_bps[index];
> 
> This causes a new warning:
> 
>    warning: ISO C90 forbids mixed declarations and code
> 
> and I'm fixing it up in the merge as follows:

Ooops. No idea how that slipped through. Sorry!

> @@@ -633,9 -644,11 +634,10 @@@ static unsigned long ptrace_get_debugre
>   {
>         struct thread_struct *thread = &tsk->thread;
>         unsigned long val = 0;
>  -      int index = n;
> 
>         if (n < HBP_NUM) {
> -               struct perf_event *bp = thread->ptrace_bps[n];
>  -              index = array_index_nospec(index, HBP_NUM);
> ++              int index = array_index_nospec(n, HBP_NUM);
> +               struct perf_event *bp = thread->ptrace_bps[index];
> 
>                 if (bp)
>                         val = bp->hw.info.address;
> 
> Holler if I did something stupid.

Obviously correct.

Thanks for fixing it up.

       tglx



  reply	other threads:[~2019-07-08 19:49 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-08  9:05 [GIT pull] core/debugobjects " Thomas Gleixner
2019-07-08  9:05 ` [GIT pull] x86/pti " Thomas Gleixner
2019-07-08 19:24   ` Linus Torvalds
2019-07-08 19:48     ` Thomas Gleixner [this message]
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] timers/core " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] x86/entry " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] x86/cpu " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] core/rslib " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] x86/timers " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] smp/hotplug " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] x86/apic " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] x86/fpu " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08  9:05 ` [GIT pull] irq/core " Thomas Gleixner
2019-07-08 19:30   ` pr-tracker-bot
2019-07-08 19:30 ` [GIT pull] core/debugobjects " pr-tracker-bot

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=alpine.DEB.2.21.1907082146110.1961@nanos.tec.linutronix.de \
    --to=tglx@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --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

all inboxes | Powered by JetHome®