-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path0125-xen-xenbus-don-t-be-slow.patch
48 lines (42 loc) · 1.55 KB
/
0125-xen-xenbus-don-t-be-slow.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Arjan van de Ven <[email protected]>
Date: Sun, 7 May 2017 00:34:01 +0000
Subject: [PATCH] xen: xenbus: don't be slow
---
drivers/xen/xenbus/xenbus_probe_frontend.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/xen/xenbus/xenbus_probe_frontend.c b/drivers/xen/xenbus/xenbus_probe_frontend.c
index 480944606a3c..0f0086e69c38 100644
--- a/drivers/xen/xenbus/xenbus_probe_frontend.c
+++ b/drivers/xen/xenbus/xenbus_probe_frontend.c
@@ -199,6 +199,7 @@ static int is_device_connecting(struct device *dev, void *data, bool ignore_none
struct xenbus_device *xendev = to_xenbus_device(dev);
struct device_driver *drv = data;
struct xenbus_driver *xendrv;
+ int ret;
/*
* A device with no driver will never connect. We care only about
@@ -224,9 +225,13 @@ static int is_device_connecting(struct device *dev, void *data, bool ignore_none
return 0;
}
xendrv = to_xenbus_driver(dev->driver);
- return (xendev->state < XenbusStateConnected ||
+ ret = (xendev->state < XenbusStateConnected ||
(xendev->state == XenbusStateConnected &&
xendrv->is_ready && !xendrv->is_ready(xendev)));
+
+ if (ret)
+ dev_info(dev, " connecting\n");
+ return ret;
}
static int essential_device_connecting(struct device *dev, void *data)
{
@@ -288,7 +293,7 @@ static bool wait_loop(unsigned long start, unsigned int max_delay,
}
}
- schedule_timeout_interruptible(HZ/10);
+ schedule_timeout_interruptible(1);
return false;
}
--
https://clearlinux.org