From 73ad873a4e7f5d78d0e6bf116a2241f88f369392 Mon Sep 17 00:00:00 2001 From: Will Deacon Date: Thu, 7 Jul 2022 15:51:33 +0100 Subject: [PATCH] Revert "ANDROID: KVM: arm64: Allow non-coallescable pages in a hyp_pool" This reverts commit a437069d1321048ab0ed65dc4168cceb2bdfd04f. Bug: 233587962 Signed-off-by: Will Deacon Change-Id: I349d95060a7b7e6d223ff7c3e28d6900b370868a --- arch/arm64/kvm/hyp/nvhe/page_alloc.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/arch/arm64/kvm/hyp/nvhe/page_alloc.c b/arch/arm64/kvm/hyp/nvhe/page_alloc.c index aa72fd2546ab..31c073dcf478 100644 --- a/arch/arm64/kvm/hyp/nvhe/page_alloc.c +++ b/arch/arm64/kvm/hyp/nvhe/page_alloc.c @@ -93,15 +93,11 @@ static inline struct hyp_page *node_to_page(struct list_head *node) static void __hyp_attach_page(struct hyp_pool *pool, struct hyp_page *p) { - phys_addr_t phys = hyp_page_to_phys(p); unsigned short order = p->order; struct hyp_page *buddy; memset(hyp_page_to_virt(p), 0, PAGE_SIZE << p->order); - if (phys < pool->range_start || phys >= pool->range_end) - goto insert; - /* * Only the first struct hyp_page of a high-order page (otherwise known * as the 'head') should have p->order set. The non-head pages should @@ -120,7 +116,6 @@ static void __hyp_attach_page(struct hyp_pool *pool, p = min(p, buddy); } -insert: /* Mark the new head, and insert it */ p->order = order; page_add_to_list(p, &pool->free_area[order]);