1. 24 10月, 2012 6 次提交
  2. 23 10月, 2012 32 次提交
  3. 22 10月, 2012 2 次提交
    • A
      pci: honor PCI_COMMAND_MASTER · 1c380f94
      Avi Kivity 提交于
      Currently we ignore PCI_COMMAND_MASTER completely: DMA succeeds even when
      the bit is clear.
      
      Honor PCI_COMMAND_MASTER by inserting a memory region into the device's
      bus master address space, and tying its enable status to PCI_COMMAND_MASTER.
      
      Tested using
      
        setpci -s 03 COMMAND=3
      
      while a ping was running on a NIC in slot 3.  The kernel (Linux) detected
      the stall and recovered after the command
      
        setpci -s 03 COMMAND=7
      
      was issued.
      Signed-off-by: NAvi Kivity <avi@redhat.com>
      1c380f94
    • A
      pci: give each device its own address space · 817dcc53
      Avi Kivity 提交于
      Accesses from different devices can resolve differently
      (depending on bridge settings, iommus, and PCI_COMMAND_MASTER), so
      set up an address space for each device.
      
      Currently iommus are expressed outside the memory API, so this doesn't
      work if an iommu is present.
      Signed-off-by: NAvi Kivity <avi@redhat.com>
      817dcc53