Commit Graph

290 Commits

Author SHA1 Message Date
malc 4c9b53e3ff More flexible audio card selection
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6258 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 10:46:34 +00:00
edgar_igl 253bd7f864 CRIS: Enable NTPL.
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6225 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-07 20:07:09 +00:00
malc 6cdc737502 Add missing space
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6194 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-06 18:57:51 +00:00
blueswir1 3aa9bd6c35 Add Sparc define checks
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6144 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-31 16:55:26 +00:00
aliguori ac0df51d7b Parse --cc and --cross-prefix earlier and use CC to determine cpu and host
We have been relying on uname to determine the host cpu architecture and
operating system.  This is totally broken for cross compilation.  It was
workable in the past because you can manually override both settings but after
the host USB passthrough refactoring, cross host builds were broken.

This moves the parsing of --cc and --cross-prefix to before the probes for cpu
and host.  Complation testing is used to determine the host and CPU types.  I've
only added checks for i386, x86_64, Linux, and Windows since these are the only
platforms I have access to for testing.  Everything else falls back to uname.

It should be relatively easy to add the right checks for other platforms and
eliminate uname altogether.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6141 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-29 17:14:15 +00:00
malc fc9902d9c7 Do not rely on BSD style echo (which accepts -n option)
http://www.opengroup.org/onlinepubs/7990989775/xcu/echo.html

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6072 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-17 19:00:18 +00:00
aurel32 d76d16501e target-ppc: Enable KVM for ppcemb.
Implement hooks called by generic KVM code.

Also add code that will copy the host's CPU and timebase frequencies to the
guest, which is necessary on KVM because the guest can directly access the
timebase.

Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
Acked-by: Anthony Liguori <aliguori@us.ibm.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6065 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-16 10:43:58 +00:00
aurel32 f652e6af11 Implement device tree support needed for Bamboo emulation
To implement the -kernel, -initrd, and -append options, 4xx board emulation
must load the guest kernel as if firmware had loaded it. Where u-boot would be
the firmware, we must load the flat device tree into memory and set key fields
such as /chosen/bootargs.

This patch introduces a dependency on libfdt for flat device tree support.

Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6064 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-16 10:43:48 +00:00
aurel32 71e991fdfa configure: also switch ppc64abi32 and ppcemb to CONFIG_SOFTFLOAT
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6043 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-15 17:13:19 +00:00
aurel32 3147d1e8e6 configure: switch to CONFIG_SOFTFLOAT for PPC
softfloat-native currently only supports one FPU context, while we need
at least 3 of them for the PPC target (FPU, SPE, AVR).

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6041 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-15 06:34:37 +00:00
balrog 8c7f75746e configure: close stdout for the remaining calls to cc.
r5953 managed to quite most colorgcc errors leakage to console
but not all of them.


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6040 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-15 03:15:36 +00:00
aliguori da93a1fd49 Make sure to link librt if we need to.
This is really a stop-gap.  The recent thread pool changes uncovered a 
deeper issue with how we use librt.  We really should be probing for 
timer_create and then conditionally enabling that code.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5997 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-12 20:02:52 +00:00
aliguori 3c529d9359 Replace posix-aio with custom thread pool
glibc implements posix-aio as a thread pool and imposes a number of limitations.

1) it limits one request per-file descriptor.  we hack around this by dup()'ing
file descriptors which is hideously ugly

2) it's impossible to add new interfaces and we need a vectored read/write
operation to properly support a zero-copy API.

What has been suggested to me by glibc folks, is to implement whatever new
interfaces we want and then it can eventually be proposed for standardization.
This requires that we implement our own posix-aio implementation though.

This patch implements posix-aio using pthreads.  It immediately eliminates the
need for fd pooling.

It performs at least as well as the current posix-aio code (in some
circumstances, even better).

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5996 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-12 16:41:40 +00:00
aliguori d85dc283fa Disable KVM support if the kernel modules have broken memory slot handling
Prior to kvm-80, memory slot deletion was broken in the KVM kernel 
modules.  In kvm-81, a new capability is introduced to signify that this
problem has been fixed.

