All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v2 0/2] pci/iommu: PCIe requester ID interface
@ 2013-07-11 21:03 Alex Williamson
  2013-07-11 21:03   ` Alex Williamson
  2013-07-11 21:03   ` Alex Williamson
  0 siblings, 2 replies; 54+ messages in thread
From: Alex Williamson @ 2013-07-11 21:03 UTC (permalink / raw)
  To: bhelgaas; +Cc: linux-pci, joro, iommu, acooks, ddutile, dwmw2

v2: second pass at refining the interface.  Rolled pci_requester_id
into pci_get_visible_pcie_requester.  Fixed some bus walk issues.

Another obscure issue that I forgot to mention that this should fix
is gaps in requester IDs.  If you had:

 ---pcie--->[pcie2pci]---pci--->[pci2pcie]---pcie--->[endpoint]

I think the current code would try to use the endpoint requester id and
fail.  This code will use the pcie2pci->secondary as the requester id.
This may not even be that obscure of a bug if a PCIe ASIC is soldered
to a pci2pcie bridge to make a compatible conventional PCI card.

The diffstat for pci improves a bit when we remove:
pci_find_upstream_pci_bridge:

 drivers/iommu/intel-iommu.c         |  164 ++++++++++-----------------
 drivers/iommu/intel_irq_remapping.c |    2 
 drivers/pci/search.c                |  215 +++++++++++++++++++++++++++++++-----
 include/linux/pci.h                 |   16 +-
 4 files changed, 260 insertions(+), 137 deletions(-)

Comments?  Thanks,

Alex

---

Alex Williamson (2):
      pci: Create PCIe requester ID interface
      iommu/intel: Make use of PCIe requester ID interface


 drivers/iommu/intel-iommu.c         |  164 +++++++++++------------------
 drivers/iommu/intel_irq_remapping.c |    2 
 drivers/pci/search.c                |  198 +++++++++++++++++++++++++++++++++++
 include/linux/pci.h                 |    7 +
 4 files changed, 270 insertions(+), 101 deletions(-)

