All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Vrabel <david.vrabel@citrix.com>
To: Jan Beulich <JBeulich@suse.com>
Cc: <boris.ostrovsky@oracle.com>, <xen-devel@lists.xenproject.org>,
	<konrad.wilk@oracle.com>, <srostedt@redhat.com>,
	<linux-kernel@vger.kernel.org>
Subject: Re: [Xen-devel] [PATCH] x86/xen: Fix 32-bit PV guests's usage of kernel_stack
Date: Wed, 9 Apr 2014 15:29:07 +0100	[thread overview]
Message-ID: <53455933.2060406@citrix.com> (raw)
In-Reply-To: <5345739202000078000073EA@nat28.tlf.novell.com>

On 09/04/14 15:21, Jan Beulich wrote:
>>>> On 09.04.14 at 16:06, <boris.ostrovsky@oracle.com> wrote:
>> --- a/arch/x86/xen/xen-asm_32.S
>> +++ b/arch/x86/xen/xen-asm_32.S
>> @@ -88,7 +88,11 @@ ENTRY(xen_iret)
>>  	 * avoid having to reload %fs
>>  	 */
>>  #ifdef CONFIG_SMP
>> +	pushw %fs
>> +	movl $(__KERNEL_PERCPU), %eax
>> +	movl %eax, %fs
>>  	GET_THREAD_INFO(%eax)
>> +	popw %fs
> 
> I don't think it's guaranteed that this can't fault.

If loading %fs faults when it is restored previously, the fixup zeros
the value.  However, this later load could still fault even if the first
succeeded.

Suggest copying the fixup section from the RESTORE_REGS macros in
arch/x86/kernel/entry_32.S

David

  reply	other threads:[~2014-04-09 14:29 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-09 14:06 [PATCH] x86/xen: Fix 32-bit PV guests's usage of kernel_stack Boris Ostrovsky
2014-04-09 14:08 ` David Vrabel
2014-04-09 14:08 ` David Vrabel
2014-04-09 14:21 ` [Xen-devel] " Jan Beulich
2014-04-09 14:29   ` David Vrabel [this message]
2014-04-09 14:41     ` Andrew Cooper
2014-04-09 14:41     ` [Xen-devel] " Andrew Cooper
2014-04-09 15:01       ` Jan Beulich
2014-04-09 15:38         ` Boris Ostrovsky
2014-04-09 15:38         ` [Xen-devel] " Boris Ostrovsky
2014-04-09 15:40           ` Jan Beulich
2014-04-09 15:40           ` [Xen-devel] " Jan Beulich
2014-04-09 15:01       ` Jan Beulich
2014-04-09 14:29   ` David Vrabel
2014-04-09 14:21 ` Jan Beulich
2014-04-09 15:25 ` Steven Rostedt
2014-04-09 15:25 ` Steven Rostedt
2014-04-09 16:15   ` Boris Ostrovsky
2014-04-09 16:15   ` Boris Ostrovsky

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=53455933.2060406@citrix.com \
    --to=david.vrabel@citrix.com \
    --cc=JBeulich@suse.com \
    --cc=boris.ostrovsky@oracle.com \
    --cc=konrad.wilk@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=srostedt@redhat.com \
    --cc=xen-devel@lists.xenproject.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.