All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] VT-d flush issue
@ 2015-12-10  9:33 Quan Xu
  2015-12-10  9:33 ` [PATCH v2 1/2] VT-d: Reduce spin timeout to 1ms, which can be boot-time changed Quan Xu
  2015-12-10  9:33 ` [PATCH v2 2/2] VT-d: Fix vt-d flush timeout issue Quan Xu
  0 siblings, 2 replies; 24+ messages in thread
From: Quan Xu @ 2015-12-10  9:33 UTC (permalink / raw)
  To: jbeulich, kevin.tian
  Cc: feng.wu, eddie.dong, george.dunlap, andrew.cooper3, tim,
	xen-devel, jun.nakajima, Quan Xu, keir

This patches are based on Kevin Tian's previous discussion 'Revisit VT-d asynchronous flush issue'.
Fix current timeout concern and also allow limited ATS support in a light way:

1. Reduce spin timeout to 1ms, which can be boot-time changed with 'iommu_qi_timeout_ms'.
   For example:
           multiboot /boot/xen.gz ats=1 iommu_qi_timeout_ms=100

2. Fix vt-d flush timeout issue.

    If IOTLB/Context/IETC flush is timeout, we should think all devices under this IOMMU cannot function correctly.
    So for each device under this IOMMU we'll mark it as unassignable and kill the domain owning the device.

    If Device-TLB flush is timeout, we'll mark the target ATS device as unassignable and kill the domain owning
    this device.

    If impacted domain is hardware domain, just throw out a warning. It's an open here whether we want to kill
    hardware domain (or directly panic hypervisor). Comments are welcomed.

    Device marked as unassignable will be disallowed to be further assigned to any domain.

*Kevin Tian did basic functional review.

--Changes in v2:
    1. Checking hardware_domain should be enough.
    2. Do timeout check within dev_invalidate_iotlb for each ATS device, to identify bogus device accurately.

Quan Xu (2):
  VT-d: Reduce spin timeout to 1ms, which can be boot-time changed.
  VT-d: Fix vt-d flush timeout issue.

 xen/drivers/passthrough/vtd/extern.h  |  4 ++
 xen/drivers/passthrough/vtd/iommu.c   |  6 +++
 xen/drivers/passthrough/vtd/iommu.h   |  5 ++
 xen/drivers/passthrough/vtd/qinval.c  | 97 +++++++++++++++++++++++++++++++++--
 xen/drivers/passthrough/vtd/x86/ats.c | 16 ++++++
 xen/include/xen/pci.h                 |  7 +++
 6 files changed, 131 insertions(+), 4 deletions(-)

-- 
1.9.1

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

end of thread, other threads:[~2015-12-14  8:49 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-10  9:33 [PATCH v2 0/2] VT-d flush issue Quan Xu
2015-12-10  9:33 ` [PATCH v2 1/2] VT-d: Reduce spin timeout to 1ms, which can be boot-time changed Quan Xu
2015-12-10 19:03   ` Andrew Cooper
2015-12-11  2:09     ` Xu, Quan
2015-12-11  7:00       ` Tian, Kevin
2015-12-11  7:29         ` Xu, Quan
2015-12-11  8:37       ` Andrew Cooper
2015-12-11  8:45         ` Xu, Quan
2015-12-11 10:01   ` Jan Beulich
2015-12-11 14:03     ` Xu, Quan
2015-12-12  9:03     ` Xu, Quan
2015-12-14  8:18       ` Jan Beulich
2015-12-14  8:31         ` Xu, Quan
2015-12-14  8:49           ` Jan Beulich
2015-12-10  9:33 ` [PATCH v2 2/2] VT-d: Fix vt-d flush timeout issue Quan Xu
2015-12-10 19:05   ` Andrew Cooper
2015-12-11  5:37     ` Xu, Quan
2015-12-11  8:38       ` Andrew Cooper
2015-12-11  8:42         ` Xu, Quan
2015-12-11  7:27   ` Tian, Kevin
2015-12-11  8:01     ` Xu, Quan
2015-12-11 10:04       ` Jan Beulich
2015-12-11 14:00         ` Xu, Quan
2015-12-11 14:12           ` Xu, Quan

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.