提交 f45140df 编写于 作者: D Dan Carpenter 提交者: Oleksandr Andrushchenko

drm/xen-front: Fix loop timeout

If the loop times out then we want to exit with "to" set to zero, but in
the current code it's set to -1.

Fixes: c575b7ee ("drm/xen-front: Add support for Xen PV display frontend")
Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: NOleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Signed-off-by: NOleksandr Andrushchenko <oleksandr_andrushchenko@epam.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180508092829.GC661@mwanda
上级 18f20bc5
......@@ -778,7 +778,7 @@ static int xen_drv_remove(struct xenbus_device *dev)
*/
while ((xenbus_read_unsigned(front_info->xb_dev->otherend, "state",
XenbusStateUnknown) != XenbusStateInitWait) &&
to--)
--to)
msleep(10);
if (!to) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册