Staging: hv: remove ASSERT()s in ChannelMgt.c
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
1e19c05443
commit
75910f236a
@ -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;
|
||||||
|
Loading…
Reference in New Issue
Block a user