aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2009-07-08 06:27:38 -0400
committerJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>2009-12-03 14:14:49 -0500
commitf8dc33088febc63286b7a60e6b678de8e064de8e (patch)
tree1bafcc4d64001f132cdd374b643bce5474094a9a /drivers
parentc6e1971139be1342902873181f3b80a979bfb33b (diff)
xen: improvement to wait_for_devices()
When printing a warning about a timed-out device, print the current state of both ends of the device connection (i.e., backend as well as frontend). This backports half of changeset 146 from the Xenbits tree. Cc: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/xen/xenbus/xenbus_probe.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/xen/xenbus/xenbus_probe.c b/drivers/xen/xenbus/xenbus_probe.c
index 19bce3e1b333..9246a8c4ecf2 100644
--- a/drivers/xen/xenbus/xenbus_probe.c
+++ b/drivers/xen/xenbus/xenbus_probe.c
@@ -885,10 +885,13 @@ static int print_device_status(struct device *dev, void *data)
885 /* Information only: is this too noisy? */ 885 /* Information only: is this too noisy? */
886 printk(KERN_INFO "XENBUS: Device with no driver: %s\n", 886 printk(KERN_INFO "XENBUS: Device with no driver: %s\n",
887 xendev->nodename); 887 xendev->nodename);
888 } else if (xendev->state != XenbusStateConnected) { 888 } else if (xendev->state < XenbusStateConnected) {
889 enum xenbus_state rstate = XenbusStateUnknown;
890 if (xendev->otherend)
891 rstate = xenbus_read_driver_state(xendev->otherend);
889 printk(KERN_WARNING "XENBUS: Timeout connecting " 892 printk(KERN_WARNING "XENBUS: Timeout connecting "
890 "to device: %s (state %d)\n", 893 "to device: %s (local state %d, remote state %d)\n",
891 xendev->nodename, xendev->state); 894 xendev->nodename, xendev->state, rstate);
892 } 895 }
893 896
894 return 0; 897 return 0;