On Mon, Jul 27, 2020 at 02:29:08PM +0530, Aneesh Kumar K.V wrote: > This adds a kernel command line option that can be used to disable GTSE > support. > Disabling GTSE implies kernel will make hcalls to invalidate TLB entries. > > This was done so that we can do VM migration between configs that > enable/disable > GTSE support via hypervisor. To migrate a VM from a system that supports > GTSE to a system that doesn't, we can boot the guest with > radix_hcall_invalidate=on, thereby forcing the guest to use hcalls for TLB > invalidates. > > The check for hcall availability is done in pSeries_setup_arch so that > the panic message appears on the console. This should only happen on > a hypervisor that doesn't force the guest to hash translation even > though it can't handle the radix GTSE=0 request via CAS. With > radix_hcall_invalidate=on if the hypervisor doesn't support > hcall_rpt_invalidate > hcall it should force the LPAR to hash translation. > > Signed-off-by: Aneesh Kumar K.V <aneesh.ku...@linux.ibm.com>
Tested 1. radix_hcall_invalidate=on with KVM implementation of H_RPT_INVALIDATE hcall, the tlb flush calls get off-loaded to the hcall. 2. radix_hcall_invalidate=on w/o H_RPT_INVALIDATE hcall, the guest kernel panics as per design. Tested-by: Bharata B Rao <bhar...@linux.ibm.com>