[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3 kvm/queue 06/16] KVM: Implement fd-based memory using MEMF
From: |
Sean Christopherson |
Subject: |
Re: [PATCH v3 kvm/queue 06/16] KVM: Implement fd-based memory using MEMFD_OPS interfaces |
Date: |
Tue, 28 Dec 2021 22:14:41 +0000 |
On Fri, Dec 24, 2021, Chao Peng wrote:
> On Fri, Dec 24, 2021 at 12:09:47AM +0100, Paolo Bonzini wrote:
> > On 12/23/21 19:34, Sean Christopherson wrote:
> > > > select HAVE_KVM_PM_NOTIFIER if PM
> > > > + select MEMFD_OPS
> > > MEMFD_OPS is a weird Kconfig name given that it's not just memfd() that
> > > can
> > > implement the ops.
> > >
> >
> > Or, it's kvm that implements them to talk to memfd?
>
> The only thing is VFIO may also use the same set of callbacks, as
> discussed in the v2. But I think that's fine.
I'm objecting to assuming that KVM is talking to memfd. KVM shouldn't know or
care what is sitting behind the fd, KVM only cares whether or not the backing
store
provides the necessary APIs.
I also think that the API as whole should be abstracted from memfd. It's mostly
cosmectic, e.g. tweak the struct and Kconfig name. I don't really care if it's
initially dependent on MEMFD_CREATE, I just don't want to end up with an API and
KVM implementation that implies there's something fundamentally special about
memfd.
- Re: [PATCH v3 kvm/queue 05/16] KVM: Maintain ofs_tree for fast memslot lookup by file offset, (continued)
[PATCH v3 kvm/queue 07/16] KVM: Refactor hva based memory invalidation code, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 08/16] KVM: Special handling for fd-based memory invalidation, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 06/16] KVM: Implement fd-based memory using MEMFD_OPS interfaces, Chao Peng, 2021/12/23
Re: [PATCH v3 kvm/queue 06/16] KVM: Implement fd-based memory using MEMFD_OPS interfaces, Chao Peng, 2021/12/23
Re: [PATCH v3 kvm/queue 06/16] KVM: Implement fd-based memory using MEMFD_OPS interfaces, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 09/16] KVM: Split out common memory invalidation code, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 10/16] KVM: Implement fd-based memory invalidation, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 11/16] KVM: Add kvm_map_gfn_range, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 12/16] KVM: Implement fd-based memory fallocation, Chao Peng, 2021/12/23
[PATCH v3 kvm/queue 13/16] KVM: Add KVM_EXIT_MEMORY_ERROR exit, Chao Peng, 2021/12/23