1. 24 Nov, 2014 5 commits
    • Paolo Bonzini's avatar
      target-i386: move generic memory hotplug methods to DSDTs · 4f99ab7a
      Paolo Bonzini authored
      
      
      This makes it simpler to keep the SSDT byte-for-byte identical for a
      given machine type, which is a goal we want to have for 2.2 and newer
      types.
      Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      4f99ab7a
    • Michael S. Tsirkin's avatar
      acpi-build: mark RAM dirty on table update · ad5b88b1
      Michael S. Tsirkin authored
      
      
      acpi build modifies internal FW CFG RAM on first access
      but we forgot to mark it dirty.
      If this RAM has been migrated already, it won't be
      migrated again, returning corrupted tables to guest.
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      ad5b88b1
    • Marcel Apfelbaum's avatar
      hw/pci: fix crash on shpc error flow · 109e90e4
      Marcel Apfelbaum authored
      
      
      If the pci bridge enters in error flow as part
      of init process it will only delete the shpc mmio
      subregion but not remove it from the properties list,
      resulting in segmentation fault when the bridge runs
      the exit function.
      
      Example: add a pci bridge without specifing the chassis number:
          <qemu-bin> ... -device pci-bridge,id=p1
      Result:
          (qemu) qemu-system-x86_64: -device pci-bridge,id=p1: Bridge chassis not specified. Each bridge is required to be assigned a unique chassis id > 0.
          qemu-system-x86_64: -device pci-bridge,id=p1: Device
          initialization failed.
          Segmentation fault (core dumped)
      
          if (child->class->unparent) {
          #0  0x00005555558d629b in object_finalize_child_property (obj=0x555556d2e830, name=0x555556d30630 "shpc-mmio[0]", opaque=0x555556a42fc8) at qom/object.c:1078
          #1  0x00005555558d4b1f in object_property_del_all (obj=0x555556d2e830) at qom/object.c:367
          #2  0x00005555558d4ca1 in object_finalize (data=0x555556d2e830) at qom/object.c:412
          #3  0x00005555558d55a1 in object_unref (obj=0x555556d2e830) at qom/object.c:720
          #4  0x000055555572c907 in qdev_device_add (opts=0x5555563544f0) at qdev-monitor.c:566
          #5  0x0000555555744f16 in device_init_func (opts=0x5555563544f0, opaque=0x0) at vl.c:2213
          #6  0x00005555559cf5f0 in qemu_opts_foreach (list=0x555555e0f8e0 <qemu_device_opts>, func=0x555555744efa <device_init_func>, opaque=0x0, abort_on_failure=1) at util/qemu-option.c:1057
          #7  0x000055555574a11b in main (argc=16, argv=0x7fffffffdde8, envp=0x7fffffffde70) at vl.c:423
      
      Unparent the shpc mmio region as part of shpc cleanup.
      Signed-off-by: default avatarMarcel Apfelbaum <marcel.a@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Reviewed-by: default avatarAmos Kong <akong@redhat.com>
      109e90e4
    • Igor Mammedov's avatar
      pc: count in 1Gb hugepage alignment when sizing hotplug-memory container · 085f8e88
      Igor Mammedov authored
      
      
      if DIMMs with different size/alignment are interleaved
      in creation order, it could lead to hotplug-memory
      container fragmentation and following inability to use
      all RAM upto maxmem.
      For example:
          -m 4G,slots=3,maxmem=7G
          -object memory-backend-file,id=mem-1,size=256M,mem-path=/pagesize-2MB
          -device pc-dimm,id=mem1,memdev=mem-1
          -object memory-backend-file,id=mem-2,size=1G,mem-path=/pagesize-1GB
          -device pc-dimm,id=mem2,memdev=mem-2
          -object memory-backend-file,id=mem-3,size=256M,mem-path=/pagesize-2MB
          -device pc-dimm,id=mem3,memdev=mem-3
      
      fragments hotplug-memory container and doesn't allow
      to use 1GB hugepage backend to consume remainig 1Gb.
      
      To ease managment factor count in max 1Gb alignment for
      each memory slot when sizing hotplug-memory region so
      that regadless of fragmentaion it would be possible to
      add max aligned DIMM.
      Signed-off-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      085f8e88
    • Igor Mammedov's avatar
      pc: explicitly check maxmem limit when adding DIMM · b03541fa
      Igor Mammedov authored
      
      
      Currently maxmem limit is not checked and depends on
      hotplug region container not being able to fit more RAM
      than maxmem. Do check explicitly so that it would
      be possible to change hotplug container size later
      to deal with fragmentation.
      Signed-off-by: default avatarIgor Mammedov <imammedo@redhat.com>
      Reviewed-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      b03541fa
  2. 23 Nov, 2014 7 commits
  3. 21 Nov, 2014 8 commits
  4. 20 Nov, 2014 7 commits
  5. 18 Nov, 2014 13 commits