summaryrefslogtreecommitdiff
path: root/hw/i386
AgeCommit message (Collapse)Author
2015-03-19smbios: add max speed comdline option for type-17 (meory device) structureGabriel L. Somlo
Signed-off-by: Gabriel Somlo <somlo@cmu.edu> Acked-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
2015-03-17target-i386: Remove icc_bridge parameter from cpu_x86_create()Eduardo Habkost
Instead of passing icc_bridge from the PC initialization code to cpu_x86_create(), make the PC initialization code attach the CPU to icc_bridge. The only difference here is that icc_bridge attachment will now be done after x86_cpu_parse_featurestr() is called. But this shouldn't make any difference, as property setters shouldn't depend on icc_bridge. Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
2015-03-17pc: Suppress APIC ID compatibility warning for QTestAndreas Färber
This avoids cluttering GTester output with irrelevant warnings. Cc: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
2015-03-16pc: Disable vmdesc submission for old machinesAlexander Graf
Older PC machine types might by accident be backwards live migration compatible, but with the new vmdesc self-describing blob in our live migration stream we would break that compatibility. Also users wouldn't expect massive behaviorial differences when updating to a new version of QEMU while retaining their old machine type, especially not potential breakage in tooling around live migration. So disable vmdesc submission for old PC machine types. Signed-off-by: Alexander Graf <agraf@suse.de> Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
2015-03-09target-i386: Move APIC ID compatibility code to pc.cEduardo Habkost
The APIC ID compatibility code is required only for PC, and now that x86_cpu_initfn() doesn't use x86_cpu_apic_id_from_index() anymore, that code can be moved to pc.c. Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
2015-03-09Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into stagingPeter Maydell
pci, pc, virtio fixes and cleanups A bunch of fixes all over the place. All of ACPI refactoring has been merged. Legacy pci commands have been dropped. virtio header cleanup initial patches from virtio-1.0 branch Signed-off-by: Michael S. Tsirkin <mst@redhat.com> * remotes/mst/tags/for_upstream: (130 commits) acpi: drop unused code aml-build: comment fix acpi-build: fix typo in comment acpi: update generated files vhost user:support vhost user nic for non msi guests aml-build: fix build for glib < 2.22 acpi: update generated files Makefile.target: binary depends on config-devices acpi-test-data: update after pci rewrite acpi, mem-hotplug: use PC_DIMM_SLOT_PROP in acpi_memory_plug_cb(). pci-hotplug-old: Has been dead for five major releases, bury pci: Give a few helpers internal linkage acpi: make build_*() routines static to aml-build.c pc: acpi: remove not used anymore ssdt-[misc|pcihp].hex.generated blobs pc: acpi-build: drop template patching and create PCI bus tree dynamically tests: ACPI: update pc/SSDT.bridge due to new alg of PCI tree creation pc: acpi-build: simplify PCI bus tree generation tests: add ACPI blobs for qemu with bridge cases tests: bios-tables-test: add support for testing bridges tests: ACPI test blobs update due to PCI0._CRS changes ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Conflicts: hw/pci/pci-hotplug-old.c
2015-03-08acpi: drop unused codeMichael S. Tsirkin
Recent changes left acpi_get_hex unused, and clag is unhappy about it: error: unused function 'acpi_get_hex' Drop it, as well as some unused macros. Signer-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-08acpi-build: fix typo in commentMichael S. Tsirkin
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-04acpi: update generated filesMichael S. Tsirkin
Fixes up build on systems without iasl. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-03Merge remote-tracking branch 'remotes/armbru/tags/pull-error-2015-02-26' ↵Peter Maydell
into staging QemuOpts: Convert various setters to Error # gpg: Signature made Thu Feb 26 13:56:43 2015 GMT using RSA key ID EB918653 # gpg: Good signature from "Markus Armbruster <armbru@redhat.com>" # gpg: aka "Markus Armbruster <armbru@pond.sub.org>" * remotes/armbru/tags/pull-error-2015-02-26: qtest: Use qemu_opt_set() instead of qemu_opts_parse() pc: Use qemu_opt_set() instead of qemu_opts_parse() qemu-sockets: Simplify setting numeric and boolean options block: Simplify setting numeric options qemu-img: Suppress unhelpful extra errors in convert, amend QemuOpts: Propagate errors through opts_parse() QemuOpts: Propagate errors through opts_do_parse() QemuOpts: Drop qemu_opt_set(), rename qemu_opt_set_err(), fix use block: Suppress unhelpful extra errors in bdrv_img_create() qemu-img: Suppress unhelpful extra errors in convert, resize QemuOpts: Convert qemu_opts_set() to Error, fix its use QemuOpts: Convert qemu_opt_set_number() to Error, fix its use QemuOpts: Convert qemu_opt_set_bool() to Error, fix its use Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2015-03-03Revert "Merge remote-tracking branch ↵Peter Maydell
'remotes/ehabkost/tags/x86-pull-request' into staging" This reverts commit b8a173b25c887a606681fc35a46702c164d5b2d0, reversing changes made to 5de090464f1ec5360c4f30faa01d8a9f8826cd58. (I applied this pull request when I should not have done so, and am now immediately reverting it.) Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2015-03-02acpi: update generated filesMichael S. Tsirkin
Fixes up build on systems without iasl. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-02Merge remote-tracking branch 'remotes/ehabkost/tags/x86-pull-request' into ↵Peter Maydell
staging * remotes/ehabkost/tags/x86-pull-request: target-i386: Move APIC ID compatibility code to pc.c target-i386: Require APIC ID to be explicitly set before CPU realize target-i386: Set APIC ID using cpu_index on CONFIG_USER linux-user: Check for cpu_init() errors target-i386: Move CPUX86State.cpuid_apic_id to X86CPU.apic_id target-i386: Simplify error handling on cpu_x86_init_user() target-i386: Eliminate cpu_init() function target-i386: Rename cpu_x86_init() to cpu_x86_init_user() target-i386: Move topology.h to include/hw/i386 target-i386: Eliminate unnecessary get_cpuid_vendor() function target-i386: Simplify listflags() function Conflicts: target-i386/cpu.c Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2015-03-02Merge remote-tracking branch 'remotes/afaerber/tags/qom-devices-for-peter' ↵Peter Maydell
into staging QOM infrastructure fixes and device conversions * Assertion fix for device_add with non-device types * Documentation fix * qdev_init() error reporting cleanups # gpg: Signature made Tue Feb 24 13:56:33 2015 GMT using RSA key ID 3E7E013F # gpg: Good signature from "Andreas Färber <afaerber@suse.de>" # gpg: aka "Andreas Färber <afaerber@suse.com>" * remotes/afaerber/tags/qom-devices-for-peter: parallel: parallel_hds_isa_init() shouldn't fail parallel: Factor out common parallel_hds_isa_init() serial: serial_hds_isa_init() shouldn't fail serial: Factor out common serial_hds_isa_init() etsec: Replace qdev_init() by qdev_init_nofail() leon3: Replace unchecked qdev_init() by qdev_init_nofail() ide/isa: Replace unchecked qdev_init() by qdev_init_nofail() qdev: Improve qdev_init_nofail()'s error reporting qom: Fix typo, 'my_class_init' -> 'derived_class_init' qdev: Avoid type assertion in qdev_build_hotpluggable_device_list() Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2015-03-02Merge remote-tracking branch 'remotes/ehabkost/tags/numa-pull-request' into ↵Peter Maydell
staging NUMA fixes queue # gpg: Signature made Mon Feb 23 19:28:42 2015 GMT using RSA key ID 984DC5A6 # gpg: Can't check signature: public key not found * remotes/ehabkost/tags/numa-pull-request: numa: Rename set_numa_modes() to numa_post_machine_init() numa: Rename option parsing functions numa: Move QemuOpts parsing to set_numa_nodes() numa: Make max_numa_nodeid static numa: Move NUMA globals to numa.c vl.c: Remove unnecessary zero-initialization of NUMA globals numa: Move NUMA declarations from sysemu.h to numa.h Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2015-03-01pc: acpi: remove not used anymore ssdt-[misc|pcihp].hex.generated blobsIgor Mammedov
Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi-build: drop template patching and create PCI bus tree dynamicallyIgor Mammedov
Replace AML template patching with direct composing of PCI device entries in C. It allows to simplify PCI tree generation further and saves us about 400LOC scattered through different files, confining tree generation to one C function which is much easier to deal with. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi-build: simplify PCI bus tree generationIgor Mammedov
it basicaly does the same as original approach, * just without bus/notify tables tracking (less obscure) which is easier to follow. * drops unnecessary loops and bitmaps, creating devices and notification method in the same loop. * saves us ~100LOC Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi-build: drop template patching and create Device(SMC) dynamicallyIgor Mammedov
patch moves SMC device into SSDT and creates it only when device is present, which makes ACPI tables smaller in default case when device is not present. Also it fixes wrong IO range in CRS if "iobase" property is set to a non default value. PS: Testing with XP shows that current default "iobase" used SMC device conflicts with floppy controller IO, but it's topic for another patch and I'd leave it to SMC device author for resolving conflict. Signed-off-by: Igor Mammedov <imammedo@redhat.com> CC: agraf@suse.de Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: export applesmc IO port/lenIgor Mammedov
IO port and length will be used in following patch to correctly generate SMC ACPI device in SSDT. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi-build: drop remaining ssdt_misc templateIgor Mammedov
It drops empty ssdt_misc templete. It also hides from user almost all pointer arithmetic when building SSDT which makes resulting code a bit cleaner and concentrating only on composing ASL construct /i.e. a task build_ssdt() should be doing/. Also it makes one binary blob less stored in QEMU source tree by removing need to keep and update hw/i386/ssdt-misc.hex.generated file here in total saving us ~430LOC. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi: drop manual hole punching for GPE0 resourcesIgor Mammedov
Drops manual hole punching in PCI0._CRS on PIIX4 machine type for GPE0 resources. Resources will be consumed by Device(GPE0) that is attached to PCI namespace. There is GPE device with HID ACPI0006 since ACPI2.0 that should be used for this purpose but none of Windows versions support it and show it as "unknown device", so reserve resource in old fashioned way with PNP0A06 device to make windows happy and actually reserve resources. Along with last hole _CRS layout of PIIX4 machine becomes the same as Q35 one, so merge them together and use the same _CRS for both machine types. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi: drop manual hole punching for CPU hotplug resourcesIgor Mammedov
Drops manual hole punching in PCI0._CRS on PIIX4 machine type for CPU hotplug resources. Resources will be consumed by Device(PRES) that is attached to PCI bus. The same way how it currently works for mem hotlpug. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi: drop manual hole punching for PCI hotplug resourcesIgor Mammedov
Drops manual hole punching in PCI0._CRS for PIIX4 machine type. Resources will be consumed by Device(PHPR) that cwis attached to PCI bus. The same way how it currently works for mem hotlpug. Manual hole in PIIX4 _CRS wasn't correct anyway since it was legacy size 0xF while current PCIHP MMIO region is of size 0x14. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-03-01pc: acpi-build: create PCI0._CRS dynamicallyIgor Mammedov
Replace template patching and runtime calculation in _CRS() method with static _CRS defined in SSDT. No functional change except of as mentined above and _CRS being moved from DSDT to SSDT. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: Use qemu_opt_set() instead of qemu_opts_parse()Markus Armbruster
Less code, same result. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
2015-02-26acpi: drop unused generated filesMichael S. Tsirkin
drop ssdt-mem.hex.generated and ssdt-proc.hex.generated: dsl files have been removed previously. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26acpi: update generated hex filesMichael S. Tsirkin
Used for IASL builds. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: reserve PCIHP MMIO resourcesIgor Mammedov
Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: create memory hotplug IO region dynamicallyIgor Mammedov
it replaces a static complied in DSDT MMIO region for memory hotplug with one created at runtime leaving only truly static memory hotplug related ASL bits in DSDT. And replaces template patching of MEMORY_SLOTS_NUMBER value with ASL API created named value. Later it also would make easier to reuse current ACPI memory hotplug on other targets. Also later it would be possible to move remaining memory hotplug ASL methods into build_ssdt() and add all memory hotplug related AML into SSDT only when memory hotplug is enabled, further reducing ACPI tables blob if memory hotplug isn't used. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: drop template patching and memory hotplug objects dynamicallyIgor Mammedov
in addition it saves us ~330LOC and makes it one binary blob less stored in QEMU source tree by removing need to keep and update hw/i386/ssdt-mem.hex.generated file there. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: create CPU hotplug IO region dynamicallyIgor Mammedov
it replaces a static complied in DSDT MMIO region for CPU hotplug with one created at runtime leaving only truly static CPU hotplug related ASL bits in DSDT. It also puts CPU_HOTPLUG_RESOURCE_DEVICE into PCI0 scope and reserves resources from it, preparing for dropping manual hole punching in PCI0._CRS. Later it also would make easier to reuse current ACPI CPU hotplug on other targets. Also later it would be possible to move remaining CPU hotplug ASL methods into build_ssdt() and add all CPU hotplug related AML into SSDT only when CPU hotplug is enabled, further reducing ACPI tables blob if CPU hotplug isn't used. impl. detail: Windows XP can't handle /BSODs/ OperationRegion declaration in DSDT when variable from SSDT is used for specifying its address/length and also when Field declared in DSDT with OperationRegion from SSDT if DSDT is being parsed before SSDT. But it works just fine when referencing named fields from another table. Hence OperationRegion and Field declaration are moved to SSDT to make XP based editions work. PS: Later Windows editions seem to be fine with above conditions. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: drop template patching and CPU hotplug objects dynamicallyIgor Mammedov
in addition it saves us ~400LOC and makes it one binary blob less stored in QEMU source tree by removing need to keep and update hw/i386/ssdt-proc.hex.generated file there. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: generate pvpanic device description dynamicallyIgor Mammedov
Drops AML template patching and allows to save some space in SSDT if pvpanic device doesn't exist by not including disabled device description into SSDT. It also makes device description smaller by replacing _STA method with named value and dropping _INI method. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: generate _S[345] packages dynamicallyIgor Mammedov
Replaces template patching with packages composed using AML API. Note on behavior change: If S3 or S4 is disabled, respective packages won't be created and put into SSDT. Which saves us some space in SSDT and doesn't confuse guest OS with mangled package names as it was done originally. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26acpi: add aml_int() termIgor Mammedov
* factor out ACPI const int packing out of build_append_value() and rename build_append_value() to build_append_int_noprefix() it will be reused for adding a plain integer value into AML. will be used by is aml_processor() and CRS macro helpers * extend build_append_int{_noprefix}() to support 64-bit values it will be used PCI for generating 64bit _CRS entries Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: use aml_scope() for \_SB scopeIgor Mammedov
prepares for incremental conversion of SSDT content to AML API Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi: use local var for accessing ACPI tables blob in acpi_build()Igor Mammedov
except of shortening of lines and making code a bit more readable, it will reduce renaming noise when changing tables blob from GArray* to Aml* type. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26acpi-build: skip hotplugged bridgesMichael S. Tsirkin
hotplugged bridges don't get bsel allocated so acpi hotplug doesn't work for them anyway. OTOH adding them in ACPI creates a host of problems, e.g. they can't be hot-unplugged themselves which is surprising to users. So let's just skip these. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26acpi-build: simplify rsdp management for legacyMichael S. Tsirkin
For legacy machine types, rsdp is not in RAM, so we need a copy of rsdp for fw cfg. We previously used g_array_free with false parameter, but this seems to confuse people. This also wastes a bit of memory as the buffer is unused for new machine types. Let's just use plain g_memdup, and free original memory together with the array. TODO: rationalize tcpalog memory management, and get rid of the mfre parameter. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com>
2015-02-26acpi: has_immutable_rsdp->!rsdp_in_ramMichael S. Tsirkin
As comment in acpi-build.c notes, RSDP is not really immutable. So it's really a question of whether it's in RAM, name the variable accordingly. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com>
2015-02-26acpi-build: fix ACPI RAM managementMichael S. Tsirkin
This fixes multiple issues around ACPI RAM management: RSDP and linker RAM aren't currently marked dirty on update, so they won't be migrated correctly. Let's handle all tables in the same way: set correct size (assert if too big), update, mark RAM dirty. This also drops assert checking that table size didn't change: table size is fundamentally dynamic and depends on hw configuration, just set the correct size and use that (memory core asserts if size is too large). This also means we can drop tracking table size, memory core does this for us now. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pc: acpi-build: migrate RSDP tableIgor Mammedov
Makes sure that RSDP stays the same /i.e. matches ACPI tables blob in source/ if guest is migrated during RSDP reading or has been already shadowed by firmware. Fix applies only to new machine types starting from 2.3, so it won't break migration for old machine types. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Marcel Apfelbaum <marcel@redhat.com>
2015-02-26pc: acpi-build: update linker on guest accessIgor Mammedov
Linker table is build only once, so if later during tables rebuild sizes of other ACPI tables change pointers will be patched incorrectly due to wrong offsets in linker. Resulting in guest not being able to find ACPI tables. Fix it by updating 'linker' table with the rest of tables when firmware reads it. Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Marcel Apfelbaum <marcel@redhat.com>
2015-02-26acpi: update RSDP on guest accessMichael S. Tsirkin
RSDT offset can change across reboots and that makes immutable RSDP, which is build at startup, point to incorrect place in ACPI table blob. That results in BIOS corrupting tables and guest OS failing to find ACPI tables. We really should have put it in a ROM region, but we can't change that for old machine types, let's just set the callback and update it explicitly. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Marcel Apfelbaum <marcel@redhat.com>
2015-02-26pc: memory: Validate alignment of maxram_size to page sizePeter Krempa
If the maxram_size is not aligned and dimm devices were added on the command line qemu would terminate with a rather unhelpful message: ERROR:hw/mem/pc-dimm.c:150:pc_dimm_get_free_addr: assertion failed: (QEMU_ALIGN_UP(address_space_size, align) == address_space_size) In case no dimm device was originally added on the commandline qemu exits on the assertion failure. Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com>
2015-02-26acpi, pc: Add unplug cb for pc machine.Tang Chen
Memory and CPU hot unplug are both asynchronous procedures. When the unplug operation happens, unplug request cb is called first. And when guest OS finished handling unplug, unplug cb will be called to do the real removal of device. This patch adds hotunplug cb to pc machine, which memory and CPU hot unplug will use it. Reviewed-by: Igor Mammedov <imammedo@redhat.com> Signed-off-by: Tang Chen <tangchen@cn.fujitsu.com> Signed-off-by: Zhu Guihua <zhugh.fnst@cn.fujitsu.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26acpi, pc: Add hotunplug request cb for pc machine.Tang Chen
Memory and CPU hot unplug are both asynchronous procedures. They both need unplug request callback to initiate unplug operation. Add unplug handler to pc machine that will be used by following CPU and memory unplug patches. Reviewed-by: Igor Mammedov <imammedo@redhat.com> Signed-off-by: Tang Chen <tangchen@cn.fujitsu.com> Signed-off-by: Zhu Guihua <zhugh.fnst@cn.fujitsu.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2015-02-26pci-assign: Convert to realizeMarkus Armbruster
Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Reviewed-by: Gonglei <arei.gonglei@huawei.com>
2015-02-26acpi: drop min-bytes in build_package()Igor Mammedov
Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Claudio Fontana <claudio.fontana@huawei.com> Reviewed-by: Marcel Apfelbaum <marcel@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>