PCI: Add support for DMA alias quirks
authorAlex Williamson <alex.williamson@redhat.com>
Thu, 22 May 2014 23:07:43 +0000 (17:07 -0600)
committerBjorn Helgaas <bhelgaas@google.com>
Wed, 28 May 2014 21:20:31 +0000 (15:20 -0600)
commit31c2b8153c58f11ddb80dfd392c16f13c2d709c6
tree7ceb946ee75079ed1552f9a60e471a97bb3fa72b
parent6b121592f8a3fd2bd0de128637b76a0d0864d993
PCI: Add support for DMA alias quirks

Some devices are broken and use a requester ID other than their physical
devfn.  Add a byte, using an existing gap in the pci_dev structure, to
store an alternate "alias" devfn.  A bit in the dev_flags tells us when
this is valid.  We then add the alias as one more step in the
pci_for_each_dma_alias() iterator.

Tested-by: George Spelvin <linux@horizon.com>
Tested-by: Pat Erley <pat-lkml@erley.org>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/search.c
include/linux/pci.h