summaryrefslogtreecommitdiffstats
path: root/hw/pcie_aer.c
Commit message (Collapse)AuthorAgeFilesLines
* pcie/aer: fix inject aer error commandIsaku Yamahata2011-08-241-4/+5
| | | | | | | | | | various fixes to make aer inject error command work. - wrong assert - command line parser - err.status needs initialization Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* Use glib memory allocation and free functionsAnthony Liguori2011-08-201-2/+2
| | | | | | qemu_malloc/qemu_free no longer exist after this commit. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* Merge remote-tracking branch 'origin/master' into pciMichael S. Tsirkin2011-06-151-1/+1
|\ | | | | | | | | Conflicts: hw/virtio-pci.c
| * Fix typo in comment (responsiblity -> responsibility)Stefan Weil2011-05-081-1/+1
| | | | | | | | | | Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
* | pci: Update pci_regs headerJan Kiszka2011-06-121-2/+7
|/ | | | | | | | | | | Pulls in latest version from kernel 3.0-rc2. Some changes around AER now require local defines as QEMU accesses the error source identification register via sub-words. CC: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* vmstate: move VMSTATE_PCIE_AER_ERRS to hw/hw.hDmitry Eremin-Solenikov2011-03-031-11/+1
| | | | | | | | | | VMSTATE_PCIE_AER_ERRS is indeed useful for other emulation drivers. Move it to hw/hw.h under the name of VMSTATE_STRUCT_VARRAY_POINTER_UINT16. Also add VMSTATE_STRUCT_VARRAY_POINTER_INT32 which is more or less the same as _UINT16 macro, except the fact it uses int32_t internally. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> Signed-off-by: Andrzej Zaborowski <andrew.zaborowski@intel.com>
* pcie/aer: glue aer error injection into qemu monitorIsaku Yamahata2010-12-241-0/+223
| | | | | | | introduce pcie_aer_inject_error command. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* pci/aer: factor out common codeMichael S. Tsirkin2010-12-091-14/+13
| | | | | | | Same logic is used to assert interrupts and send msix messages, so add a static functin for this. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* pci/aer: remove dead codeMichael S. Tsirkin2010-12-091-23/+2
| | | | | | | Remove some unused variables and return values. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* pci/aer: fix interrupt on config writeMichael S. Tsirkin2010-12-091-29/+17
| | | | | | | | | | | | | config write handling for aer seems broken: For example, it won't clear a level interrupt when command register is set to 0. Make it match the spec: level should equal the logical or of enabled bits, msi only be sent when the logical or changes. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* pci/aer: fix error injectionMichael S. Tsirkin2010-12-091-16/+35
| | | | | | | | | | Fix the injection logic upon aer message to follow 6.2.4.1.2 more closely: specifically only send an msi interrupt when the logical or of the enabled bits changed, not when a bit which was previously clear becomes set. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* pci: untangle pci/msi dependencyMichael S. Tsirkin2010-12-091-8/+16
| | | | | | | | | | | | msi depends on pci but pci should not depend on msi. The only dependency we have is a recent addition of pci_msi_ functions, IMO they add little enough to open-code in the small number of users. Follow-up patches add more cleanups. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
* Fix mingw32 and OpenBSD warningsBlue Swirl2010-12-041-1/+1
| | | | | | | | | | | ffsl() is not universally available, so there are these warnings on both mingw32 and OpenBSD: /src/qemu/hw/pcie_aer.c: In function 'pcie_aer_update_log': /src/qemu/hw/pcie_aer.c:399: warning: implicit declaration of function 'ffsl' Since status field in PCIEAERErr is uint32_t, we can just use ffs() instead. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* pcie_aer: complete unwinding recursionMichael S. Tsirkin2010-11-221-53/+27
| | | | | | | | | Open-code functions created in the previous patch, to make code more compact and clear. Detcted and documented what looks like a bug in code that becomes apparent from this refactoring. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* pcie_aer: get rid of recursionMichael S. Tsirkin2010-11-221-17/+31
| | | | | | | Added some TODOs: they are trivial but omitted here to make the patch logic as transparent as possible. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
* pcie/aer: helper functions for pcie aer capabilityIsaku Yamahata2010-11-221-0/+827
This patch implements helper functions for pcie aer capability which will be used later. Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
OpenPOWER on IntegriCloud