Cocoa: Silence type warning
Add const for "qemu" character literal, to avoid:
warning: initialization discards qualifiers from pointer target type
An earlier patch by John proposed to use char5. Since we do not modifythe text and later copy it into malloc'ed memory, marking it as const...
Cocoa: Fix compilation on Mac OS X v10.4 and earlier
NSView's enterFullScreenMode:withOptions: andexitFullScreenModeWithOptions: are available on v10.5and later only. Undefined methods raise warnings andundefined constants result in errors.
Reported by Ryan Schmidt....
Cocoa: ppc64 host support
Fix integer usage in the Cocoa backend: NSInteger is long on LP64.
http://developer.apple.com/mac/library/documentation/Cocoa/Reference/ApplicationKit/Classes/NSView_Class/Reference/NSView.html#//apple_ref/doc/uid/20000014-BBCFHHCD...
Cocoa: Silence warning for cocoa_keycode_to_qemu
Make cocoa_keycode_to_qemu static, to avoid:
warning: no previous prototype for ‘cocoa_keycode_to_qemu’
Signed-off-by: Andreas Färber <andreas.faerber@web.de>Cc: John Arbuckle <programmingkidx@gmail.com>...
Cocoa: Silence warning on Big Endian host
LITTLE_ENDIAN is undefined on Big Endian host.
Signed-off-by: Andreas Färber <andreas.faerber@web.de>Cc: John Arbuckle <programmingkidx@gmail.com>Signed-off-by: malc <av1474@comtv.ru>
sparc64: clear exception_index with -1 value
Signed-off-by: Igor V. Kovalenko <igor.v.kovalenko@gmail.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Merge remote branch 'mst/for_anthony' into staging
pass env to raise_exception if called outside of op_helper code
- this fixes stepping with gdb, where do_unassigned_access may be called from gdb handler, outside of generated code
sparc64: switch to MMU global registers in more MMU related traps
- extended range of MMU related traps which use MMU global registers, as listed in Ultrasparc-IIi document- no visible changes, since emulation do not cause added traps
Signed-off-by: Igor V. Kovalenko <igor.v.kovalenko@gmail.com>...
target-i386: Fix "call im" on x86_64 when executing 32-bit code
Similarly to what is done in 32938e127f50a40844a0fb9c5abb8691aeeccf7efor "jmp im", trunc the immediate to 32-bit when not running in 64-bitmode.
Reported-by: Kevin O'Connor <kevin@koconnor.net>...
loader: don't call realloc(non_null, 0) when no symbols are present
According to C99, realloc(non_null, 0) != free(non_null), that's whyit is forbidden in QEMU.
When there are no symbols, nsyms equals to 0. Free the syms structureand set it to NULL instead of reallocating it with a size of 0....
Sparc64: split DPRINTF into CPUIRQ and EBUS versions
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Sparc64: fix compile with DEBUG_IRQ enabled
sdl: print the reason why SDL thinks SDL_Init failed before exiting
Signed-off-by: malc <av1474@comtv.ru>
Add missing newline at the end of options list
In qemu-kvm this place looks even more "interesting":
-runas user Change to user id user just before starting the VM. -readconfig <file> -writeconfig <file> read/write config file-no-kvm disable KVM hardware virtualization...
Update Sparc64 OpenBIOS image to r649.
Sparc64: move APB PCI memory base to correct location
PCI: Fix bus address conversion
Pass physical addresses to map functions instead of PCI bus addresses.
sparc: make command line available also via firmware configuration device
tcg: Add tcg_unsigned_cond.
Returns an unsigned version of a signed condition;returns the original condition otherwise.
Signed-off-by: Richard Henderson <rth@twiddle.net>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
block/bochs: improve format checking
block.c: fix warning with _FORTIFY_SOURCE
CC block.occ1: warnings being treated as errorsblock.c: In function 'bdrv_open2':block.c:400: error: ignoring return value of 'realpath', declared with attribute warn_unused_result
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>...
block/bochs.c: fix warning with _FORTIFY_SOURCE
CC block/bochs.occ1: warnings being treated as errorsblock/bochs.c: In function 'seek_to_sector':block/bochs.c:202: error: ignoring return value of 'read', declared with attribute warn_unused_result...
savevm.c: fix warning with _FORTIFY_SOURCE
CC savevm.occ1: warnings being treated as errorssavevm.c: In function 'file_put_buffer':savevm.c:342: error: ignoring return value of 'fwrite', declared with attribute warn_unused_resultmake: *** [savevm.o] Error 1...
slirp/misc.c: fix warning with _FORTIFY_SOURCE
CC slirp/misc.occ1: warnings being treated as errorsslirp/misc.c: In function 'fork_exec':slirp/misc.c:209: error: ignoring return value of 'write', declared with attribute warn_unused_resultmake: *** [slirp/misc.o] Error 1...
hw/pc.c: fix warnings with _FORTIFY_SOURCE
CC i386-softmmu/pc.occ1: warnings being treated as errors/usr/src/RPM/BUILD/qemu-0.11.92/hw/pc.c: In function 'load_multiboot':/usr/src/RPM/BUILD/qemu-0.11.92/hw/pc.c:614: error: ignoring return value of 'fread', declared with attribute warn_unused_result...
path.c fix warning with _FORTIFY_SOURCE
CC libuser/path.occ1: warnings being treated as errors/usr/src/RPM/BUILD/qemu-0.11.92/path.c: In function 'new_entry':/usr/src/RPM/BUILD/qemu-0.11.92/path.c:49: error: ignoring return value of 'asprintf', declared with attribute warn_unused_result...
PCI: partially revert 2e01c8cf4b076b05013c87723e3fc710b50a0a7a
Bus address conversion was not correct.
PCI: make pci_mem_base private
Make pci_mem_base private to PCIBus. Add a function to set it.
Fix Sparse error: dubious one-bit signed bitfield
Fix Sparse warning: dubious: !x & y
scsi: fix Sparse warning: Initializer entry defined twice
Both REWIND and REZERO_UNIT use 0x01, READ_POSITION and PRE_FETCHshare 0x34.
MAC DBDMA: store register values in native endianness
Store the register values in native endianness, by dropping all theendianness conversion functions, and converting the endianness indbdma_readl/dbdma_writel instead.
Also guard the endianness conversion with TARGET_WORDS_BIGENDIAN to...
Intel CPUs starting from pentium have apic
Intel CPUs starting from pentium have apic. Lets advertise it.
Signed-off-by: Gleb Natapov <gleb@redhat.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
loader: more ignores for rom intended to be loaded by the bios
Similarly to what has been done in e405a2ba91b68817cae2a428de55fe9616a4cf37,ignore rom intended to be loaded by the bios in find_rom() and rom_copy().
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Don't load options roms intended to be loaded by the bios in qemu
The first such option rom will load at address 0, which isn't very nice,and the second will report a conflict and abort, which is horrible.
Signed-off-by: Avi Kivity <avi@redhat.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
target-arm: fix strexd
linux-user: fix build with gcc-4.1
linuxboot.bin is a generated file
Signed-off-by: Juan Quintela <quintela@redhat.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
qemu-nbd: fix OpenBSD linker warning
e1000: add link to data sheet
Link to data sheet at intel.com so people can find it.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
qemu-io: suppress a warning with gcc 4.0.2
Compile qemu-nbd also on OpenBSD and Solaris
basename() needs #include <libgen.h>.
No prototype for daemon() is available on Solaris, but linksucceeds.
piix_pci: use range helper function
use range helper function in i440fx_write_config().
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
piix_pci: add link to i440fx data sheet.
add link to i440fx data sheet.
list MST as pci layer maintainer
List MST as PCI maintainer so that people knowwhom to Cc on patches.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
ne2000: switch to symbolic names for pci registers
No functional changes. I verified that the generated binarydoes not change.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>Acked-by: Juan Quintela <quintela@redhat.com>Acked-by: Glauber Costa <glommer@gmail.com>
rtl: switch to symbolic names for pci registers
pcnet: switch to symbolic names for pci registers
pci: add more status bits
will be used by eepro100.
eepro100: symbolic names for pci registers
No functional changes. I verified that the generated binarydoes not change in meaningful ways.
piix: symbolic constants
cmd646: symbolic names for pci registers
vmware_vga: symbolic names for pci registers
lsi: symbolic names for pci registers
pci: add another devsel macro
will be used by ensoniq emulation
es1370: symbolic names for pci registers
wdt_i6300esb: symbolic names for pci registers
ac97: symbolic names for pci registers
usb-uhci: symbolic names for pci registers
usb-ohci: symbolic names for pci registers
pci: remove unused macro
PCI_STATUS_DEVSEL is unused, and it alsohas a different name in pci_regs.hRemove.
pci: remove PCIBus::config_reg.
PCIBus::config_reg isn't used anymore, so remove it.
pci: s/PCI_SUBVENDOR_ID/PCI_SUBSYSTEM_VENDOR_ID/g
To match Linux PCI register definition,rename PCI_SUBVENDOR_ID to PCI_SUBSYSTEM_VENDOR_ID.
pci: import Linux pci_regs.h
Import Linux pci_regs.h. Later PCI register definitions in pci.hwill be eliminated.
pci: use pci_regs.h
include pci_regs.h and remove duplicated defines.And remove unused PCI_REVISION and PCI_SUBDEVICE_ID.
gt64xxx: remove gt64120_{read, write}_config().
They call only pci_default_{read, write}_config().So they aren't necessary.
acpi: use range helper function.
use range helper function in pm_write_config().
msix: use range helper function.
use range helper function in msix_write_config().
piix_pci: define symbolic value for PAM0, PAM6 and SMRAM.
Define symbolic value in i440fx configuration spacefor 0x59, 0x5f and 0x7f and use them.
e1000: switch to symbolic names for pci registers
No functional changes. I verified that the generatedobject binary does not change.
Revert "Revert "pci: interrupt disable bit support""
This reverts commit d587e0787153f0224a6140c5015609963ceaabfb.
USB: Improve usbdevice error messages
When an non-existent USB device is specified on the command line,print "qemu: could not add USB device 'X'".Likewise for the usb_{add,del} monitor commands.
Signed-off-by: Scott Tsai <scottt.tw@gmail.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
target-alpha: Initialize fpcr
Linux, at least, disables exceptions by default.
Signed-off-by: Richard Henderson <rth@twiddle.net>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
tcg-sparc: Implement brcond2.
Split out tcg_out_cmp and properly handle immediate arguments.Fix constraints on brcond to match what SUBCC accepts.Add tcg_out_brcond2_i32 for 32-bit host.
tcg-sparc: Use TCG_TARGET_REG_BITS in conditional compilation.
The test TCG_TARGET_REG_BITS==64 is exactly the feature that weare checking for, whereas something involving sparc_v9 orsparc_v8plus should be reserved for something ISA related,as with SMULX....
tcg-sparc: Improve tcg_out_movi for sparc64.
Generate sign-extended 32-bit constants with SETHI+XOR.Otherwise tidy the routine to avoid the need forconditional compilation and code duplication with movi_imm32.
Signed-off-by: Richard Henderson <rth@twiddle.net>...
tcg-sparc: Fix imm13 check in movi.
We were unnecessarily restricting imm13 constants to 12 bits.
ARM PBX-A9 memory map tweaks
Add core tile memeory to the RealView PBX-A9 board. Document thememeory maps that are known to work with the qemu bootloader.
Signed-off-by: Paul Brook <paul@codesourcery.com>
LAN9118 improvements
Implement LAN9118 general purpose timer and PHY interrupts. Fix globalinterrupt status bit.
PPC: Make DCR uint32_t
For what I know DCR is always 32 bits wide, so we should also use uint32_t topass it along the stacks.
This fixes a warning when compiling qemu-system-ppc64 with KVM enabled, makingit compile without --disable-werror
Signed-off-by: Alexander Graf <agraf@suse.de>...
PPC64: Fix alternate timebase
Fix the alternate time base the same way as the default timebase. SPR_ATBLshould return a 64-bit value on 64 bit implementations.
PPC64: Fix timebase
On PPC we have a 64-bit time base. Usually (PPC32) this is accessed usingtwo separate 32 bit SPR accesses to SPR_TBU and SPR_TBL.
On PPC64 the SPR_TBL register acts as 64 bit though, so we get the full64 bits as return value. If we only take the lower ones, fine. But Linux...
target-alpha: Emit tcg debug_insn_start.
linux-user: Add aliases for some Alpha syscalls
Alpha always used 32-bit uids, but never renamed the syscallsto match i386 when 32-bit uids were added there. This enablesthe proper bits in syscall.c.
Update OpenBIOS PPC image to revision 647
ppc64: Change default machine to mac99
Also change the New World default CPU to 970FX for ppc64,since the G4 is a 32-bit CPU.
Signed-off-by: Andreas Färber <andreas.faerber@web.de>Acked-by: Alexander Graf <agraf@suse.de>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
cpu-all.h: fix cpu_get_real_ticks() #ifdef
Reported-by: Hervé Poussineau <hpoussin@reactos.org>
Multiboot support: Fix rom_copy
ROMs need to be loaded if they are anywhere in the requested area, notonly at the very beginning. This fixes Multiboot with ELF kernels thathave more than one program header.
Signed-off-by: Kevin Wolf <mail@kevin-wolf.de>...
linux-user: use TARGET_ABI_FMT_lx to print abi_ulong types
linux-user: fix ELF_USE_CORE_DUMP/USE_ELF_CORE_DUMP confusion
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
linux-user: commonify definitions of target typedefs
There's no sense in separately declaring target_{elf_greg,uid,gid,pid}_tfor every architecture. Just declare them once with appropriateUSE_UID16 handling.
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>...
linux-user: fix ARM core dumps on opposite-endian hosts
linux-user: add core dump support for PPC
linux-user: add core dump support for MIPS
linux-user: add core dump support for M68K
linux-user: add core dump support for SH
linux-user: Fix mmap_lock ordering
mmap_lock() can be called while tb_lock() is being held. Toavoid deadlock when one thread is holding mmap_lock and anothertb_lock, always lock first tb_lock().
Signed-off-by: Riku Voipio <riku.voipio@nokia.com>Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
linux-user: cleanup force_sig() calls
Force_sig should be always called with TARGET_ signals.Not that it really matters with SEGV, so this patch isjust for cleanup and improving consistency.
roms: allow roms to be loaded at address 0
It was possible to load roms at address 0, but commit632cf034b401cdd01dae253a8b577fe518e37654 started to forbid that, whichbroke at least ARM versatile.