Commit 75910f23 authored by Bill Pemberton's avatar Bill Pemberton Committed by Greg Kroah-Hartman

Staging: hv: remove ASSERT()s in ChannelMgt.c

Signed-off-by: default avatarBill Pemberton <wfp5p@virginia.edu>
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 1e19c054
...@@ -753,9 +753,15 @@ int VmbusChannelRequestOffers(void) ...@@ -753,9 +753,15 @@ int VmbusChannelRequestOffers(void)
msgInfo = kmalloc(sizeof(*msgInfo) + msgInfo = kmalloc(sizeof(*msgInfo) +
sizeof(struct vmbus_channel_message_header), sizeof(struct vmbus_channel_message_header),
GFP_KERNEL); GFP_KERNEL);
ASSERT(msgInfo != NULL); if (!msgInfo)
return -ENOMEM;
msgInfo->WaitEvent = osd_WaitEventCreate(); msgInfo->WaitEvent = osd_WaitEventCreate();
if (!msgInfo->WaitEvent) {
kfree(msgInfo);
return -ENOMEM;
}
msg = (struct vmbus_channel_message_header *)msgInfo->Msg; msg = (struct vmbus_channel_message_header *)msgInfo->Msg;
msg->MessageType = ChannelMessageRequestOffers; msg->MessageType = ChannelMessageRequestOffers;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment