[PATCH 2/4] bhyve: Move autostarting of domains into bhyveStateInitialize

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The stateAutoStart callback will go away shortly. Therefore, move
the autostart call into state initialize callback.

Signed-off-by: Michal Privoznik <mprivozn@xxxxxxxxxx>
---
 src/bhyve/bhyve_driver.c | 12 ++----------
 1 file changed, 2 insertions(+), 10 deletions(-)

diff --git a/src/bhyve/bhyve_driver.c b/src/bhyve/bhyve_driver.c
index 3e192284cc..061888ab0b 100644
--- a/src/bhyve/bhyve_driver.c
+++ b/src/bhyve/bhyve_driver.c
@@ -1269,6 +1269,8 @@ bhyveStateInitialize(bool privileged,
 
     virBhyveProcessReconnectAll(bhyve_driver);
 
+    bhyveAutostartDomains(bhyve_driver);
+
     return 0;
 
  cleanup:
@@ -1296,15 +1298,6 @@ bhyveDriverGetGrubCaps(virConnectPtr conn)
     return 0;
 }
 
-static void
-bhyveStateAutoStart(void)
-{
-    if (!bhyve_driver)
-        return;
-
-    bhyveAutostartDomains(bhyve_driver);
-}
-
 static int
 bhyveConnectGetMaxVcpus(virConnectPtr conn,
                         const char *type)
@@ -1712,7 +1705,6 @@ static virConnectDriver bhyveConnectDriver = {
 static virStateDriver bhyveStateDriver = {
     .name = "bhyve",
     .stateInitialize = bhyveStateInitialize,
-    .stateAutoStart = bhyveStateAutoStart,
     .stateCleanup = bhyveStateCleanup,
 };
 
-- 
2.19.2

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux