summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2009-11-15PCI: make duplicate devfn allocation fatalBlue Swirl2-5/+3
Only two callers of pci_create_simple/pci_register_device bothered to check the return value. Other cases were prone to crashing with spurious NULL pointer dereferences. Make QEMU exit with an error message when devfn is attempted to be duplicated, also applies to case when the bus is full. Remove checks. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-11-14Do not execute shell scripts directlymalc1-1/+1
Signed-off-by: malc <av1474@comtv.ru>
2009-11-14mips malta: fix indentationAurelien Jarno1-3/+3
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14target-mips: fix indentationAurelien Jarno2-3/+3
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14mips-malta: fix resetAurelien Jarno1-25/+27
(broken by 45a50b1668822c23afc2a89f724654e176518bc4) Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14mips: fix cpu_reset memory leakBlue Swirl3-56/+54
Remove cpu_mips_register() - move mmu_init(), fpu_init() and mvp_init() into cpu_mips_init() - move the other parts in cpu_mips_init() Reported-by: Blue Swirl <blauwirbel@gmail.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14fix make clean targetsMagnus Damm1-2/+3
This patch fixes clean in case of missing directories and also adds code to distclean that removes the following files: qemu-monitor.texi roms/seabios/config.mak roms/vgabios/config.mak Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14sh4 disasm fixesMagnus Damm2-1/+4
Add the sh4 target to the monitor disassembly function, and remove a duplicate "0x" printout from the sh4 dis- assembly code. Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14tcg/i386: remove duplicate sar opcodeMagnus Damm1-1/+0
Signed-off-by: Magnus Damm <damm@opensource.se> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14pci: Fix function pci_default_write_configStefan Weil1-3/+3
Change 260c0cd3d985e51b15870ff47e17b7b930efbda1 (pci: use range helper functions) introduced a bug which made pci cirrus vga on mips malta (and maybe other pci devices) fail. Don't change addr - its original value is needed by ranges_overlap() and range_covers(). Signed-off-by: Stefan Weil <weil@mail.berlios.de> Acked-by: Ryan Harper <ryanh@us.ibm.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-14mips: fix CPU resetAurelien Jarno3-20/+36
Don't load the kernel twice during reset. See f2d74978764f62d832d61ac17bb5d934ade58816. Signed-off-by: Blue Swirl <blauwirbel@gmail.com> Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-11-13Fix PPC crashBlue Swirl1-1/+1
Because of a typo, structure field vga_bios_size was not initialized properly and a bogus BAR6 for the nonexistent VGA BIOS appeared. The bug was uncovered by c169998802505c244b8bcad562633f29de7d74a4. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-11-13ARM MPCore tweaksPaul Brook4-47/+131
Allow the user to specify the number of cores present on the RealView EB + ARM11MPCore board. Also split into its own config rather than guessing from the CPU name. Signed-off-by: Paul Brook <paul@codesourcery.com>
2009-11-13Realview/EB procid hacksPaul Brook4-6/+18
Guess core tile ID based on CPU type. Signed-off-by: Paul Brook <paul@codesourcery.com>
2009-11-12pci: fix the conversion of config field from array to pointerJuan Quintela1-2/+2
Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12qemu_system_reset: we need to call it before loadvm/migrationJuan Quintela1-1/+1
Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12fdc: fix vmstate variable passedJuan Quintela1-4/+29
When code was transformed to use qdev_reset/vmstate registration, vmstate was passed a variable of the wrong type Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12vnc: improve capslock handling.Gerd Hoffmann1-0/+21
When capslock is toggled while the vnc window hasn't the focus qemu will miss the state change. Add sanity checks for the capslock state and toggle it if needed, so hosts and guests idea of capslock state stay in sync. Simliar logic for numlock is present in qemu already. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12e1000 fix: read access to some registers is missing.Kay Ackermann1-0/+2
While writing working on an e1000 driver for my university's OS I noticed that some registers aren't readable in QEMU, but they should be readable as stated in Intels Driver Developer Manual (and also verified on real hardware). Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12Fix 32-bit overflow in parallels image supportDavid Woodhouse1-2/+3
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12kvm ppc: Remove unused labelHollis Blanchard1-1/+0
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12kvm: Move KVM mp_state accessors to i386-specific codeHollis Blanchard3-23/+20
Unbreaks PowerPC and S390 KVM builds. Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12virtio-blk: Pass read errors to the guestKevin Wolf1-1/+1
We need to signal not only write errors, but also read errors to the guest driver. This fixes a regression introduced by 869a5c6d. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12savevm: Delete existing snapshots in all imagesKevin Wolf1-19/+39
When creating a snapshot we can run into the situation that the first disk doesn't have a snapshot, but the second one does have one with the same name as the new snapshot. In this case, qemu doesn't recognize that there is a snapshot to be overwritten, so it starts to save the new snapshot and errors out later when it tries to snapshot the second image. With this patch, snapshots on secondary images are overwritten just like on the first image. Reported-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12Fix incoming migrationJuan Quintela1-1/+6
commit b04c4134d6de28c249277de19e523bfbe4aebbd6 broke incoming migration. After talking with Gleb, code was intended to be the way is in this fix. This fixes migration here. Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12fix type in CFLAGS nameJuan Quintela1-1/+1
Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12fix parallel buildJuan Quintela3-6/+10
Based on a ideas of Daniel Jacobowitz + Stefan Weil Signed-off-by: Juan Quintela <quintela@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12qdev: Check if unplug handler exists before calling itAmit Shah1-0/+2
A bus may have hotplugging enabled but not have the 'unplug' callback defined, which would lead to a crash on trying to unplug a device on the bus. Fix by introducing an assert to check if the callback is valid. Signed-off-by: Amit Shah <amit.shah@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12Makefile: Fix definition of pxe-*.bin blobsStefan Weil1-2/+3
* Remove 2nd entry for pxe-pcnet.bin. This kind of error can be avoided by sorting entries. So all pxe-*.bin entries are now sorted alphabetically. * Rename pxe-eepro100.bin -> pxe-i82559er.bin. This change completes another patch which did the rename on the pxe image for i82559er. Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12eepro100: Add missing .exit initialisationStefan Weil1-0/+9
Some devices did not have an initialisation value for entry ".exit". This is fixed here. Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12eepro100: Fix boot ROM supportStefan Weil2-0/+11
* Rename pxe-eepro100.bin to pxe-i82559er.bin. The other devices supported by eepro100.c need additional pxe boot ROM images. * Call rom_add_option during initialisation. The code won't work with two or more different eepro100 devices, because it only adds one option ROM, but this use case is perhaps never needed. Using this patch, model=i82559er at least works partially. For full support, more eepro100 patches are needed (will follow later, can be fetched from ar7 branch of QEMU). Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12Makefile: Prettify loggingStefan Weil1-1/+1
Replace GEN config-all-devices.mak by GEN config-all-devices.mak Like this, the logging output is column aligned. Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12serial: Add interface to set reference oscillator frequencyStefan Weil2-0/+8
Many (most?) serial interfaces have a programmable clock which provides the reference frequency ("baudbase"). So a fixed baudbase which is only set once can be wrong. omap1.c is an example which could use the new interface to change baudbase when the programmable clock changes. ar7 system emulation (still not part of standard QEMU) is similar to omap and already uses serial_set_frequency. Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-12microblaze: Move the kcmdline out of the way.Edgar E. Iglesias1-1/+1
Avoids rom overlap conflicts. Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-11-12microblaze: Restore env when raising unmapped bus access.Edgar E. Iglesias1-0/+2
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-11-12microblaze: Unbreak reset.Edgar E. Iglesias1-27/+26
Initialize synthesis config registers at reset to cope with the new cpu_reset sequences. Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-11-11Fix ARM MCore secondary cpu bootPaul Brook3-9/+27
Make MPCore secondary cpu initialization work with the new reset handling. Also change the inital FLAG value from 3 to zero to match recent kenrels. Signed-off-by: Paul Brook <paul@codesourcery.com>
2009-11-11Reject late rom loadingPaul Brook1-0/+7
rom_+add_file/rom_add_blob only work correctly if called before load_all_roms. Enforce this rather than silently accepting and putting the rom in the wrong place at reset. Signed-off-by: Paul Brook <paul@codesourcery.com>
2009-11-11Fix ARM system emulationPaul Brook2-28/+41
Since 45a50b1 load_image_targphys should only be called once. ARM boards incorrectly call it every time the system is reset. Signed-off-by: Paul Brook <paul@codesourcery.com>
2009-11-09QemuOpts: command line switches for the config file.Gerd Hoffmann2-0/+35
Adds -readconfig and -writeconfig command line switches to read/write QemuOpts from config file. In theory you should be able to do: qemu < machine config cmd line switches here > -writeconfig vm.cfg qemu -readconfig vm.cfg In practice it will not work. Not all command line switches are converted to QemuOpts, so you'll have to keep the not-yet converted ones on the second line. Also there might be bugs lurking which prevent even the converted ones from working correctly. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09QemuOpts: parse config from file.Gerd Hoffmann2-0/+51
Add functions to parse QemuOpts from a git-style config file. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09QemuOpts: dump config.Gerd Hoffmann2-0/+41
Add a function to write the QemuOpts configuration to a git-style config file. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09QemuOpts: add find_list()Gerd Hoffmann1-9/+20
Factor out the QemuOptsList search code for upcoming users. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09Documentation: Add options to image format descriptionsKevin Wolf1-1/+45
Explain the existing format specific options that can be used with qemu-img create/convert -o ... Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09Documentation: Don't mention old qemu-img optionsKevin Wolf3-31/+21
The old options are still supported for compatibility, but they are inconsistent (for example create -b vs. convert -B for backing files) and incomplete (-F only exists for create) which tends to confuse people. Remove all references to the old options from the documentation to guide users to the more consistent -o options. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09Documentation: Move image format descriptions to own sectionKevin Wolf1-37/+41
The description of the image formats is too long to be a subitem of a parameter description. It will become even longer when we include the options provided by the respective format. Signed-off-by: Kevin Wolf <kwolf@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09Documentation: Add documentation for -chardevMatthew Booth1-4/+230
Adds documentation for all -chardev backends. Signed-off-by: Matthew Booth <mbooth@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09Added imlpementation for qemu_error for non-qemu executablesNaphtali Sprei1-0/+9
Now qemu_error can be called also from shared files, e.g. block.c. Signed-off-by: Naphtali Sprei <nsprei@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09eepro100: Improve support for different devicesStefan Weil1-25/+143
* Add device properties (size of statistical data, extended tcb support) to EEPRO100State and set these values for the different devices. * Fix PCI configuration for existing devices. * Add initialisation code for missing devices. * Remove function device_supports_eTxCB. It is no longer needed. * Fix dump of statistical data. It now respects the real size of the statistical data. An endianess issue was fixed here, too. * CU_SHOWSTATS, CU_DUMPSTATS now write a completion value after the statistical data. There is no need to keep this value in eepro100_stats_t, so member "complete" could be removed. Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-11-09pci/monitor: print out bridge's filtering values and so on.Isaku Yamahata1-0/+25
make pci_info_device() print out bridge's filtering value like io base/limit, subbus and subordinate bus. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Acked-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>