[SeaBIOS] [PATCH] memory hotplug
vasilis.liaskovitis at profitbricks.com
Thu Sep 8 18:21:54 CEST 2011
On Wed, Sep 07, 2011 at 05:58:49PM +0800, Lai Jiangshan wrote:
> On 09/06/2011 04:07 PM, Vasilis Liaskovitis wrote:
> > Hi Lai,
> Yes, it is virtio disk. (the guest kernel is 2.6.32-71.el6)
> [root at lai qemu-kvm]# x86_64-softmmu/qemu-system-x86_64 -drive file=/home/laijs/Machines/rhel6.img,if=none,id=drive-virtio-disk0,format=qcow2 -device virtio-blk-pci,bus=pci.0,multifunction=on,addr=0x5.0x0,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 -m 1024,maxmem=2048 -smp 2,maxcpus=8 -bios ../seabios/out/bios.bin
> When I changed it to IDE disk: (the guest kernel is 3.1.0-rc4-tip)
> [root at lai qemu-kvm]# x86_64-softmmu/qemu-system-x86_64 /home/laijs/Machines/rhel6.img -m 1024,maxmem=2048 -smp 2,maxcpus=8 -bios ../seabios/out/bios.bin
> The memory block was successfully added, but when after
> "echo online > /sys/devices/system/memory/memory3/state",
> the result are the same: disk failed.
I notice that you only have 2 memory devices initially, for 1GB initial memory.
This suggests your /sys/devices/system/memory/block_size_bytes is 512MB, can you
Currently the draft patches I sent only work with x86_64 guest, where
block_size_bytes are 128 MB. You 'll have to change the definition of the
constant LINUX_MIN_BLOCK_SIZE to whatever block_size_bytes your guest uses (in
both the qemu-kvm and seabios patch).
Additionally, in SeaBIOS the final line of the QWordMemory descriptor in
src/ssdt-mem.dsl will need to match the new block_size_bytes as well.
Is your rhel6 guest 32-bit with PAE? This combination has SECTION_SIZE_BITS==29
in arch/x86/include/asm/sparsemem.h which would explain the number of memory
devices you are seeing.
More information about the SeaBIOS