Since we rely on being able to delete memory slots, refuse to work with 
any kernel module that does not have this capability present.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5960 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-09 19:59:09 +00:00
aurel32 178baee68b configure: also close stdout when calling cc
Remove some ugly outputs with colorgcc

Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5953 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-08 18:11:57 +00:00
malc fd69fe2b94 Quote configure's arguments and location while storing them in config_host.mak
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5940 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-07 22:50:16 +00:00
blueswir1 e0e36fe91d Enable gcc flag -Wredundant-decls
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5931 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-07 19:16:27 +00:00
blueswir1 10865b3496 Enable gcc flag -Wstrict-prototypes
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5930 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-07 19:15:47 +00:00
blueswir1 c1e6ccd1db Enable gcc flag -Wmissing-prototypes
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5929 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-07 19:15:17 +00:00
aurel32 662bbadd35 Remove gcc 3.4 check
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5911 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-07 13:40:38 +00:00
aurel32 45d827d2d7 target-ppc: convert SPR accesses to TCG
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5910 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-07 13:40:29 +00:00
aliguori bf9298b90e Make struct iovec universally available
Vectored IO APIs will require some sort of vector argument.  It makes sense to
use struct iovec and just define it globally for Windows.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5889 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-05 20:05:26 +00:00
blueswir1 1360677cfe Attached patch makes NetBSD use the native bswap functions
which compile.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5886 c046a42c-6fe2-441c-8c8c-71466251a162
2008-12-05 17:54:09 +00:00
malc d4742de84f Handle SDL log just like other temporary files
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5817 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-29 22:04:31 +00:00
malc 9ac81bbbe1 Use trap shell builtin to remove temporary files
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5816 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-29 20:09:56 +00:00
ths 777553406d Make installing bios files optional.
Signed-off-by: Riku Voipio <riku.voipio@iki.fi>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5800 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-27 15:45:16 +00:00
blueswir1 f488791962 Fix typo reported by Thiemo Seufer
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5782 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-23 07:27:59 +00:00
blueswir1 6806364989 Native BSD host USB support (Juergen Lock, Lonnie Mendez)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5780 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-22 21:03:55 +00:00
blueswir1 8ef92a880f Fix some compile and linking issues on NetBSD.
- adapt configure to link against -lrt to fix aio linking errors
- adapt configure to link against -lossaudio to fix oss linking errors

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5776 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-22 20:24:29 +00:00
malc b29fe3ed48 Preliminary AIX support
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5732 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-18 01:42:22 +00:00
aliguori 5985eceeaa Allow KVM to be used on either 32-bit or 64-bit x86
Inspired by a patch from Glauber Costa.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5631 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-05 19:59:25 +00:00
aliguori eac3026225 Add --kerneldir configure argument
This allows a user to override the default search path and also makes cross
compilation work a bit nicer wrt KVM detection.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5628 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-05 16:28:56 +00:00
aliguori 7ba1e61953 Add KVM support to QEMU
This patch adds very basic KVM support.  KVM is a kernel module for Linux that
allows userspace programs to make use of hardware virtualization support.  It
current supports x86 hardware virtualization using Intel VT-x or AMD-V.  It
also supports IA64 VT-i, PPC 440, and S390.

This patch only implements the bare minimum support to get a guest booting.  It
has very little impact the rest of QEMU and attempts to integrate nicely with
the rest of QEMU.

Even though this implementation is basic, it is significantly faster than TCG.
Booting and shutting down a Linux guest:

w/TCG:  1:32.36 elapsed  84% CPU

w/KVM:  0:31.14 elapsed  59% CPU

Right now, KVM is disabled by default and must be explicitly enabled with
 -enable-kvm.  We can enable it by default later when we have had better
