#
3e300fa6 |
| 26-May-2014 |
Alexander Graf <agraf@suse.de> |
macio ide: Do remainder access asynchronously
The macio IDE controller has some pretty nasty magic in its implementation to allow for unaligned sector accesses. We used to handle these accesses sync
macio ide: Do remainder access asynchronously
The macio IDE controller has some pretty nasty magic in its implementation to allow for unaligned sector accesses. We used to handle these accesses synchronously inside the IO callback handler.
However, the block infrastructure changed below our feet and now it's impossible to call a synchronous block read/write from the aio callback handler of a previous block access.
Work around that limitation by making the unaligned handling bits also go through our asynchronous handler.
This fixes booting Mac OS X for me.
Reported-by: John Arbuckle <programmingkidx@gmail.com> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
85720d36 |
| 18-May-2014 |
Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> |
macio: handle non-block ATAPI DMA transfers
Currently the macio DMA routines assume that all DMA requests are for read/write block transfers. This is not always the case for ATAPI, for example when
macio: handle non-block ATAPI DMA transfers
Currently the macio DMA routines assume that all DMA requests are for read/write block transfers. This is not always the case for ATAPI, for example when requesting a TOC where the response is generated directly in the IDE buffer.
Detect these non-block ATAPI DMA transfers (where no lba is specified in the command) and copy the results directly into RAM as indicated by the DBDMA descriptor. This fixes CDROM access under MorphOS.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
35d08458 |
| 16-Apr-2014 |
Juan Quintela <quintela@redhat.com> |
savevm: Remove all the unneeded version_minimum_id_old (rest)
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case
savevm: Remove all the unneeded version_minimum_id_old (rest)
After previous Peter patch, they are redundant. This way we don't assign them except when needed. Once there, there were lots of case where the ".fields" indentation was wrong:
.fields = (VMStateField []) { and .fields = (VMStateField []) {
Change all the combinations to:
.fields = (VMStateField[]){
The biggest problem (appart from aesthetics) was that checkpatch complained when we copy&pasted the code from one place to another.
Signed-off-by: Juan Quintela <quintela@redhat.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
#
c6baf942 |
| 23-Aug-2013 |
Andreas Färber <afaerber@suse.de> |
ide: Pass size to ide_bus_new()
To be passed to qbus_create_inplace().
Reviewed-by: Wenchao Xia <xiawenc@linux.vnet.ibm.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
|
#
04dd1259 |
| 12-Jul-2013 |
Stefan Weil <sw@weilnetz.de> |
PPC: dbdma: macio: Fix format specifiers (build regression)
Fix a number of warnings for 32 bit builds (tested on MingW and Linux):
CC hw/ide/macio.o qemu/hw/ide/macio.c: In function 'pmac_ide
PPC: dbdma: macio: Fix format specifiers (build regression)
Fix a number of warnings for 32 bit builds (tested on MingW and Linux):
CC hw/ide/macio.o qemu/hw/ide/macio.c: In function 'pmac_ide_atapi_transfer_cb': qemu/hw/ide/macio.c:134:9: error: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'hwaddr' [-Werror=format] qemu/hw/ide/macio.c: In function 'pmac_ide_transfer_cb': qemu/hw/ide/macio.c:215:5: error: format '%ld' expects argument of type 'long int', but argument 5 has type 'int64_t' [-Werror=format] qemu/hw/ide/macio.c:222:9: error: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'hwaddr' [-Werror=format] qemu/hw/ide/macio.c:264:9: error: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'hwaddr' [-Werror=format] cc1: all warnings being treated as errors make: *** [hw/ide/macio.o] Error 1
Signed-off-by: Stefan Weil <sw@weilnetz.de> Acked-by: Alexander Graf <agraf@suse.de> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
show more ...
|
#
f35ea98c |
| 30-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: dbdma: Support more multi-issue DMA requests
A DMA request can happen for data that hasn't been completely been provided by the IDE core yet. For example
- DBDMA request for 0x1000 bytes -
PPC: dbdma: Support more multi-issue DMA requests
A DMA request can happen for data that hasn't been completely been provided by the IDE core yet. For example
- DBDMA request for 0x1000 bytes - IDE request for 1 sector - DBDMA wants to read 0x1000 bytes (8 sectors) from bdrv - breakage
Instead, we should truncate our bdrv request to the maximum number of sectors we're allowed to read at that given time. Once that transfer is through, we will fall into our recently introduced waiting logic.
- DBDMA requests for 0x1000 bytes - IDE request for 1 sector - DBDMA wants to read MIN(0x1000, 1 * 512) bytes - DBDMA finishes reading, indicates to IDE core that transfer is complete - IDE request for 7 sectors - DBDMA finishes the DMA
Reported-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
80fc95d8 |
| 28-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: dbdma: Support unaligned DMA access
The DBDMA engine really just reads bytes from a producing device (IDE in our case) and shoves these bytes into memory. It doesn't care whether any alignment
PPC: dbdma: Support unaligned DMA access
The DBDMA engine really just reads bytes from a producing device (IDE in our case) and shoves these bytes into memory. It doesn't care whether any alignment takes place or not.
Our code today however assumes that block accesses always happen on sector (512 byte) boundaries. This is a fair assumption for most cases.
However, Mac OS X really likes to do unaligned, incomplete accesses that it finishes with the next DMA request.
So we need to read / write the unaligned bits independent of the actual asynchronous request, because that one can only handle 512-byte-aligned data. We also need to cache these unaligned sectors until the next DMA request, at which point the data might be successfully flushed from the pipe.
Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
cae32357 |
| 30-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: dbdma: Wait for DMA until we have data
We should only start processing DMA requests when we have data to process. Hold off working through the DMA shuffling until the IDE core told us that it's
PPC: dbdma: Wait for DMA until we have data
We should only start processing DMA requests when we have data to process. Hold off working through the DMA shuffling until the IDE core told us that it's ready.
This is required because the guest can program the DMA engine or the IDE transfer first. Both are legal.
Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
4aa3510f |
| 30-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: dbdma: macio: Add DMA callback
We need to know when the IDE core starts a DMA transfer. Add a notifier function so we have the chance to start transmitting data.
Signed-off-by: Alexander Graf
PPC: dbdma: macio: Add DMA callback
We need to know when the IDE core starts a DMA transfer. Add a notifier function so we have the chance to start transmitting data.
Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
33ce36bb |
| 29-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: Mac: Add debug prints in macio and dbdma code
The macio code is basically undebuggable as it stands today, with no debug prints anywhere whatsoever. DBDMA was better, but I needed a few more to
PPC: Mac: Add debug prints in macio and dbdma code
The macio code is basically undebuggable as it stands today, with no debug prints anywhere whatsoever. DBDMA was better, but I needed a few more to create reasonable logs that tell me where breakage is.
Add a DPRINTF macro in the macio source file and add a bunch of debug prints that are all disabled by default of course.
Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
8aef291f |
| 29-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: Macio: Replace tabs with spaces
s/^I/ /g on the file.
Signed-off-by: Alexander Graf <agraf@suse.de>
|
#
14eefd0e |
| 24-Jun-2013 |
Alexander Graf <agraf@suse.de> |
PPC: g3beige: Move secondary IDE bus to mac-io
On a real G3 Beige the secondary IDE bus lives on the mac-io chip, not on some random PCI device. Move it there to become more compatible.
While at it
PPC: g3beige: Move secondary IDE bus to mac-io
On a real G3 Beige the secondary IDE bus lives on the mac-io chip, not on some random PCI device. Move it there to become more compatible.
While at it, also clean up the IDE channel connection logic.
Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
1437c94b |
| 07-Jun-2013 |
Paolo Bonzini <pbonzini@redhat.com> |
hw/i*: pass owner to memory_region_init* functions
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
#
2c9b15ca |
| 06-Jun-2013 |
Paolo Bonzini <pbonzini@redhat.com> |
memory: add owner argument to initialization functions
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
#
f487b677 |
| 03-Jun-2013 |
Paolo Bonzini <pbonzini@redhat.com> |
dma: keep a device alive while it has SGLists
Reviewed-by: Anthony Liguori <aliguori@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
#
df32fd1c |
| 10-Apr-2013 |
Paolo Bonzini <pbonzini@redhat.com> |
dma: eliminate DMAContext
The DMAContext is a simple pointer to an AddressSpace that is now always already available. Make everyone hold the address space directly, and clean up the DMA API to use
dma: eliminate DMAContext
The DMAContext is a simple pointer to an AddressSpace that is now always already available. Make everyone hold the address space directly, and clean up the DMA API to use the AddressSpace directly.
Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
show more ...
|
#
b9b5df6f |
| 19-May-2013 |
Aurelien Jarno <aurelien@aurel32.net> |
ide/macio: fix wrong opaque with TRIM support
Commit 215e47b9 enabled TRIM by default, which revealed a bug in TRIM support for the IDE macio emulation driver, introduced in d353fb72.
The call to d
ide/macio: fix wrong opaque with TRIM support
Commit 215e47b9 enabled TRIM by default, which revealed a bug in TRIM support for the IDE macio emulation driver, introduced in d353fb72.
The call to dma_bdrv_io() is using a wrong opaque of type IDEState instead of DBDMA_io. This patch fixes that.
Fixes LP#1179104
Reported-by: Michael Tokarev <mjt@tls.msk.ru> Tested-off-by: Michael Tokarev <mjt@tls.msk.ru> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
show more ...
|
#
0ee20e66 |
| 06-May-2013 |
Kevin Wolf <kwolf@redhat.com> |
ahci: Don't allow creating slave drives
An IDE bus provided by AHCI can only take a single IDE drive. If you add a drive as slave, qemu used to accept the command line but the device wouldn't be act
ahci: Don't allow creating slave drives
An IDE bus provided by AHCI can only take a single IDE drive. If you add a drive as slave, qemu used to accept the command line but the device wouldn't be actually usable. Catch the situation instead and error out.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
show more ...
|
#
0d09e41a |
| 05-Feb-2013 |
Paolo Bonzini <pbonzini@redhat.com> |
hw: move headers to include/
Many of these should be cleaned up with proper qdev-/QOM-ification. Right now there are many catch-all headers in include/hw/ARCH depending on cpu.h, and this makes it n
hw: move headers to include/
Many of these should be cleaned up with proper qdev-/QOM-ification. Right now there are many catch-all headers in include/hw/ARCH depending on cpu.h, and this makes it necessary to compile these files per-target. However, fixing this does not belong in these patches.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
show more ...
|
#
07a7484e |
| 23-Jan-2013 |
Andreas Färber <afaerber@suse.de> |
ide/macio: QOM'ify MacIO IDE
It was not qdev'ified before. Turn it into a SysBusDevice. Embed them into the MacIO devices.
Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Alexander
ide/macio: QOM'ify MacIO IDE
It was not qdev'ified before. Turn it into a SysBusDevice. Embed them into the MacIO devices.
Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
baec1910 |
| 23-Jan-2013 |
Andreas Färber <afaerber@suse.de> |
ppc: Move Mac machines to hw/ppc/
Signed-off-by: Andreas Färber <afaerber@suse.de> [agraf: squash in MAINTAINERS fix] Signed-off-by: Alexander Graf <agraf@suse.de>
|
#
9c17d615 |
| 17-Dec-2012 |
Paolo Bonzini <pbonzini@redhat.com> |
softmmu: move include files to include/sysemu/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
#
737e150e |
| 17-Dec-2012 |
Paolo Bonzini <pbonzini@redhat.com> |
block: move include files to include/block/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
#
d688e523 |
| 20-Nov-2012 |
Peter Maydell <peter.maydell@linaro.org> |
hw/ide/macio: Fix segfault caused by NULL DMAContext*
Pass qemu_sglist_init the global dma_context_memory rather than a NULL pointer; this fixes a segfault in dma_memory_map() when the guest starts
hw/ide/macio: Fix segfault caused by NULL DMAContext*
Pass qemu_sglist_init the global dma_context_memory rather than a NULL pointer; this fixes a segfault in dma_memory_map() when the guest starts using DMA.
Reported-by: Amadeusz Sławiński <amade@asmblr.net> Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Alexander Graf <agraf@suse.de>
show more ...
|
#
a8170e5e |
| 23-Oct-2012 |
Avi Kivity <avi@redhat.com> |
Rename target_phys_addr_t to hwaddr
target_phys_addr_t is unwieldly, violates the C standard (_t suffixes are reserved) and its purpose doesn't match the name (most target_phys_addr_t addresses are
Rename target_phys_addr_t to hwaddr
target_phys_addr_t is unwieldly, violates the C standard (_t suffixes are reserved) and its purpose doesn't match the name (most target_phys_addr_t addresses are not target specific). Replace it with a finger-friendly, standards conformant hwaddr.
Outstanding patchsets can be fixed up with the command
git rebase -i --exec 'find -name "*.[ch]" | xargs s/target_phys_addr_t/hwaddr/g' origin
Signed-off-by: Avi Kivity <avi@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
show more ...
|