KVM: PPC: Book3S HV: Fix H_REGISTER_VPA VPA size validation
authorNicholas Piggin <npiggin@gmail.com>
Sun, 13 Aug 2017 01:33:38 +0000 (11:33 +1000)
committerPaul Mackerras <paulus@ozlabs.org>
Thu, 31 Aug 2017 02:36:44 +0000 (12:36 +1000)
commiteaac112eac8604917bc6c39680ff67a937626a96
treed009c92c25a88619dd8cf60367dc080754a9d312
parentd182b8fd6084412963cdb1a16d04c2f07234e82b
KVM: PPC: Book3S HV: Fix H_REGISTER_VPA VPA size validation

KVM currently validates the size of the VPA registered by the client
against sizeof(struct lppaca), however we align (and therefore size)
that struct to 1kB to avoid crossing a 4kB boundary in the client.

PAPR calls for sizes >= 640 bytes to be accepted. Hard code this with
a comment.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
arch/powerpc/kvm/book3s_hv.c