Home Home > GIT Browse
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Suchanek <msuchanek@suse.de>2018-10-31 12:36:54 +0100
committerMichal Suchanek <msuchanek@suse.de>2018-10-31 23:28:39 +0100
commit233d742a11ac4ba99c86b6f8aeb8bfa235c5ad27 (patch)
tree4755a4522a976d87c2561c165a7cce2bfa706965
parent6d553d92b583a2a5dda3081daf4c077294a7e378 (diff)
KVM: PPC: Book3S: Use correct page shift in H_STUFF_TCE
(bsc#1061840).
-rw-r--r--patches.arch/KVM-PPC-Book3S-Use-correct-page-shift-in-H_STUFF_TCE.patch56
-rw-r--r--series.conf1
2 files changed, 57 insertions, 0 deletions
diff --git a/patches.arch/KVM-PPC-Book3S-Use-correct-page-shift-in-H_STUFF_TCE.patch b/patches.arch/KVM-PPC-Book3S-Use-correct-page-shift-in-H_STUFF_TCE.patch
new file mode 100644
index 0000000000..ec745f7299
--- /dev/null
+++ b/patches.arch/KVM-PPC-Book3S-Use-correct-page-shift-in-H_STUFF_TCE.patch
@@ -0,0 +1,56 @@
+From c6b61661d229e42b58d5e511191e925d105a5cce Mon Sep 17 00:00:00 2001
+From: Alexey Kardashevskiy <aik@ozlabs.ru>
+Date: Mon, 14 May 2018 20:00:27 +1000
+Subject: [PATCH] KVM: PPC: Book3S: Use correct page shift in H_STUFF_TCE
+
+References: bsc#1061840
+Patch-mainline: v4.18-rc1
+Git-commit: c6b61661d229e42b58d5e511191e925d105a5cce
+
+The other TCE handlers use page shift from the guest visible TCE table
+(described by kvmppc_spapr_tce_iommu_table) so let's make H_STUFF_TCE
+handlers do the same thing.
+
+This should cause no behavioral change now but soon we will allow
+the iommu_table::it_page_shift being different from from the emulated
+table page size so this will play a role.
+
+Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
+Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
+Acked-by: Balbir Singh <bsingharora@gmail.com>
+Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
+Acked-by: Michal Suchanek <msuchanek@suse.de>
+---
+ arch/powerpc/kvm/book3s_64_vio.c | 2 +-
+ arch/powerpc/kvm/book3s_64_vio_hv.c | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/arch/powerpc/kvm/book3s_64_vio.c b/arch/powerpc/kvm/book3s_64_vio.c
+index 4dffa611376d..041e54d26750 100644
+--- a/arch/powerpc/kvm/book3s_64_vio.c
++++ b/arch/powerpc/kvm/book3s_64_vio.c
+@@ -615,7 +615,7 @@ long kvmppc_h_stuff_tce(struct kvm_vcpu *vcpu,
+ return H_PARAMETER;
+
+ list_for_each_entry_lockless(stit, &stt->iommu_tables, next) {
+- unsigned long entry = ioba >> stit->tbl->it_page_shift;
++ unsigned long entry = ioba >> stt->page_shift;
+
+ for (i = 0; i < npages; ++i) {
+ ret = kvmppc_tce_iommu_unmap(vcpu->kvm,
+diff --git a/arch/powerpc/kvm/book3s_64_vio_hv.c b/arch/powerpc/kvm/book3s_64_vio_hv.c
+index 6651f736a0b1..e220fabb2f5d 100644
+--- a/arch/powerpc/kvm/book3s_64_vio_hv.c
++++ b/arch/powerpc/kvm/book3s_64_vio_hv.c
+@@ -526,7 +526,7 @@ long kvmppc_rm_h_stuff_tce(struct kvm_vcpu *vcpu,
+ return H_PARAMETER;
+
+ list_for_each_entry_lockless(stit, &stt->iommu_tables, next) {
+- unsigned long entry = ioba >> stit->tbl->it_page_shift;
++ unsigned long entry = ioba >> stt->page_shift;
+
+ for (i = 0; i < npages; ++i) {
+ ret = kvmppc_rm_tce_iommu_unmap(vcpu->kvm,
+--
+2.13.7
+
diff --git a/series.conf b/series.conf
index 6d4a3a4bf2..7829af2e62 100644
--- a/series.conf
+++ b/series.conf
@@ -16721,6 +16721,7 @@
patches.arch/KVM-PPC-Book3S-HV-Add-online-register-to-ONE_REG-int.patch
patches.arch/KVM-PPC-Book3S-HV-Set-RWMR-on-POWER8-so-PURR-SPURR-c.patch
patches.arch/KVM-PPC-Book3S-HV-Fix-inaccurate-comment.patch
+ patches.arch/KVM-PPC-Book3S-Use-correct-page-shift-in-H_STUFF_TCE.patch
patches.suse/ipv6-allow-PMTU-exceptions-to-local-routes.patch
patches.suse/net-dsa-add-error-handling-for-pskb_trim_rcsum.patch
patches.drivers/ixgbe-Fix-setting-of-TC-configuration-for-macvlan-ca.patch