mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 10:40:03 +01:00
libxl: improve logging on failure to start device model.
Distinguish between device model dying during startup (libxl__spawn_check returns failure) and timing out while waiting for the xenstore node to show up. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Acked-by: Ian Jackson <ian.jackson@eu.citrix.com> Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
This commit is contained in:
1 parent
2cb4424e3a
commit
306fa5ad64
1 file changed
+3
-1
@@ -445,6 +445,8 @@ int libxl__wait_for_device_model(libxl__gc *gc,
|
||||
if ( starting ) {
|
||||
rc = libxl__spawn_check(gc, starting->for_spawn);
|
||||
if ( rc ) {
|
||||
LIBXL__LOG(ctx, LIBXL__LOG_ERROR,
|
||||
"Device Model died during startup");
|
||||
rc = -1;
|
||||
goto err_died;
|
||||
}
|
||||
@@ -487,10 +489,10 @@ again:
|
||||
}
|
||||
}
|
||||
}
|
||||
LIBXL__LOG(ctx, LIBXL__LOG_ERROR, "Device Model not ready");
|
||||
err_died:
|
||||
xs_unwatch(xsh, path, path);
|
||||
xs_daemon_close(xsh);
|
||||
LIBXL__LOG(ctx, LIBXL__LOG_ERROR, "Device Model not ready");
|
||||
err:
|
||||
return -1;
|
||||
}
|
||||
|
||||