Re: [Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-26 Thread Andrew Cooper
On 26/06/18 10:57, Jan Beulich wrote: > >>> +_p(regs->rip), _p(regs->rip), _p(fixup)); >>> +/* >>> + * We mustn't come here, but for release builds have the recovery >> "We shouldn't be able to reach here..." > Well, okay - I did consider this weaker wording, but had

Re: [Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 11:41, wrote: > On 26/06/18 07:36, Jan Beulich wrote: >> --- a/xen/arch/x86/traps.c >> +++ b/xen/arch/x86/traps.c >> @@ -1749,7 +1749,21 @@ void do_device_not_available(struct cpu_ >> { >> struct vcpu *curr = current; >> >> -BUG_ON(!guest_mode(regs)); >> +if ( !g

Re: [Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-26 Thread Andrew Cooper
On 26/06/18 07:36, Jan Beulich wrote: > Just in case we still don't get CR0.TS handling right, prevent a host > crash by honoring exception fixups in do_device_not_available(). This > would in particular cover emulator stubs raising #NM. > > Signed-off-by: Jan Beulich > --- > v2: Add ASSERT_UNREAC

[Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-25 Thread Jan Beulich
Just in case we still don't get CR0.TS handling right, prevent a host crash by honoring exception fixups in do_device_not_available(). This would in particular cover emulator stubs raising #NM. Signed-off-by: Jan Beulich --- v2: Add ASSERT_UNREACHABLE(). --- a/xen/arch/x86/traps.c +++ b/xen/arch