Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/hyperv/utilities/hv_shutdown.c
Show First 20 Lines • Show All 81 Lines • ▼ Show 20 Lines | hv_shutdown_cb(struct vmbus_channel *channel, void *context) | ||||
if ((ret == 0) && recv_len > 0) { | if ((ret == 0) && recv_len > 0) { | ||||
icmsghdrp = (struct hv_vmbus_icmsg_hdr *) | icmsghdrp = (struct hv_vmbus_icmsg_hdr *) | ||||
&buf[sizeof(struct hv_vmbus_pipe_hdr)]; | &buf[sizeof(struct hv_vmbus_pipe_hdr)]; | ||||
if (icmsghdrp->icmsgtype == HV_ICMSGTYPE_NEGOTIATE) { | if (icmsghdrp->icmsgtype == HV_ICMSGTYPE_NEGOTIATE) { | ||||
int error; | int error; | ||||
error = vmbus_ic_negomsg(softc, buf, recv_len); | error = vmbus_ic_negomsg(softc, buf, &recv_len); | ||||
if (error) | if (error) | ||||
return; | return; | ||||
} else { | } else { | ||||
shutdown_msg = | shutdown_msg = | ||||
(struct hv_vmbus_shutdown_msg_data *) | (struct hv_vmbus_shutdown_msg_data *) | ||||
&buf[sizeof(struct hv_vmbus_pipe_hdr) + | &buf[sizeof(struct hv_vmbus_pipe_hdr) + | ||||
sizeof(struct hv_vmbus_icmsg_hdr)]; | sizeof(struct hv_vmbus_icmsg_hdr)]; | ||||
▲ Show 20 Lines • Show All 57 Lines • Show Last 20 Lines |