1. 23 3月, 2017 15 次提交
  2. 22 3月, 2017 4 次提交
  3. 16 3月, 2017 2 次提交
    • M
      virTimeBackOffWait: Avoid long periods of sleep · 67dcb797
      Michal Privoznik 提交于
      While connecting to qemu monitor, the first thing we do is wait
      for it to show up. However, we are doing it with some timeout to
      avoid indefinite waits (e.g. when qemu doesn't create the monitor
      socket at all). After beaa447a we are using exponential back
      off timeout meaning, after the first connection attempt we wait
      1ms, then 2ms, then 4 and so on.  This allows us to bring down
      wait time for small domains where qemu initializes quickly.
      However, on the other end of this scale are some domains with
      huge amounts of guest memory. Now imagine that we've gotten up to
      wait time of 15 seconds. The next one is going to be 30 seconds,
      and the one after that whole minute. Well, okay - with current
      code we are not going to wait longer than 30 seconds in total,
      but this is going to change in the next commit.
      
      The exponential back off is usable only for first few iterations.
      Then it needs to be caped (one second was chosen as the limit)
      and switch to constant wait time.
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      67dcb797
    • J
      util: Rename virFileWaitForDevices · 97e0d3c3
      John Ferlan 提交于
      The function is actually in virutil.c, but prototyped in virfile.h.
      This patch fixes that by renaming the function to virWaitForDevices,
      adding the prototype in virutil.h and libvirt_private.syms, and then
      changing the callers to use the new name.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      97e0d3c3
  4. 08 3月, 2017 11 次提交
  5. 07 3月, 2017 3 次提交
    • P
      tests: sysinfo: Export virSysinfoSetup via the private header · c58d95b7
      Peter Krempa 提交于
      virSysinfoSetup should be used only in tests so it can be moved to the
      new header file rather than using an extern declaration.
      c58d95b7
    • P
      util: sysinfo: Reduce amount of conditionally compiled code · b38c6b6a
      Peter Krempa 提交于
      Whole implementations along with helper totalling screens of code were
      conditionally compiled. That made the code totally unreadable and
      untestable. Rename functions to have the architecture in the name so
      that all can be compiled at the same time and introduce header to allow
      testing them all.
      b38c6b6a
    • L
      make all struct typedefs comply with proposed coding conventions · 38985269
      Laine Stump 提交于
      Proposed formal coding conventions encourage defining typedefs for
      vir[Blah] and vir[Blah]Ptr separately from the associated struct named
      _vir[Blah]:
      
          typedef struct _virBlah virBlah;
          typedef virBlah *virBlahPtr;
          struct _virBlah {
          ...
          };
      
      At some point in the past, I had submitted several patches using a
      more compact style that I prefer, and they were accepted:
      
          typedef struct _virBlah {
              ...
          } virBlah, *virBlahPtr;
      
      Since these are by far a minority among all struct definitions, this
      patch changes all those definitions to reflect the style prefered by
      the proposal so that there is 100% consistency.
      38985269
  6. 06 3月, 2017 2 次提交
    • J
      Cache the presence of machine1 service · f10bd740
      Ján Tomko 提交于
      After the system has been booted, it should not change.
      
      Cache the return value of virSystemdHasMachined.
      Allow starting and terminating machines with just one
      DBus call, instead of three, reducing the chance of
      the call timing out.
      
      Also introduce a small function for resetting the cache
      to be used in tests.
      f10bd740
    • J
      Unify checking for machine1 systemd service · 18c145a0
      Ján Tomko 提交于
      Both virSystemdTerminateMachine and virSystemdCreateMachine
      propagate the error to tell between a non-systemd system
      and a hard error.
      
      In virSystemdGetMachineNameByPID both are treated the same,
      but an error is ignored by the callers.
      
      Split out the checks into a separate function.
      18c145a0
  7. 24 2月, 2017 3 次提交