[GIT,PULL,1/2] kvm: fix compile on s390 part 2
diff mbox series

Message ID 20190529125045.42935-2-borntraeger@de.ibm.com
State New
Headers show
Series
  • [GIT,PULL,1/2] kvm: fix compile on s390 part 2
Related show

Commit Message

Christian Borntraeger May 29, 2019, 12:50 p.m. UTC
We also need to fence the memunmap part.

Fixes: e45adf665a53 ("KVM: Introduce a new guest mapping API")
Fixes: d30b214d1d0a (kvm: fix compilation on s390)
Cc: Michal Kubecek <mkubecek@suse.cz>
Cc: KarimAllah Ahmed <karahmed@amazon.de>
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
---
 virt/kvm/kvm_main.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

David Hildenbrand May 29, 2019, 12:53 p.m. UTC | #1
On 29.05.19 14:50, Christian Borntraeger wrote:
> We also need to fence the memunmap part.
> 
> Fixes: e45adf665a53 ("KVM: Introduce a new guest mapping API")
> Fixes: d30b214d1d0a (kvm: fix compilation on s390)
> Cc: Michal Kubecek <mkubecek@suse.cz>
> Cc: KarimAllah Ahmed <karahmed@amazon.de>
> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
> ---
>  virt/kvm/kvm_main.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
> index 134ec0283a8a..301089a462c4 100644
> --- a/virt/kvm/kvm_main.c
> +++ b/virt/kvm/kvm_main.c
> @@ -1795,8 +1795,10 @@ void kvm_vcpu_unmap(struct kvm_vcpu *vcpu, struct kvm_host_map *map,
>  
>  	if (map->page)
>  		kunmap(map->page);
> +#ifdef CONFIG_HAS_IOMEM
>  	else
>  		memunmap(map->hva);
> +#endif
>  
>  	if (dirty) {
>  		kvm_vcpu_mark_page_dirty(vcpu, map->gfn);
> 

I *think* you dropped my r-b - never mind ;)

Patch
diff mbox series

diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index 134ec0283a8a..301089a462c4 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -1795,8 +1795,10 @@  void kvm_vcpu_unmap(struct kvm_vcpu *vcpu, struct kvm_host_map *map,
 
 	if (map->page)
 		kunmap(map->page);
+#ifdef CONFIG_HAS_IOMEM
 	else
 		memunmap(map->hva);
+#endif
 
 	if (dirty) {
 		kvm_vcpu_mark_page_dirty(vcpu, map->gfn);