^ permalink raw reply	[flat|nested] 54+ messages in thread
* re: [RFC PATCH v2 2/2] iommu/intel: Make use of PCIe requester ID interface
@ 2014-08-26  7:13 Andy Burns
       [not found] ` <53FC33AF.5040407-6TVDe6PzSGq9FHfhHBbuYA@public.gmane.org>
  0 siblings, 1 reply; 54+ messages in thread
From: Andy Burns @ 2014-08-26  7:13 UTC (permalink / raw)
  To: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA

I'm running into an IOMMU crash on CentOS7, it seems this patch series 
aims to fix the same type of issue, any thoughts as to whether it is 
likely to help in my case?

[ 0.451393] IOMMU: Prepare 0-16MiB unity mapping for LPC
[ 0.451400] IOMMU: Setting identity map for device 0000:00:1f.0 [0x0 - 
0xffffff]
[ 0.451455] PCI-DMA: Intel(R) Virtualization Technology for Directed I/O
[ 0.451546] ------------[ cut here ]------------
[ 0.451552] WARNING: at drivers/pci/search.c:46 
pci_find_upstream_pcie_bridge+0x87/0x90()
[ 0.451553] Modules linked in:
[ 0.451557] CPU: 2 PID: 1 Comm: swapper/0 Not tainted 
3.10.0-123.6.3.el7.x86_64 #1
[ 0.451558] Hardware name: To Be Filled By O.E.M. To Be Filled By 
O.E.M./H97 Pro4, BIOS P1.40 07/29/2014
[ 0.451559] 0000000000000000 000000003a87b4a1 ffff880408885cf0 
ffffffff815e20bb
[ 0.451561] ffff880408885d28 ffffffff8105dee1 ffff880408212000 
ffff88040821c000
[ 0.451563] ffff88040821c098 0000000000000000 0000000000000000 
ffff880408885d38
[ 0.451565] Call Trace:
[ 0.451570] [<ffffffff815e20bb>] dump_stack+0x19/0x1b
[ 0.451574] [<ffffffff8105dee1>] warn_slowpath_common+0x61/0x80
[ 0.451576] [<ffffffff8105e00a>] warn_slowpath_null+0x1a/0x20
[ 0.451579] [<ffffffff812ec727>] pci_find_upstream_pcie_bridge+0x87/0x90
[ 0.451582] [<ffffffff814a9d8d>] intel_iommu_add_device+0x4d/0x230
[ 0.451585] [<ffffffff814a0e30>] ? bus_set_iommu+0x50/0x50
[ 0.451588] [<ffffffff814a0e5a>] add_iommu_group+0x2a/0x50
[ 0.451591] [<ffffffff813b4563>] bus_for_each_dev+0x73/0xc0
[ 0.451593] [<ffffffff814a0e28>] bus_set_iommu+0x48/0x50
[ 0.451597] [<ffffffff81a58273>] intel_iommu_init+0x3ea/0x413
[ 0.451601] [<ffffffff81a11c93>] ? memblock_find_dma_reserve+0x147/0x147
[ 0.451603] [<ffffffff81a11ca5>] pci_iommu_init+0x12/0x3c
[ 0.451606] [<ffffffff810020e2>] do_one_initcall+0xe2/0x190
[ 0.451608] [<ffffffff81a09153>] kernel_init_freeable+0x18b/0x22a
[ 0.451610] [<ffffffff81a0892b>] ? do_early_param+0x88/0x88
[ 0.451614] [<ffffffff815c3960>] ? rest_init+0x80/0x80
[ 0.451617] [<ffffffff815c396e>] kernel_init+0xe/0x180
[ 0.451619] [<ffffffff815f26ec>] ret_from_fork+0x7c/0xb0
[ 0.451621] [<ffffffff815c3960>] ? rest_init+0x80/0x80
[ 0.451626] ---[ end trace e5ab4299053e7cdf ]---

I will report back after testing. To save duplication there's info about 
my setup here ...

<http://centos.org/forums/viewtopic.php?f=47&t=48115>

^ permalink raw reply	[flat|nested] 54+ messages in thread

end of thread, other threads:[~2014-08-26 10:33 UTC | newest]

Thread overview: 54+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-11 21:03 [RFC PATCH v2 0/2] pci/iommu: PCIe requester ID interface Alex Williamson
2013-07-11 21:03 ` [RFC PATCH v2 1/2] pci: Create " Alex Williamson
2013-07-11 21:03   ` Alex Williamson
2013-07-23 22:35   ` Bjorn Helgaas
2013-07-23 22:35     ` Bjorn Helgaas
2013-07-23 23:21     ` Alex Williamson
2013-07-23 23:21       ` Alex Williamson
2013-07-24 15:03       ` Andrew Cooks
2013-07-24 15:03         ` Andrew Cooks
2013-07-24 15:50         ` Alex Williamson
2013-07-24 15:50           ` Alex Williamson
2013-07-24 16:47       ` Bjorn Helgaas
2013-07-24 16:47         ` Bjorn Helgaas
2013-07-24 18:12         ` Alex Williamson
2013-07-24 18:12           ` Alex Williamson
2013-07-24 23:24           ` Bjorn Helgaas
2013-07-25 17:56             ` Alex Williamson
2013-07-25 17:56               ` Alex Williamson
2013-07-26 21:54               ` Bjorn Helgaas
2013-07-29 16:06                 ` Alex Williamson
2013-07-29 21:02                   ` Bjorn Helgaas
2013-07-29 22:32                     ` Alex Williamson
2013-07-29 22:32                       ` Alex Williamson
2013-08-01 22:08                       ` Bjorn Helgaas
2013-08-02 16:59                         ` Alex Williamson
2013-08-02 16:59                           ` Alex Williamson
2014-04-03 21:48                           ` Bjorn Helgaas
2014-04-03 21:48                             ` Bjorn Helgaas
2014-04-04  2:51                             ` Alex Williamson
2014-04-04  2:51                               ` Alex Williamson
2014-04-04 15:00                               ` Bjorn Helgaas
2014-04-04 15:00                                 ` Bjorn Helgaas
2013-07-29 21:03                   ` Don Dutile
2013-07-29 22:55                     ` Alex Williamson
2013-07-29 22:55                       ` Alex Williamson
2013-07-24 20:42     ` Don Dutile
2013-07-24 20:42       ` Don Dutile
2013-07-24 21:22       ` Alex Williamson
2013-07-24 21:22         ` Alex Williamson
2013-07-25 18:38         ` Don Dutile
2013-07-25 18:38           ` Don Dutile
2013-07-25 17:19       ` Bjorn Helgaas
2013-07-25 17:19         ` Bjorn Helgaas
2013-07-25 18:25         ` Don Dutile
2013-07-25 18:25           ` Don Dutile
2013-07-26 19:48           ` Bjorn Helgaas
2013-07-26 19:48             ` Bjorn Helgaas
2013-07-26 20:04             ` Don Dutile
2013-07-26 20:04               ` Don Dutile
2013-07-11 21:03 ` [RFC PATCH v2 2/2] iommu/intel: Make use of " Alex Williamson
2013-07-11 21:03   ` Alex Williamson
2014-08-26  7:13 Andy Burns
     [not found] ` <53FC33AF.5040407-6TVDe6PzSGq9FHfhHBbuYA@public.gmane.org>
2014-08-26  7:49   ` Andy Burns
     [not found]     ` <53FC3C07.8050906-6TVDe6PzSGq9FHfhHBbuYA@public.gmane.org>
2014-08-26 10:33       ` Andy Burns

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.