mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-01 23:03:54 -06:00
hyperv: process SIGNAL_EVENT hypercall
Add handling of SIGNAL_EVENT hypercall. For that, provide an interface to associate an EventNotifier with an event connection number, so that it's signaled when the SIGNAL_EVENT hypercall with the matching connection ID is called by the guest. Support for using KVM functionality for this will be added in a followup patch. Signed-off-by: Roman Kagan <rkagan@virtuozzo.com> Message-Id: <20180921082217.29481-8-rkagan@virtuozzo.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
f5642f8b45
commit
e6ea9f45b7
4 changed files with 113 additions and 4 deletions
|
@ -39,6 +39,19 @@ int hyperv_post_msg(HvSintRoute *sint_route, struct hyperv_message *msg);
|
|||
*/
|
||||
int hyperv_set_event_flag(HvSintRoute *sint_route, unsigned eventno);
|
||||
|
||||
/*
|
||||
* Associate @notifier with the event connection @conn_id, such that @notifier
|
||||
* is signaled when the guest executes HV_SIGNAL_EVENT hypercall on @conn_id.
|
||||
* If @notifier is NULL clear the association.
|
||||
*/
|
||||
int hyperv_set_event_flag_handler(uint32_t conn_id, EventNotifier *notifier);
|
||||
|
||||
/*
|
||||
* Process HV_SIGNAL_EVENT hypercall: signal the EventNotifier associated with
|
||||
* the connection as specified in @param.
|
||||
*/
|
||||
uint16_t hyperv_hcall_signal_event(uint64_t param, bool fast);
|
||||
|
||||
static inline uint32_t hyperv_vp_index(CPUState *cs)
|
||||
{
|
||||
return cs->cpu_index;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue