linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Lutomirski <luto@amacapital.net>
To: Borislav Petkov <bp@alien8.de>
Cc: Huang Rui <ray.huang@amd.com>,
	Peter Zijlstra <a.p.zijlstra@chello.nl>,
	spg_linux_kernel@amd.com, X86 ML <x86@kernel.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [RFC PATCH] x86/delay: Do not use cpu_tss in preemptible ctxt in delay_mwaitx()
Date: Wed, 9 Mar 2016 09:56:39 -0800	[thread overview]
Message-ID: <CALCETrVGaPASf=r7Z3aSQ1aM7EmHfT1y5QBK6Gss-M=++D+wUw@mail.gmail.com> (raw)
In-Reply-To: <1457523473-3285-1-git-send-email-bp@alien8.de>

On Mar 9, 2016 3:38 AM, "Borislav Petkov" <bp@alien8.de> wrote:
>
> From: Borislav Petkov <bp@suse.de>
>
> So Andy had a good idea about using a cacheline-aligned, seldomly used
> per-cpu var as the MONITORX target but we can't use it in preemptible
> context. The first simple idea I have is to disable preemption around us
> dereffing it.

What's the actual problem?  Is it the preempt warnings and, if so,
would raw_cpu_ptr fix it?

It may pay to move it into the loop, though.

--Andy

  reply	other threads:[~2016-03-09 17:57 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-09 11:37 [RFC PATCH] x86/delay: Do not use cpu_tss in preemptible ctxt in delay_mwaitx() Borislav Petkov
2016-03-09 17:56 ` Andy Lutomirski [this message]
2016-03-09 18:10   ` Borislav Petkov
2016-03-09 20:56     ` [PATCH] x86/delay: Avoid preemptible context checks " Borislav Petkov
2016-03-10 11:07       ` [tip:x86/urgent] " tip-bot for Borislav Petkov

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='CALCETrVGaPASf=r7Z3aSQ1aM7EmHfT1y5QBK6Gss-M=++D+wUw@mail.gmail.com' \
    --to=luto@amacapital.net \
    --cc=a.p.zijlstra@chello.nl \
    --cc=bp@alien8.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ray.huang@amd.com \
    --cc=spg_linux_kernel@amd.com \
    --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).