When QEMU was launched in no-graphic, Curses or VNC mode,
don't run it as a Cocoa application.
Based on patch by Alexander Graf.
v1:
- Avoid type mismatch warning for argv
- Drop noCocoa variable
- Coding Style changes
Signed-off-by: Andreas Färber <andreas.faerber@web.de>
Cc: Alexander Graf <agraf@suse.de>
Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org>
Signed-off-by: malc <av1474@comtv.ru>
NSView's enterFullScreenMode:withOptions: and
exitFullScreenModeWithOptions: are available on v10.5
and later only. Undefined methods raise warnings and
undefined constants result in errors.
Reported by Ryan Schmidt.
While at it, avoid a warning on v10.3.9,
where MAC_OS_X_VERSION_10_4 is not defined.
Spotted by John Arbuckle.
Fix associated comments.
Signed-off-by: Andreas Färber <andreas.faerber@web.de>
Cc: John Arbuckle <programmingkidx@gmail.com>
Cc: Ryan Schmidt <qemu-2009@ryandesign.com>
Cc: Mike Kronenberg <mike.kronenberg@kronenberg.org>
Signed-off-by: malc <av1474@comtv.ru>
Add const for "qemu" character literal, to avoid:
warning: initialization discards qualifiers from pointer target type
An earlier patch by John proposed to use char[5]. Since we do not modify
the text and later copy it into malloc'ed memory, marking it as const
seems sufficient.
Signed-off-by: Andreas Färber <andreas.faerber@web.de>
Cc: John Arbuckle <programmingkidx@gmail.com>
Signed-off-by: malc <av1474@comtv.ru>
__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>
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>
Signed-off-by: malc <av1474@comtv.ru>
- this fixes stepping with gdb, where do_unassigned_access
may be called from gdb handler, outside of generated code
Signed-off-by: Igor V. Kovalenko <igor.v.kovalenko@gmail.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
- 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>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Similarly to what is done in 32938e127f
for "jmp im", trunc the immediate to 32-bit when not running in 64-bit
mode.
Reported-by: Kevin O'Connor <kevin@koconnor.net>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
According to C99, realloc(non_null, 0) != free(non_null), that's why
it is forbidden in QEMU.
When there are no symbols, nsyms equals to 0. Free the syms structure
and set it to NULL instead of reallocating it with a size of 0.
This fixes -kernel with stripped kernels.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
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
-no-kvm-irqchip disable KVM kernel mode PIC/IOAPIC/LAPIC
-no-kvm-pit disable KVM kernel mode PIT
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
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>
CC block.o
cc1: warnings being treated as errors
block.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>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
CC block/bochs.o
cc1: warnings being treated as errors
block/bochs.c: In function 'seek_to_sector':
block/bochs.c:202: error: ignoring return value of 'read', declared with attribute warn_unused_result
make: *** [block/bochs.o] Error 1
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
CC savevm.o
cc1: warnings being treated as errors
savevm.c: In function 'file_put_buffer':
savevm.c:342: error: ignoring return value of 'fwrite', declared with attribute warn_unused_result
make: *** [savevm.o] Error 1
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
CC slirp/misc.o
cc1: warnings being treated as errors
slirp/misc.c: In function 'fork_exec':
slirp/misc.c:209: error: ignoring return value of 'write', declared with attribute warn_unused_result
make: *** [slirp/misc.o] Error 1
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
CC i386-softmmu/pc.o
cc1: 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
/usr/src/RPM/BUILD/qemu-0.11.92/hw/pc.c: In function 'load_linux':
/usr/src/RPM/BUILD/qemu-0.11.92/hw/pc.c:888: error: ignoring return value of 'fread', declared with attribute warn_unused_result
/usr/src/RPM/BUILD/qemu-0.11.92/hw/pc.c:889: error: ignoring return value of 'fread', declared with attribute warn_unused_result
make[1]: *** [pc.o] Error 1
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
CC libuser/path.o
cc1: 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
make[1]: *** [path.o] Error 1
Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Store the register values in native endianness, by dropping all the
endianness conversion functions, and converting the endianness in
dbdma_readl/dbdma_writel instead.
Also guard the endianness conversion with TARGET_WORDS_BIGENDIAN to
simulate the backward connection of the bus.
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
Similarly to what has been done in e405a2ba91,
ignore rom intended to be loaded by the bios in find_rom() and rom_copy().
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
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>
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>
basename() needs #include <libgen.h>.
No prototype for daemon() is available on Solaris, but link
succeeds.
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
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>
Define symbolic value in i440fx configuration space
for 0x59, 0x5f and 0x7f and use them.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>