diff mbox

[2/2] x86: fix asm() constraint for GS selector update

Message ID 59F1B18B020000780018A1C2@prv-mh.provo.novell.com (mailing list archive)
State New, archived
Headers show

Commit Message

Jan Beulich Oct. 26, 2017, 7:57 a.m. UTC
Exception fixup code may alter the operand, which ought to be reflected
in the constraint.

Signed-off-by: Jan Beulich <jbeulich@suse.com>

Comments

Andrew Cooper Oct. 26, 2017, 11:07 a.m. UTC | #1
On 26/10/17 08:57, Jan Beulich wrote:
> Exception fixup code may alter the operand, which ought to be reflected
> in the constraint.
>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>

Hopefully this won't have caused us any real problems in the past.
diff mbox

Patch

--- a/xen/arch/x86/x86_64/mm.c
+++ b/xen/arch/x86/x86_64/mm.c
@@ -1062,7 +1062,7 @@  long do_set_segment_base(unsigned int wh
             "     jmp  1b             \n"
             ".previous                \n"
             _ASM_EXTABLE(1b, 2b)
-            : : "r" (base&0xffff) );
+            : "+r" (base) );
         break;
 
     default: