Messages in this thread | | | From | Paul Durrant <> | Date | Wed, 22 Nov 2023 13:04:18 +0000 | Subject | Re: [PATCH v9 04/15] KVM: pfncache: add a mark-dirty helper |
| |
On 22/11/2023 12:24, David Woodhouse wrote: > On Wed, 2023-11-22 at 12:18 +0000, Paul Durrant wrote: >> >> --- a/include/linux/kvm_host.h >> +++ b/include/linux/kvm_host.h >> @@ -1367,6 +1367,16 @@ int kvm_gpc_refresh(struct gfn_to_pfn_cache *gpc, unsigned long len); >> */ >> void kvm_gpc_deactivate(struct gfn_to_pfn_cache *gpc); >> >> +/** >> + * kvm_gpc_mark_dirty - mark a cached page as dirty. >> + * >> + * @gpc: struct gfn_to_pfn_cache object. >> + */ >> +static inline void kvm_gpc_mark_dirty(struct gfn_to_pfn_cache *gpc) >> +{ >> + mark_page_dirty_in_slot(gpc->kvm, gpc->memslot, gpc->gpa >> PAGE_SHIFT); >> +} > > This doesn't rescind my existing ack, but it's probably worth asserting > that gpc->lock is held here?
Yes, a good idea. If a v10 is needed, I'll add it. Otherwise I can do it as an incremental patch.
Paul
| |