Skip to content
Snippets Groups Projects
  1. Mar 16, 2017
    • Daniel P. Berrangé's avatar
      migration: use "" as the default for tls-creds/hostname · 4af245dc
      Daniel P. Berrangé authored
      
      The tls-creds parameter has a default value of NULL indicating
      that TLS should not be used. Setting it to non-NULL enables
      use of TLS. Once tls-creds are set to a non-NULL value via the
      monitor, it isn't possible to set them back to NULL again, due
      to current implementation limitations. The empty string is not
      a valid QObject identifier, so this switches to use "" as the
      default, indicating that TLS will not be used
      
      The tls-hostname parameter has a default value of NULL indicating
      the the hostname from the migrate connection URI should be used.
      Again, once tls-hostname is set non-NULL, to override the default
      hostname for x509 cert validation, it isn't possible to reset it
      back to NULL via the monitor. The empty string is not a valid
      hostname, so this switches to use "" as the default, indicating
      that the migrate URI hostname should be used.
      
      Using "" as the default for both, also means that the monitor
      commands "info migrate_parameters" / "query-migrate-parameters"
      will report existance of tls-creds/tls-parameters even when set
      to their default values.
      
      Signed-off-by: default avatarDaniel P. Berrange <berrange@redhat.com>
      Reviewed-by: default avatarDr. David Alan Gilbert <dgilbert@redhat.com>
      Reviewed-by: default avatarEric Blake <eblake@redhat.com>
      
      Signed-off-by: default avatarJuan Quintela <quintela@redhat.com>
      4af245dc
    • Chao Fan's avatar
      Change the method to calculate dirty-pages-rate · 1ffb5dfd
      Chao Fan authored
      
      In function cpu_physical_memory_sync_dirty_bitmap, file
      include/exec/ram_addr.h:
      
      if (src[idx][offset]) {
          unsigned long bits = atomic_xchg(&src[idx][offset], 0);
          unsigned long new_dirty;
          new_dirty = ~dest[k];
          dest[k] |= bits;
          new_dirty &= bits;
          num_dirty += ctpopl(new_dirty);
      }
      
      After these codes executed, only the pages not dirtied in bitmap(dest),
      but dirtied in dirty_memory[DIRTY_MEMORY_MIGRATION] will be calculated.
      For example:
      When ram_list.dirty_memory[DIRTY_MEMORY_MIGRATION] = 0b00001111,
      and atomic_rcu_read(&migration_bitmap_rcu)->bmap = 0b00000011,
      the new_dirty will be 0b00001100, and this function will return 2 but not
      4 which is expected.
      the dirty pages in dirty_memory[DIRTY_MEMORY_MIGRATION] are all new,
      so these should be calculated also.
      
      Signed-off-by: default avatarChao Fan <fanc.fnst@cn.fujitsu.com>
      Signed-off-by: default avatarLi Zhijian <lizhijian@cn.fujitsu.com>
      Reviewed-by: default avatarJuan Quintela <quintela@redhat.com>
      Signed-off-by: default avatarJuan Quintela <quintela@redhat.com>
      1ffb5dfd
  2. Mar 15, 2017
  3. Mar 14, 2017
Loading