Commit Graph

2319 Commits (4951f65bd35ea57c28d8af2d20e1c93087e73f0c)

Author SHA1 Message Date
Avi Kivity 1632dc6a8f Route IOAPIC interrupts via ISA bus
Instead of calling the IOAPIC from the PIC, raise IOAPIC irqs via the ISA bus.
As a side effect, IOAPIC lines 16-23 are enabled.

Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-24 08:01:42 -05:00
Avi Kivity 1452411b25 Route PC irqs to ISA bus instead of i8259 directly
A PC has its motherboard IRQ lines connected to both the PIC and IOAPIC.
Currently, qemu routes IRQs to the PIC which then calls the IOAPIC, an
incestuous arrangement.  In order to clean this up, create a new ISA IRQ
abstraction, and have devices raise ISA IRQs (which in turn raise the i8259
IRQs as usual).

Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-24 08:01:41 -05:00
Jes Sorensen 6b35e7bf48 QEMU set irq0override in fw_cfg
Hi,

After discussing the issue with Avi, Gleb and a couple others on irq,
we came to the conclusion that it is preferred to have QEMU request
features from the BIOS, rather than notifying the BIOS that it is
running on QEMU or KVM. This way memory ranges can change etc. and
an older BIOS will continue to work on newer QEMU if it receives the
info as a fw_cfg value.

This one also matches what qemu-kvm does for irq0override, except I
haven't made it configurable. I leave that as an exercise for whoever
would be interested in switching off irq0override.

Thanks,
Jes

Set irq0 override in fw_cfg, informing the BIOS that QEMU expects
override on irq0. This matches qemu-kvm, and will help sharing a
single BIOS binary.

Signed-off-by: Jes Sorensen <jes@sgi.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-24 08:01:41 -05:00
Brian Wheeler e8b5439495 SMART ATA Functionality
For the lulz I implemented basic SMART functionality in ide.c.  smartctl
on linux recognizes it just fine and starting self tests with it
complete successfully.

Signed-off-by: Brian Wheeler <bdwheele@indiana.edu>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-24 08:01:41 -05:00
Stefano Stabellini 04a52b4120 make vga screen_dump use DisplayState properly
Hi all,
currently the vga screen_dump code doesn't use the DisplayState
interface properly and tries to replace it temporarily while taking the
screenshot.
A better approach is to register a DisplayChangeListener, call
vga_hw_update, and finally write the ppm in the next call from dpy_update.

Testing is appreciated.

Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-24 08:01:39 -05:00
malc b6f6d0e2f8 Restore consistent formatting
Signed-off-by: malc <av1474@comtv.ru>
2009-08-24 15:18:40 +04:00
Juan Quintela e5944641ab es1370: Remove unused indirection of PCIES1370State and ES1370State
Signed-off-by: Juan Quintela <quintela@redhat.com>
2009-08-24 15:15:31 +04:00
Andrzej Zaborowski 4445b0a624 Revert my commit c00a9de060
was incorrect.
2009-08-23 19:00:58 +02:00
Torsten Duwe 8d30b794ce Fix segfault of qemu-system-arm with PXA target
qemu-system-arm (0.10.5) segfaults when invoked with a PXA machine target,
e.g. -M tosa. The reason is fairly obvious:

Signed-off-by: Torsten Duwe <duwe@lst.de>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Andrzej Zaborowski <balrogg@gmail.com>
2009-08-23 18:08:14 +02:00
Reimar Döffinger c00a9de060 Use corect depth from DisplaySurface in vmware_vga.c
Hello,
for what I can tell, there is no way for vmware_vga to work correctly
right now. It assumes that the framebuffer bits-per-pixel and the one
from the DisplaySurface are identical (it uses directly the VRAM from
vga.c), but it always assumes 3 bytes per pixel, which is never possible
with the current version of DisplaySurface.
Attached patch fixes that by using ds_get_bits_per_pixel.
2009-08-23 18:00:33 +02:00
Andrzej Zaborowski 13f59cbfe3 Remove the unnecessary and only global in musicpal.c 2009-08-23 17:44:20 +02:00
Andrzej Zaborowski 7ef6e71c59 Merge with balrog@git.sv.gnu.org:/srv/git/qemu.git 2009-08-23 17:19:44 +02:00
Andrzej Zaborowski d074769c5a Make musicpal.c use the I2C device and the Marvell 88w8618 audio device
Signed-off-by: Benoit Canet <benoit.canet@gmail.com>
Signed-off-by: Andrzej Zaborowski <balrogg@gmail.com>
2009-08-23 15:51:14 +02:00
Andrzej Zaborowski ef07b49145 Extract the Marvell 88w8618 audio device from musicpal.c
Signed-off-by: Benoit Canet <benoit.canet@gmail.com>
Signed-off-by: Andrzej Zaborowski <balrogg@gmail.com>
2009-08-23 15:44:15 +02:00
Andrzej Zaborowski 3ead03bd0a Extract musicpal.c I2C bitbanging code and make it gpio aware
Signed-off-by: Benoit Canet <benoit.canet@gmail.com>
Signed-off-by: Andrzej Zaborowski <balrogg@gmail.com>
2009-08-23 15:38:50 +02:00
Benoit Canet 343ec8e485 Musicpal qdev conversion: gpio (except I2C part), keyboard and lcd
Signed-off-by: Benoit Canet <benoit.canet@gmail.com>
Signed-off-by: Andrzej Zaborowski <balrogg@gmail.com>
2009-08-23 14:38:07 +02:00
Blue Swirl d453c2c32e Sparc32: fix monitor commands 'info pic' and 'info irq'
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-23 12:23:30 +00:00
Blue Swirl 7432ff5d6b Rearrange to suppress gcc 3.3.5 warning about unused variable
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-23 06:12:54 +00:00
Blue Swirl 0fd0eb2161 ESP: implement Transfer Pad
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-22 13:55:05 +00:00
Blue Swirl 5e1e0a3bb9 ESP: Implement select without ATN, fix comments
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-22 13:54:31 +00:00
Juan Quintela 10ee2aaa41 Remove unneded ac97 indirection accessing its state
Searching for "inspiration" to convert another device to qdev, I got
ac97.  Once I understood a bit of qdev, found that ac97 used a not needed
indirection.  To protect the unaware, just fixed it.

