diff options
Diffstat (limited to 'sys/dev/hyperv/include/hyperv.h')
-rw-r--r-- | sys/dev/hyperv/include/hyperv.h | 28 |
1 files changed, 12 insertions, 16 deletions
diff --git a/sys/dev/hyperv/include/hyperv.h b/sys/dev/hyperv/include/hyperv.h index 89ee202..9b59e20 100644 --- a/sys/dev/hyperv/include/hyperv.h +++ b/sys/dev/hyperv/include/hyperv.h @@ -242,7 +242,7 @@ typedef struct { uint32_t ring_data_size; /* ring_size */ } hv_vmbus_ring_buffer_info; -typedef void (*hv_vmbus_pfn_channel_callback)(void *context); +typedef void (*vmbus_chan_callback_t)(void *); typedef struct hv_vmbus_channel { device_t ch_dev; @@ -266,24 +266,21 @@ typedef struct hv_vmbus_channel { */ hv_vmbus_ring_buffer_info inbound; - struct taskqueue * rxq; - struct task channel_task; - hv_vmbus_pfn_channel_callback on_channel_callback; - void* channel_callback_context; + struct taskqueue *ch_tq; + struct task ch_task; + vmbus_chan_callback_t ch_cb; + void *ch_cbarg; struct hyperv_mon_param *ch_monprm; struct hyperv_dma ch_monprm_dma; + int ch_cpuid; /* owner cpu */ /* - * From Win8, this field specifies the target virtual process - * on which to deliver the interrupt from the host to guest. - * Before Win8, all channel interrupts would only be - * delivered on cpu 0. Setting this value to 0 would preserve - * the earlier behavior. + * Virtual cpuid for ch_cpuid; it is used to communicate cpuid + * related information w/ Hyper-V. If MSR_HV_VP_INDEX does not + * exist, ch_vcpuid will always be 0 for compatibility. */ - uint32_t target_vcpu; - /* The corresponding CPUID in the guest */ - uint32_t target_cpu; + uint32_t ch_vcpuid; /* * If this is a primary channel, ch_subchan* fields @@ -365,9 +362,8 @@ int hv_vmbus_channel_open( uint32_t recv_ring_buffer_size, void* user_data, uint32_t user_data_len, - hv_vmbus_pfn_channel_callback - pfn_on_channel_callback, - void* context); + vmbus_chan_callback_t cb, + void *cbarg); void hv_vmbus_channel_close(hv_vmbus_channel *channel); |