Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 55b06b0f authored by Corey Minyard's avatar Corey Minyard Committed by Greg Kroah-Hartman
Browse files

ipmi: fix unsigned long underflow



commit 392a17b10ec4320d3c0e96e2a23ebaad1123b989 upstream.

When I set the timeout to a specific value such as 500ms, the timeout
event will not happen in time due to the overflow in function
check_msg_timeout:
...
	ent->timeout -= timeout_period;
	if (ent->timeout > 0)
		return;
...

The type of timeout_period is long, but ent->timeout is unsigned long.
This patch makes the type consistent.

Reported-by: default avatarWeilong Chen <chenweilong@huawei.com>
Signed-off-by: default avatarCorey Minyard <cminyard@mvista.com>
Tested-by: default avatarWeilong Chen <chenweilong@huawei.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 8af77738
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment