]> git.proxmox.com Git - mirror_qemu.git/commit
kvm: Add helper kvm_dirty_ring_init()
authorGavin Shan <gshan@redhat.com>
Tue, 9 May 2023 02:21:21 +0000 (12:21 +1000)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 18 May 2023 06:53:50 +0000 (08:53 +0200)
commit3794cb9485ca52a65494c6eb108ff280a7e98dbc
tree22acdb5b50a8da8efa451ea9c4e41888f72d067f
parentb20cc776922dcf6d97f431a3460e868a9ac3e89e
kvm: Add helper kvm_dirty_ring_init()

Due to multiple capabilities associated with the dirty ring for different
architectures: KVM_CAP_DIRTY_{LOG_RING, LOG_RING_ACQ_REL} for x86 and
arm64 separately. There will be more to be done in order to support the
dirty ring for arm64.

Lets add helper kvm_dirty_ring_init() to enable the dirty ring. With this,
the code looks a bit clean.

No functional change intended.

Signed-off-by: Gavin Shan <gshan@redhat.com>
Reviewed-by: Peter Xu <peterx@redhat.com>
Tested-by: Zhenyu Zhang <zhenyzha@redhat.com>
Message-Id: <20230509022122.20888-4-gshan@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
accel/kvm/kvm-all.c