On Fri, Apr 08, 2016 at 05:54:11PM +0200, Thomas Huth wrote: > The SIAR register is available twice, one time as SPR 780 (unprivileged, > but read-only), and one time as SPR 796 (privileged, but read and write). > The Linux kernel code currently uses SPR 780 - and while this is OK for > reading, writing to that register of course does not work. > Since the KVM code tries to write to this register, too (see the mtspr > in book3s_hv_rmhandlers.S), the contents of this register sometimes get > lost for the guests, e.g. during migration of a VM. > To fix this issue, simply switch to the other SPR numer 796 instead. > > Signed-off-by: Thomas Huth <thuth@xxxxxxxxxx> > --- > Note: The perf code in core-book3s.c also seems to write to the SIAR > SPR, so that might be affected by this issue, too - but I did > not test the perf code, so I'm not sure about that part. EBBs mean we need to context-switch the SIAR between user tasks (among other registers). I notice that SDAR is also wrong, and the MMCR2 definition is also using the user-accessible number (though it at least is writable as well as readable). Paul. -- To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html