Re: [PATCH 2/2] x86/speculation: Support "Enhanced IBRS" on future CPUs

From: Alan Cox
Date: Mon Feb 19 2018 - 19:13:50 EST


On Tue, 20 Feb 2018 00:00:23 +0000
"Van De Ven, Arjan" <arjan.van.de.ven@xxxxxxxxx> wrote:

> > On Mon, 19 Feb 2018 23:42:24 +0000, "Van De Ven, Arjan" said:
> >
> > > the guest is not the problem; guests obviously will already honor if Enhanced
> > > IBRS is enumerated. The problem is mixed migration pools where the
> > hypervisor
> > > may need to decide to not pass this enumeration through to the guest.
> >
> > For bonus points: What should happen to a VM that is live migrated from one
> > hypervisor to another, and the hypervisors have different IBRS support?
>
> Doctor Doctor it hurts when I do this....
>
> Migration tends to only work between HV's that are relatively homogeneous, that's nothing new... folks who run clouds or bigger pools know this obviously.

In theory there's nothing stopping a guest getting a 'you are about to
gain/lose IBRS' message or having a new 'CPU' hotplugged and the old one
removed.

It's just that it's always been less painful to avoid the problems you
get with wild mismatches than attmept the cure. And any 'cure' goes
beyond the OS kernel into some of the managed runtimes so I'd agree with
Arjan 'don't do that'.

Alan