Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-21 Thread Steven Price
On 20/05/2021 18:50, Catalin Marinas wrote: > On Thu, May 20, 2021 at 04:05:46PM +0100, Steven Price wrote: >> On 20/05/2021 12:54, Catalin Marinas wrote: >>> On Mon, May 17, 2021 at 01:32:35PM +0100, Steven Price wrote: diff --git a/arch/arm64/kvm/mmu.c b/arch/arm64/kvm/mmu.c index

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-20 Thread Catalin Marinas
On Thu, May 20, 2021 at 04:05:46PM +0100, Steven Price wrote: > On 20/05/2021 12:54, Catalin Marinas wrote: > > On Mon, May 17, 2021 at 01:32:35PM +0100, Steven Price wrote: > >> diff --git a/arch/arm64/kvm/mmu.c b/arch/arm64/kvm/mmu.c > >> index c5d1f3c87dbd..8660f6a03f51 100644 > >> ---

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-20 Thread Steven Price
On 20/05/2021 12:54, Catalin Marinas wrote: > On Mon, May 17, 2021 at 01:32:35PM +0100, Steven Price wrote: >> diff --git a/arch/arm64/kvm/mmu.c b/arch/arm64/kvm/mmu.c >> index c5d1f3c87dbd..8660f6a03f51 100644 >> --- a/arch/arm64/kvm/mmu.c >> +++ b/arch/arm64/kvm/mmu.c >> @@ -822,6 +822,31 @@

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-20 Thread Steven Price
On 20/05/2021 09:51, Marc Zyngier wrote: > On Wed, 19 May 2021 11:48:21 +0100, > Steven Price wrote: >> >> On 17/05/2021 17:45, Marc Zyngier wrote: >>> On Mon, 17 May 2021 13:32:35 +0100, >>> Steven Price wrote: [...] + } + } + + return 0; +} +

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-20 Thread Catalin Marinas
On Mon, May 17, 2021 at 01:32:35PM +0100, Steven Price wrote: > diff --git a/arch/arm64/kvm/mmu.c b/arch/arm64/kvm/mmu.c > index c5d1f3c87dbd..8660f6a03f51 100644 > --- a/arch/arm64/kvm/mmu.c > +++ b/arch/arm64/kvm/mmu.c > @@ -822,6 +822,31 @@ transparent_hugepage_adjust(struct kvm_memory_slot >

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-20 Thread Marc Zyngier
On Wed, 19 May 2021 11:48:21 +0100, Steven Price wrote: > > On 17/05/2021 17:45, Marc Zyngier wrote: > > On Mon, 17 May 2021 13:32:35 +0100, > > Steven Price wrote: > >> > >> Add a new VM feature 'KVM_ARM_CAP_MTE' which enables memory tagging > >> for a VM. This will expose the feature to the

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-19 Thread Steven Price
On 17/05/2021 17:45, Marc Zyngier wrote: > On Mon, 17 May 2021 13:32:35 +0100, > Steven Price wrote: >> >> Add a new VM feature 'KVM_ARM_CAP_MTE' which enables memory tagging >> for a VM. This will expose the feature to the guest and automatically >> tag memory pages touched by the VM as

Re: [PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-17 Thread Marc Zyngier
On Mon, 17 May 2021 13:32:35 +0100, Steven Price wrote: > > Add a new VM feature 'KVM_ARM_CAP_MTE' which enables memory tagging > for a VM. This will expose the feature to the guest and automatically > tag memory pages touched by the VM as PG_mte_tagged (and clear the tag > storage) to ensure

[PATCH v12 4/8] arm64: kvm: Introduce MTE VM feature

2021-05-17 Thread Steven Price
Add a new VM feature 'KVM_ARM_CAP_MTE' which enables memory tagging for a VM. This will expose the feature to the guest and automatically tag memory pages touched by the VM as PG_mte_tagged (and clear the tag storage) to ensure that the guest cannot see stale tags, and so that the tags are