提交 24b8a406 编写于 作者: T Tobias Klauser 提交者: Greg Kroah-Hartman

hv: Remove unnecessary comparison of unsigned against 0

pfncount is of type u32 and thus can never be smaller than 0.

Found by the coverity scanner, CID 143213.
Signed-off-by: NTobias Klauser <tklauser@distanz.ch>
Signed-off-by: NK. Y. Srinivasan <kys@microsoft.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 3a28fa35
......@@ -682,8 +682,7 @@ int vmbus_sendpacket_multipagebuffer(struct vmbus_channel *channel,
u32 pfncount = NUM_PAGES_SPANNED(multi_pagebuffer->offset,
multi_pagebuffer->len);
if ((pfncount < 0) || (pfncount > MAX_MULTIPAGE_BUFFER_COUNT))
if (pfncount > MAX_MULTIPAGE_BUFFER_COUNT)
return -EINVAL;
/*
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册