Later, Juan.

Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: malc <av1474@comtv.ru>
2009-08-22 13:51:39 +04:00
Blue Swirl b11ebf64b6 Replace REGX with PRIx64
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-16 11:54:37 +00:00
Blue Swirl 90e189ece1 Replace local ADDRX/PADDRX macros with TARGET_FMT_lx/plx
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-16 11:13:18 +00:00
Blue Swirl 636aa20056 Replace always_inline with inline
We define inline as always_inline.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-16 09:06:54 +00:00
Blue Swirl 802670e6c9 PPC: clean up ppc405
Rely on the subpage system instead of the local version.
Make most functions "static".
Fix wrong parameter passed to ppc4xx_pob_reset.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-15 14:27:05 +00:00
Anthony Liguori 0bf5e443bd Fix migration for ide devices
commit 93c8cfd9e6
Author: Gleb Natapov <gleb@redhat.com>
Date:   Sun Aug 2 11:36:47 2009 +0300

    make windows notice media change

Broke save/restore by loading a new field but not saving it.

Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-13 16:05:12 -05:00
Blue Swirl 0c5b8d831d Unbreak Sparc64
EBus is a sort of ISA bus.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-13 17:51:46 +00:00
Blue Swirl bc19fcaa1b Unbreak Sparc32 and PPC
Convert qdev ptr type to chr, allow a NULL pointer.

Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-08-13 16:26:52 +00:00
Anthony Liguori c981d39c95 Fix virtio-blk
Reported-by: Christoph Hellwig
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-08-10 19:27:59 -05:00
Gerd Hoffmann f6c64e0eea rename "info qdrv" to "info qdm"
As requested by avi: driver != device model.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:27 -05:00
Gerd Hoffmann 22f2e34474 fix qdev_print_devinfo()
snprintf returns number of bytes needed for the output, not the number
of bytes actually written.  Thus the math is wrong ...

Spotted by Markus Armbruster.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:27 -05:00
Gerd Hoffmann ea2b7271bf qdev/prop: convert xilinx_timer.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:27 -05:00
Gerd Hoffmann 8017dc2688 qdev/prop: convert xilinx_intc.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:27 -05:00
Gerd Hoffmann 05f0257906 qdev/prop: convert xilinx_ethlite.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:27 -05:00
Gerd Hoffmann 72c61d0bf4 qdev/prop: convert virtio-pci.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann df59cbc6e2 qdev/prop: convert vga.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann 53dad4992c qdev/prop: convert tcx.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann 083301fc81 qdev/prop: convert syborg_timer.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann c4470b2577 qdev/prop: convert syborg_serial.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann 5cdabc1498 qdev/prop: convert syborg_pointer.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann 51dd59272b qdev/prop: convert syborg_keyboard.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann 3c2aed8b27 qdev/prop: convert syborg_interrupt.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:26 -05:00
Gerd Hoffmann c230c4e38f qdev/prop: convert syborg_fb.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:25 -05:00
Gerd Hoffmann 32a7ee989f qdev/prop: convert sun4u.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:25 -05:00
Gerd Hoffmann c885159a7a qdev/prop: convert sun4m.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:25 -05:00
Gerd Hoffmann 3180d77219 qdev/prop: convert sparc32_dma.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:25 -05:00
Gerd Hoffmann bf2782d7d3 qdev/prop: convert smbus_eeprom.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:11:25 -05:00
Gerd Hoffmann 18c637dccb qdev/prop: convert slavio_timer.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id: 
Message-Id:
2009-08-10 13:11:25 -05:00
Gerd Hoffmann 7fdaf611a5 qdev/prop: convert slavio_intctl.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id: 
Message-Id:
2009-08-10 13:08:38 -05:00
Gerd Hoffmann 186507b446 qdev/prop: convert pcnet.c to helper macros.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Message-Id:
2009-08-10 13:05:52 -05:00