1. 27 11月, 2018 1 次提交
  2. 31 8月, 2017 1 次提交
  3. 04 7月, 2017 1 次提交
  4. 07 6月, 2017 1 次提交
  5. 01 2月, 2017 2 次提交
  6. 25 1月, 2017 1 次提交
  7. 02 6月, 2016 1 次提交
  8. 11 3月, 2016 1 次提交
  9. 16 2月, 2016 1 次提交
  10. 07 2月, 2016 1 次提交
    • S
      fix MSI injection on Xen · 428c3ece
      Stefano Stabellini 提交于
      On Xen MSIs can be remapped into pirqs, which are a type of event
      channels. It's mostly for the benefit of PCI passthrough devices, to
      avoid the overhead of interacting with the emulated lapic.
      
      However remapping interrupts and MSIs is also supported for emulated
      devices, such as the e1000 and virtio-net.
      
      When an interrupt or an MSI is remapped into a pirq, masking and
      unmasking is done by masking and unmasking the event channel. The
      masking bit on the PCI config space or MSI-X table should be ignored,
      but it isn't at the moment.
      
      As a consequence emulated devices which use MSI or MSI-X, such as
      virtio-net, don't work properly (the guest doesn't receive any
      notifications). The mechanism was working properly when xen_apic was
      introduced, but I haven't narrowed down which commit in particular is
      causing the regression.
      
      Fix the issue by ignoring the masking bit for MSI and MSI-X which have
      been remapped into pirqs.
      Signed-off-by: NStefano Stabellini <stefano.stabellini@eu.citrix.com>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      428c3ece
  11. 29 1月, 2016 1 次提交
    • P
      pci: Clean up includes · 97d5408f
      Peter Maydell 提交于
      Clean up includes so that osdep.h is included first and headers
      which it implies are not included manually.
      
      This commit was created with scripts/clean-includes.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1453832250-766-23-git-send-email-peter.maydell@linaro.org
      97d5408f
  12. 25 10月, 2015 1 次提交
    • M
      msix: implement pba write (but read-only) · 43b11a91
      Marc-André Lureau 提交于
      qpci_msix_pending() writes on pba region, causing qemu to SEGV:
      
        Program received signal SIGSEGV, Segmentation fault.
        [Switching to Thread 0x7ffff7fba8c0 (LWP 25882)]
        0x0000000000000000 in ?? ()
        (gdb) bt
        #0  0x0000000000000000 in  ()
        #1  0x00005555556556c5 in memory_region_oldmmio_write_accessor (mr=0x5555579f3f80, addr=0, value=0x7fffffffbf68, size=4, shift=0, mask=4294967295, attrs=...) at /home/elmarco/src/qemu/memory.c:434
        #2  0x00005555556558e1 in access_with_adjusted_size (addr=0, value=0x7fffffffbf68, size=4, access_size_min=1, access_size_max=4, access=0x55555565563e <memory_region_oldmmio_write_accessor>, mr=0x5555579f3f80, attrs=...) at /home/elmarco/src/qemu/memory.c:506
        #3  0x00005555556581eb in memory_region_dispatch_write (mr=0x5555579f3f80, addr=0, data=0, size=4, attrs=...) at /home/elmarco/src/qemu/memory.c:1176
        #4  0x000055555560b6f9 in address_space_rw (as=0x555555eff4e0 <address_space_memory>, addr=3759147008, attrs=..., buf=0x7fffffffc1b0 "", len=4, is_write=true) at /home/elmarco/src/qemu/exec.c:2439
        #5  0x000055555560baa2 in cpu_physical_memory_rw (addr=3759147008, buf=0x7fffffffc1b0 "", len=4, is_write=1) at /home/elmarco/src/qemu/exec.c:2534
        #6  0x000055555564c005 in cpu_physical_memory_write (addr=3759147008, buf=0x7fffffffc1b0, len=4) at /home/elmarco/src/qemu/include/exec/cpu-common.h:80
        #7  0x000055555564cd9c in qtest_process_command (chr=0x55555642b890, words=0x5555578de4b0) at /home/elmarco/src/qemu/qtest.c:378
        #8  0x000055555564db77 in qtest_process_inbuf (chr=0x55555642b890, inbuf=0x55555641b340) at /home/elmarco/src/qemu/qtest.c:569
        #9  0x000055555564dc07 in qtest_read (opaque=0x55555642b890, buf=0x7fffffffc2e0 "writel 0xe0100800 0x0\n", size=22) at /home/elmarco/src/qemu/qtest.c:581
        #10 0x000055555574ce3e in qemu_chr_be_write (s=0x55555642b890, buf=0x7fffffffc2e0 "writel 0xe0100800 0x0\n", len=22) at qemu-char.c:306
        #11 0x0000555555751263 in tcp_chr_read (chan=0x55555642bcf0, cond=G_IO_IN, opaque=0x55555642b890) at qemu-char.c:2876
        #12 0x00007ffff64c9a8a in g_main_context_dispatch (context=0x55555641c400) at gmain.c:3122
      
      (without this patch, this can be reproduced with the ivshmem qtest)
      
      Implement an empty mmio write to avoid the crash.
      Signed-off-by: NMarc-André Lureau <marcandre.lureau@redhat.com>
      Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
      43b11a91
  13. 07 9月, 2015 1 次提交
    • P
      hw/pci: Use pow2ceil() rather than hand-calculation · 9bff5d81
      Peter Maydell 提交于
      A couple of places in hw/pci use an inline calculation to round a
      size up to the next largest power of 2. We have a utility routine
      for this, so use it.
      
      (The behaviour of the old code is different if the size value
      is 0 -- it would leave it as 0 rather than rounding up to 1,
      but in both cases we know the size can't be 0.
      In the case where the size value had bit 31 set, the old code
      would invoke undefined behaviour; the new code will give a
      result of 0. Presumably that could never happen either.)
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Message-id: 1437741192-20955-2-git-send-email-peter.maydell@linaro.org
      9bff5d81
  14. 01 6月, 2015 1 次提交
  15. 28 4月, 2015 1 次提交
    • J
      pci: remove hard-coded bar size in msix_init_exclusive_bar() · a0ccd212
      Jason Wang 提交于
      This patch lets msix_init_exclusive_bar() can calculate the bar and
      pba size based on the number of MSI-X vectors other than using a
      hard-coded limit 4096. This is needed to allow device to have more
      than 128 MSI_X vectors. To keep migration compatibility, keep using
      4096 as bar size and 2048 for pba offset.
      
      Notes: We don't care about the case that using vectors > 128 for
      legacy machine type. Since we limit the queue max to 64, so vectors >=
      65 is meaningless.
      
      Virtio device will be the first user for this.
      
      Cc: Keith Busch <keith.busch@intel.com>
      Cc: Kevin Wolf <kwolf@redhat.com>
      Cc: Stefan Hajnoczi <stefanha@redhat.com>
      Cc: Michael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NJason Wang <jasowang@redhat.com>
      Reviewed-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      a0ccd212
  16. 26 4月, 2015 1 次提交
    • P
      Switch non-CPU callers from ld/st*_phys to address_space_ld/st* · 42874d3a
      Peter Maydell 提交于
      Switch all the uses of ld/st*_phys to address_space_ld/st*,
      except for those cases where the address space is the CPU's
      (ie cs->as). This was done with the following script which
      generates a Coccinelle patch.
      
      A few over-80-columns lines in the result were rewrapped by
      hand where Coccinelle failed to do the wrapping automatically,
      as well as one location where it didn't put a line-continuation
      '\' when wrapping lines on a change made to a match inside
      a macro definition.
      
      ===begin===
      #!/bin/sh -e
      # Usage:
      # ./ldst-phys.spatch.sh > ldst-phys.spatch
      # spatch -sp_file ldst-phys.spatch -dir . | sed -e '/^+/s/\t/        /g' > out.patch
      # patch -p1 < out.patch
      
      for FN in ub uw_le uw_be l_le l_be q_le q_be uw l q; do
      cat <<EOF
      @ cpu_matches_ld_${FN} @
      expression E1,E2;
      identifier as;
      @@
      
      ld${FN}_phys(E1->as,E2)
      
      @ other_matches_ld_${FN} depends on !cpu_matches_ld_${FN} @
      expression E1,E2;
      @@
      
      -ld${FN}_phys(E1,E2)
      +address_space_ld${FN}(E1,E2, MEMTXATTRS_UNSPECIFIED, NULL)
      
      EOF
      
      done
      
      for FN in b w_le w_be l_le l_be q_le q_be w l q; do
      cat <<EOF
      @ cpu_matches_st_${FN} @
      expression E1,E2,E3;
      identifier as;
      @@
      
      st${FN}_phys(E1->as,E2,E3)
      
      @ other_matches_st_${FN} depends on !cpu_matches_st_${FN} @
      expression E1,E2,E3;
      @@
      
      -st${FN}_phys(E1,E2,E3)
      +address_space_st${FN}(E1,E2,E3, MEMTXATTRS_UNSPECIFIED, NULL)
      
      EOF
      
      done
      ===endit===
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NEdgar E. Iglesias <edgar.iglesias@xilinx.com>
      Reviewed-by: NAlex Bennée <alex.bennee@linaro.org>
      42874d3a
  17. 18 8月, 2014 1 次提交
  18. 14 8月, 2014 1 次提交
  19. 11 2月, 2014 1 次提交
  20. 04 7月, 2013 2 次提交
  21. 03 6月, 2013 1 次提交
  22. 08 1月, 2013 1 次提交
  23. 26 12月, 2012 2 次提交
  24. 19 12月, 2012 1 次提交
  25. 17 12月, 2012 2 次提交
  26. 14 12月, 2012 1 次提交
  27. 23 10月, 2012 1 次提交
    • A
      Rename target_phys_addr_t to hwaddr · a8170e5e
      Avi Kivity 提交于
      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: NAvi Kivity <avi@redhat.com>
      Signed-off-by: NAnthony Liguori <aliguori@us.ibm.com>
      a8170e5e
  28. 05 10月, 2012 1 次提交
  29. 30 8月, 2012 1 次提交
  30. 18 8月, 2012 1 次提交
  31. 19 7月, 2012 1 次提交
  32. 18 6月, 2012 5 次提交