Commit Graph

6274 Commits

Author SHA1 Message Date
aliguori 973cbd37ce Fix tap downscript argument (Mark McLoughlin)
Kill off the hack that parses info_str for the tap interface
name to pass as the argument to the downscript and, instead,
just explicitly keep a copy of the string for later.

As reported by John Wong, this commit:

  Add qemu_format_nic_info_str()

changed the invocation of downscript from e.g.

  /path/kvm-ifdown "tap0"

to:

  /path/kvm-ifdown "tap0,script=/path/kvm-ifup,downscript=/path/kvm-ifdown"

This fix restores the original behavior.

Reported-by: John Wong <johnw@wonghome.net>
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6285 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 19:15:55 +00:00
aurel32 f5cbc474e8 ESCC: swap the two CharDriverState arguments
Swap the two CharDriverState arguments so that the first argument
corresponds to the channel A and the second argument to the channel B.

Modify hw/sun4m.c accordingly.

This fixes the order of the serial ports on the PPC machines.

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

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6284 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 19:08:18 +00:00
aurel32 6b4079f843 target-ppc: define max amount of memory for G3 beige
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6283 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 19:08:10 +00:00
aurel32 8a901deff9 target-ppc: fix comment about boot device in ppc_oldworld.c
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6282 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 19:07:59 +00:00
aliguori d07f22c530 Add qemu_check_nic_model() and qemu_check_nic_model_list() (Mark McLoughlin)
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6281 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 19:03:57 +00:00
blueswir1 5a37791249 Fix gdbserver number of registers (Tristan Gingold)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6280 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 16:28:01 +00:00
aliguori 2c3891ab7f RTL8139: Latch C+ mode state instead of inferring it from C+ Command register (Avi Kivity)
It was observed that Windows 2003 x64 hangs when shutting down if an
RTL8139 NIC and a USB device tablet are both present.  What seems to be
happening is:

- the guest shuts down the transmitter and receiver
- time passes
- the guest requests a tally counter dump

As it happens, the tally counter command register overlaps the transmit
status register in C mode.  Qemu determines whether the chip is in C or C+
mode by looking at the C+ transmit enable bit; as this is now unset, the
dump tally counter command is interpreted as a C mode transmit command.  The
guest doesn't think so, however, and continues to poll for completion of the
tally counter dump command.  This never occurs, so the guest hangs.

Fix by redefining C+ mode as "a write to the C+ command register has occurred
since the last reset".  The data sheet is silent on the matter.

Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6279 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 15:20:14 +00:00
aliguori f094a78220 Fix race in POSIX AIO emulation (Jan Kiszka)
When we cancel an AIO request that is already being processed by
aio_thread, qemu_paio_cancel should return QEMU_PAIO_NOTCANCELED as long
as aio_thread isn't done with this request. But as the latter currently
updates aiocb->ret after every block of the request, we may report
QEMU_PAIO_ALLDONE too early.

Futhermore, in case some zero-length request should have been queued,
aiocb->ret is never set to != -EINPROGRESS and callers like
raw_aio_cancel could get stuck in an endless loop.

Fix those issues by updating aiocb->ret _after_ the request has been
fully processed. This also simplifies the locking.

Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6278 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-13 15:13:53 +00:00
aurel32 f48c144e24 target-alpha: get rid of tests on env->user_mode_only
Replace runtime checks on env->user_mode_only by compile time
checks on CONFIG_USER_ONLY.

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

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6277 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 21:33:22 +00:00
aurel32 932e71cd57 target-mips: get rid of tests on env->user_mode_only
Replace runtime checks on env->user_mode_only by compile time
checks on CONFIG_USER_ONLY.

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

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6276 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 21:33:13 +00:00
aurel32 ae1c1a3d68 target-ppc: add altivec cache instructions
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6275 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 21:33:02 +00:00
blueswir1 afdf8109e3 Fix TLB access (Jakub Jermar)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6274 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 21:12:22 +00:00
blueswir1 164ef2e002 Update Sparc32 and Sparc64 images
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6273 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 20:00:29 +00:00
blueswir1 0580ac9160 Fix some SLIRP warnings
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6272 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 17:51:06 +00:00
blueswir1 7fa9ae1aaa Use ESCC for PowerMac serial
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6271 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 17:40:23 +00:00
blueswir1 b4ed08e09e Rename slavio_serial functions to escc, add clock rate and it_shift parameters
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6270 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 17:38:28 +00:00
blueswir1 2aa2ab3af3 Rename slavio_serial to escc
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6269 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 17:33:30 +00:00
blueswir1 8f180a4308 Fix typo
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6268 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-12 17:31:29 +00:00
blueswir1 6ea5259547 Fix segfault
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6267 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-10 14:38:00 +00:00
blueswir1 c190ea0729 Add EBUS bridge
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6266 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-10 11:33:32 +00:00
blueswir1 a94fd955eb Fix APB
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6265 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 20:53:30 +00:00
aurel32 27a3deca51 Update openbios-ppc to revision 373
Fix boot on CD-ROM.

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

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6264 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 20:06:44 +00:00
aliguori 8444eb6ecd fix configuring kvm probe when using --kerneldir (Christian Ehrhardt)
There is already a variable kvm_cflags which gets the path of the kernel
includes when using --kerneldir. But eventually with newer kernels we all will
need arch/$arch/include too (my case was a incldue of asm/kvm.h which was not
found anymore). Headers in a full kernel source are not flattened to
one arch like they are if e.g. installed kernel headers are used.

To fix that, the includes added to cflags depending on --kerneldir should also
contian the arch includes. The patch adds a special check for x86 because its
source layout recently changed, all others directly use arch/$cpu/include if
existent.

Signed-off-by: Christian Ehrhardt <ehrhardt@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6263 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 20:05:10 +00:00
aurel32 9ec0b4a310 Mark openbios-ppc as a binary file.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6262 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 19:51:09 +00:00
aurel32 5652ef78d1 mips, ppc: make sure nd->model is always defined
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6261 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 13:10:41 +00:00
aurel32 e5d01b0677 target-ppc: add an openbios-ppc image
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6260 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 11:01:31 +00:00
malc 1d1f8c33d3 Update to reflect the fact that AC97 will be built by default
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6259 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 10:46:37 +00:00
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
aurel32 6b419964d5 target-ppc: revert part of commit r6254 committed accidentally
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6257 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 06:43:25 +00:00
edgar_igl dd5de373b7 Make the set_link cmd handle multiple nics.
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6256 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 00:48:28 +00:00
edgar_igl 94410b78be ETRAX: Let the ethernet PHY report the current link-state.
* PHY reports correct link-state.
* Allow the board description to assign separate addresses to each PHY.

Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6255 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-09 00:04:35 +00:00
aurel32 5ab09f3349 Add v{add, sub}{s, u}{b, h, w}s instructions
Nathan Froyd <froydnj@codesourcery.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6254 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 23:19:50 +00:00
aliguori b0f3b8fac4 Enable ac97 by default
ac97 has drivers for Vista 64-bit whereas sb16 and es1370 do not appear to.  I
asked malc why it was disabled and he said it was because it was GPL.  He did
not object to enabling it now that more QEMU code is GPL'd.

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



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6253 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 21:03:55 +00:00
aliguori c45ca54ff9 IDE: Return zero when reading error register with slave selected (Justin Chevrier)
During hardware detection Openserver issues commands to slaves on both primary
and secondary ports. We already return a zero for the status register in this
situation but after reading the status register the Openserver installer
proceeds to check the value of the error register. Currently we return the
existing value in the register. This confuses the installer and it tries to
access the slave units later on. When the command that gets issued later gets
ignored the installer freezes. The patch below returns zero when reading the
error register if a slave unit is selected. Openserver can now successfully be
installed using the emulated IDE hard drive.

Return zero when reading error register with slave selected

Signed-off-by: Justin Chevrier <theburner1@yahoo.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6252 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 21:03:07 +00:00
blueswir1 5df23f531c Fix IDE debug
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6251 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 20:01:26 +00:00
aliguori 554c97dd43 Implement virtio_net link status (Mark McLoughlin)
Implement the VIRTIO_NET_F_STATUS feature by exposing the link status
through virtio_net_config::status.

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6250 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:46:33 +00:00
aliguori 99ed7e30cb Implement e1000 link status (Mark McLoughlin)
On link up or down we set the E1000_STATUS_LU ("link up") bit
in the status register and set the E1000_ICR_LSC ("link
status changed") bit in the interrupt cause register before
interrupting the guest.

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6249 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:45:50 +00:00
aliguori 34b25ca74e Allow devices be notified of link status change (Mark McLoughlin)
Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6248 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:45:03 +00:00
aliguori 436e5e53c9 Add 'set_link' monitor command (Mark McLoughlin)
Add a monitor command to setting a given network device's link status
to 'up' or 'down'.

Allows simulation of network cable disconnect.

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6247 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:44:06 +00:00
aliguori d6aa671f18 qemu-nbd: fix options: -b (--bind) expects an argument (IFACE) (Uri Lublin)
Rebased for qemu tree.

Signed-off-by: Uri Lublin <uril@redhat.com> 
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6246 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:34:35 +00:00
aliguori 54c16572a0 qcow2: free old snapshots array upon creation of a new one (Uri Lublin)
Don't leak memory

Rebased for qemu tree.

Signed-off-by: Uri Lublin <uril@redhat.com> 
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6245 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:32:20 +00:00
aliguori 7f48fa1f05 qcow1: Fix compressed images (Kevin Wolf)
Revert r4673, the removed dead code wasn't dead in fact.

Additionally, change the misleading else which tricks the reader into
believing that allocate is a boolean to else if (allocate == 2).

Signed-off-by: Kevin Wolf <kwolf@suse.de>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6244 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:29:03 +00:00
aliguori 062e55272e Add support for vmchannel socket migration (Gleb Natapov)
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6243 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:27:07 +00:00
aliguori 49ec9b4054 Add "restrict" and "ip" option to "user" net option (Gleb Natapov)
Expose new slirp capabilities to user through a command line options.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6242 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:26:22 +00:00
aliguori a9ba3a856d Add slirp_restrict option (Gleb Natapov)
Add "slirp firewall" to permit connection only to vmchannel addresses.

Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6241 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:24:00 +00:00
aliguori e1c5a2b334 Redirect slirp traffic to/from qemu character device (Gleb Natapov)
Signed-off-by: Gleb Natapov <gleb@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6240 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:18:21 +00:00
aliguori 4dda406337 Add model field to nic info (Mark McLoughlin)
The model type used to be printed as part of the nic info.  It was removed when
the name type was added.  This adds back a model field for those that were
using it previously.

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>



git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6239 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 19:01:37 +00:00
aurel32 c026766b15 Add vspltis{b,h,w} instructions
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6238 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 18:54:57 +00:00
aurel32 d9430add63 Add vs{l,r} instructions
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6237 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 18:54:48 +00:00
aurel32 1add6e234a Add vcmpequ{b, h, w} and vcmpgt{s, u}{b, h, w} instructions
Signed-off-by: Nathan Froyd <froydnj@codesourcery.com>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6236 c046a42c-6fe2-441c-8c8c-71466251a162
2009-01-08 18:54:38 +00:00