mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 09:43:56 -06:00
postcopy: helper for waking shared
Provide a helper to send a 'wake' request on a userfaultfd for a shared process. The address in the clients address space is specified together with the RAMBlock it was resolved to. Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
375318d03f
commit
5efc356403
3 changed files with 37 additions and 0 deletions
|
@ -164,6 +164,16 @@ struct PostCopyFD {
|
|||
*/
|
||||
void postcopy_register_shared_ufd(struct PostCopyFD *pcfd);
|
||||
void postcopy_unregister_shared_ufd(struct PostCopyFD *pcfd);
|
||||
/* postcopy_wake_shared: Notify a client ufd that a page is available
|
||||
*
|
||||
* Returns 0 on success
|
||||
*
|
||||
* @pcfd: Structure with fd, handler and name as above
|
||||
* @client_addr: Address in the client program, not QEMU
|
||||
* @rb: The RAMBlock the page is in
|
||||
*/
|
||||
int postcopy_wake_shared(struct PostCopyFD *pcfd, uint64_t client_addr,
|
||||
RAMBlock *rb);
|
||||
/* Callback from shared fault handlers to ask for a page */
|
||||
int postcopy_request_shared_page(struct PostCopyFD *pcfd, RAMBlock *rb,
|
||||
uint64_t client_addr, uint64_t offset);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue