summaryrefslogtreecommitdiff
path: root/hw/dma
AgeCommit message (Collapse)AuthorFilesLines
2013-07-29sun4m_iommu: QOM cast cleanupAndreas Färber1-4/+8
Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-07-29sparc32_dma: QOM cast cleanupAndreas Färber1-9/+14
Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-07-29pxa2xx_dma: QOM cast cleanupAndreas Färber1-8/+12
Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-07-29puv3_dma: QOM cast cleanupAndreas Färber1-4/+8
Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-07-29pl080: QOM'ify pl080 and pl081Andreas Färber1-31/+20
Let pl081 inherit from pl080 and replace triple SysBus initfn with two instance_inits. Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-07-29pl080: Rename pl080_state to PL080StateAndreas Färber1-22/+22
Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-07-15hw/dma/omap_dma: Fix bugs with DMA requests above 32Peter Maydell1-5/+6
The drqbmp field of struct soc_dma_s is a uint64_t; however several places in the code attempt to set bits in it using "(1 << drq)", which will fail if drq is large enough that the 1 bit gets shifted off the top of a 32 bit integer. Change these to "(1ULL << drq)" so that the promotion to 64 bit happens before the shift rather than afterwards. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1372423919-5669-1-git-send-email-peter.maydell@linaro.org
2013-07-04hw/d*: pass owner to memory_region_init* functionsPaolo Bonzini7-7/+9
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04piolist: add owner argument to initialization functions and pass devicesPaolo Bonzini1-1/+1
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04memory: add owner argument to initialization functionsPaolo Bonzini11-14/+14
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-07-04i82374: replace register_ioport*Jan Kiszka1-5/+13
Convert over to memory regions to obsolete register_ioport*. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-06-20dma: eliminate DMAContextPaolo Bonzini1-4/+4
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>
2013-06-15Merge branch 'realize-isa.v2' of git://github.com/afaerber/qemu-cpuBlue Swirl1-8/+5
* 'realize-isa.v2' of git://github.com/afaerber/qemu-cpu: qdev: Drop FROM_QBUS() macro isa: QOM'ify ISADevice isa: QOM'ify ISABus i8259: Convert PICCommonState to use QOM realizefn kvm/i8259: QOM'ify some more i8259: QOM'ify some more i8254: Convert PITCommonState to QOM realizefn kvm/i8254: QOM'ify some more i8254: QOM'ify some more isa: Use realizefn for ISADevice cs4231a: QOM'ify some more gus: QOM'ify some more
2013-06-10xilinx_axidma: Do not set DMA .notify to NULL after notifyWendy Liang1-1/+2
If a stream notify function is not ready, it may re-populate the notify call- back to indicate it should be re-polled later. This break in this usage, as immediately following the notify() call, .notify is set to NULL. reverse the ordering of the notify call and NULL assignment accordingly. [PC: Reworked commit message] Signed-off-by: Wendy Liang <jliang@xilinx.com> Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-06-07isa: Use realizefn for ISADeviceAndreas Färber1-8/+5
Drop ISADeviceClass::init and the resulting no-op initfn and let children implement their own realizefn. Adapt error handling. Split off an instance_init where sensible. Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-05-20Rename hexdump to avoid FreeBSD libutil conflictEd Maste1-2/+2
On FreeBSD libutil is used for openpty(), but it also provides a hexdump() which conflicts with QEMU's. Signed-off-by: Ed Maste <emaste@freebsd.org> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Message-id: 1368718348-15199-1-git-send-email-emaste@freebsd.org Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-29i82374: QOM'ifyAndreas Färber1-3/+7
Introduce type constant and cast macro to obsolete DO_UPCAST(). Prepares for ISA realizefn. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de> Message-id: 1367093935-29091-5-git-send-email-afaerber@suse.de Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-20qdev: Drop taddr propertiesPeter Maydell1-1/+0
Drop all the infrastructure for taddr properties (ie ones which are 'hwaddr' sized). These are now unused, and any further desired use would be rather questionable since device properties shouldn't generally depend on a type that is conceptually variable based on the target CPU. 32 or 64 bit integer properties should be used instead as appropriate for the specific device. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2013-04-19Remove unneeded type castsStefan Weil2-3/+3
cpu_physical_memory_read, cpu_physical_memory_write take any pointer as 2nd argument without needing a type cast. Signed-off-by: Stefan Weil <sw@weilnetz.de> Reviewed-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2013-04-16stream: Remove app argument hackPeter Crosthwaite1-29/+70
The uint32_t *app argument doesn't exist in real hardware. It was a hack in xilinx_axidma/enet to fake the (secondary) control stream connection. Removed the argument and added the second stream to axienet/dma. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axienet/dma: Implement rx path flow controlPeter Crosthwaite1-8/+41
Implement flow control for the RX data path from xilinx_axienet->xilinx_axidma. On short return from axidma, then ethernet sets up the notify callback to resume transfer from where it left off. This also allows the ethernet to track whether there is an in progress transaction and return false from ethernet can_receive() as appropriate. If the DMA backs up or is disabled it waits for enablement. When the rx stream IO region is touched, the can_push() notify function is called if set. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16stream: Add flow control APIPeter Crosthwaite1-1/+2
Add basic flow control to stream. A stream slave may return short, indicating that it is not capable of accepting any more data at the present time. Polling or a callback can be used via the can_push() function to determine when the slave can receive again. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axidma: Fix rx/tx halted bit.Peter Crosthwaite1-2/+2
If there is no DMA buffer descriptor, the DMA halts, not idles. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axidma: Create Proxy object for streamPeter Crosthwaite1-5/+58
Create a separate child object to proxy the stream slave connection. This is setup for future work where a second stream slave connection is needed. The new child object is created at qdev init time and is linked back to the parent (the ethernet device itself) automatically. Stream slave masters differentiate which slave connection they are connected to by linking to the proxy object rather than the parent. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axidma: converted init->realizePeter Crosthwaite1-13/+13
The prescribed transition from SysBusDevice::init to Device::realize. I'm going with Andreas suggestion to move the sysbus foo to Object::init for early IRQ visibility. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axidma: Register reset properlyPeter Crosthwaite1-1/+11
Register the reset function as the Device::reset function rather than explicitly call it from the sysbus::init. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axidma: Defined and use type cast macroPeter Crosthwaite1-4/+9
Standard QOM cast macro. Replaces usages of FROM_SYSBUS Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-16xilinx_axidma: typedef XilinxAXIDMA structPeter Crosthwaite1-7/+9
Typedef xilinx_axidma's object state struct to shorten the repeated usages of struct XilinxAXIDMA. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Acked-by: Edgar E. Iglesias <edgar.iglesias@xilinx.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2013-04-08hw: move DMA controllers to hw/dma/, configure with default-configs/Paolo Bonzini7-0/+4530
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-08hw: move target-independent files to subdirectoriesPaolo Bonzini8-0/+4306
This patch tackles all files that are compiled once, moving them to subdirectories of hw/. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-08hw: make subdirectories for devicesPaolo Bonzini1-0/+0
Prepare the new directory structure. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>