testing.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5627 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-05 16:04:33 +00:00
blueswir1 d2c7c9b871 Avoid ld flag --warn-common on Solaris
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5594 c046a42c-6fe2-441c-8c8c-71466251a162
2008-11-01 14:50:20 +00:00
blueswir1 84778508d7 Preliminary BSD user emulator support
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5544 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-26 20:33:16 +00:00
aliguori 17e909738d Fix windows build after migration changes
The live migration code broke the windows build.  As part of this 
change, I've switched the BIOS path to C:\Program Files\Qemu instead of 
/c/Program Files/Qemu.  The later is only valid when launching from MSYS 
but the former is always valid.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5524 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-24 14:11:41 +00:00
pbrook 56aebc8916 Add GDB XML register description support.
Signed-off-by: Paul Brook <paul@codesourcery.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5459 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-11 17:55:29 +00:00
balrog 17e1592d27 Use the adequate CFLAGS for confiugure tests.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5457 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-11 12:00:42 +00:00
balrog ac62922e72 Add a configure check for zlib (Ryota OZAKI).
This patch makes configure check zlib devel files installed.
Current configure doesn't check that, so make will fail if they
are not installed.

Signed-off-by: Ryota Ozaki <ozaki.ryota@gmail.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5456 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-11 09:56:04 +00:00
aliguori 9e472e101f Fix IO performance regression in sparc
Replace signalfd with signal handler/pipe.  There is no way to interrupt
the CPU execution loop when a file descriptor becomes readable.  This
results in a large performance regression in sparc emulation during
bootup.
   
This patch switches us to signal handler/pipe which was originally
suggested by Ian Jackson.  The signal handler lets us interrupt the
CPU emulation loop while the write to a pipe lets us avoid the
select/signal race condition.
    
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5451 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-08 19:50:24 +00:00
aliguori 890b165890 add help text for --enable-sparse (Gerd Hoffman)
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5444 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-07 21:22:41 +00:00
aliguori 03b4fe7de2 Add sparse checker support to the build system (Gerd Hoffman)
This adds support for running the sparse checker during the build
process.  Left it off by default for now, build becomes very noisy with
sparse checking turned on as it has to complain alot (partly even in the
system headers!).  The qemu code base needs quite some cleanups before
we should consider turning it on by default.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5440 c046a42c-6fe2-441c-8c8c-71466251a162
2008-10-07 19:16:17 +00:00
malc 9d56d2dce6 Avoid (some) ppc cross-compilation problems
[..snip..]

A recent kvm merge with qemu brought code for 64bit power that broke cross
compilation. The issue is caused by configure trying to execute target
architecture binaries where configure is executed.

[..snip..]

The patch is based on Hollis's Blanchard idea.

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5364 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-30 19:44:32 +00:00
aurel32 8bb6e981e0 target-alpha: convert palcode ops to TCG
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5360 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-30 06:45:44 +00:00
balrog e820e3f459 Make sure bluez programs (cross-)compile, add missing statics.
Spotted by Blue Swirl.


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5358 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-30 02:27:44 +00:00
balrog fb599c9a03 Implement a HCI passthrough to host.
This allows using a host's physical HCI as one of the HCIs attached
to the virtual machine.  This brings various limitations because not
all commands/events are passed through by Linux kernel, some are
interpreted by the host's kernel for a speed gain.


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5344 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-28 23:49:55 +00:00
aliguori 27463101f1 Make compatfd fallback more robust
Be more friendly when signalfd() fails, and also add configure checks to detect
that syscall(SYS_signalfd) actually works.  malc pointed out that some installs
do not have /usr/include/linux headers that are in sync with the glibc headers
so why SYS_signalfd is defined, it's #defined to _NR_signalfd which is not
defined in the /usr/include/linux header.

While this is a distro bug, it doesn't hurt to do a more thorough job in
detection.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5334 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-27 20:58:43 +00:00
aliguori 997306fc22 Fix build on FreeBSD
__GLIBC_PREREQ is defined in such a way that the ! cannot be used in front of
it on FreeBSD.  Also, -lpthread is not implied by the build and we definitely
use it for compatfd support.

While at it, I added a default initialization for posix-aio that seems to
perform well in our testing.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5322 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-26 15:52:17 +00:00
blueswir1 49237acdb7 Enable ld flag --warn-common
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5241 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-17 19:05:19 +00:00
aurel32 0b6d3ae072 qemu sh4 nptl support
(Michael Trimarchi)

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5223 c046a42c-6fe2-441c-8c8c-71466251a162
2008-09-15 07:43:43 +00:00