Files
android_kernel_xiaomi_sm8450/arch/arm/include/asm
Marc Zyngier 04b8dc85bf arm64: KVM: Do not use pgd_index to index stage-2 pgd
The kernel's pgd_index macro is designed to index a normal, page
sized array. KVM is a bit diffferent, as we can use concatenated
pages to have a bigger address space (for example 40bit IPA with
4kB pages gives us an 8kB PGD.

In the above case, the use of pgd_index will always return an index
inside the first 4kB, which makes a guest that has memory above
0x8000000000 rather unhappy, as it spins forever in a page fault,
whist the host happilly corrupts the lower pgd.

The obvious fix is to get our own kvm_pgd_index that does the right
thing(tm).

Tested on X-Gene with a hacked kvmtool that put memory at a stupidly
high address.

Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
2015-03-11 14:24:36 +01:00
..
2014-04-18 11:40:32 +02:00
2014-06-02 09:20:18 +01:00
2014-12-04 12:41:50 +00:00
2012-07-05 09:50:55 +01:00
2012-09-14 13:53:39 +00:00
2014-11-10 15:59:23 +01:00
2013-04-17 21:38:10 +02:00
2014-02-25 11:33:37 +00:00
2012-07-24 15:27:28 +08:00
2014-06-01 01:17:12 +01:00
2014-11-10 15:59:23 +01:00
2013-07-08 22:08:51 +01:00
2014-12-27 18:19:18 -07:00
2014-05-27 15:58:49 +02:00
2014-06-01 01:17:12 +01:00
2014-02-25 11:33:37 +00:00
2015-01-13 15:23:51 +02:00
2014-08-09 14:07:53 +01:00
2014-03-18 16:39:40 -04:00