All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Xu, Quan" <quan.xu@intel.com>
To: "Tian, Kevin" <kevin.tian@intel.com>,
	"xen-devel@lists.xen.org" <xen-devel@lists.xen.org>
Cc: "dario.faggioli@citrix.com" <dario.faggioli@citrix.com>,
	"Wu, Feng" <feng.wu@intel.com>, Jan Beulich <jbeulich@suse.com>
Subject: Re: [PATCH v12 6/6] vt-d: fix vt-d Device-TLB flush timeout issue
Date: Sun, 26 Jun 2016 09:18:42 +0000	[thread overview]
Message-ID: <945CA011AD5F084CBEA3E851C0AB28894B8F668C@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <AADFC41AFE54684AB9EE6CBC0274A5D15F8D59F6@SHSMSX101.ccr.corp.intel.com>

On June 24, 2016 7:55 PM, Tian, Kevin <kevin.tian@intel.com> wrote:
> > From: Xu, Quan
> > Sent: Friday, June 24, 2016 1:52 PM
> > diff --git a/xen/drivers/passthrough/vtd/extern.h
> > b/xen/drivers/passthrough/vtd/extern.h
> > index 45357f2..efaff28 100644
> > --- a/xen/drivers/passthrough/vtd/extern.h
> > +++ b/xen/drivers/passthrough/vtd/extern.h
> > @@ -25,6 +25,7 @@
> >
> >  #define VTDPREFIX "[VT-D]"
> >
> > +struct pci_ats_dev;
> >  extern bool_t rwbf_quirk;
> >
> >  void print_iommu_regs(struct acpi_drhd_unit *drhd); @@ -60,8 +61,8 @@
> > int dev_invalidate_iotlb(struct iommu *iommu, u16 did,
> >                           u64 addr, unsigned int size_order, u64
> > type);
> >
> >  int __must_check qinval_device_iotlb_sync(struct iommu *iommu,
> > -                                          u32 max_invs_pend,
> > -                                          u16 sid, u16 size, u64 addr);
> > +                                          struct pci_ats_dev *ats_dev,
> > +                                          u16 did, u16 size, u64
> > + addr);
> >
> >  unsigned int get_cache_line_size(void);  void cacheline_flush(char
> > *); diff --git a/xen/drivers/passthrough/vtd/qinval.c
> > b/xen/drivers/passthrough/vtd/qinval.c
> > index 4492b29..e4e2771 100644
> > --- a/xen/drivers/passthrough/vtd/qinval.c
> > +++ b/xen/drivers/passthrough/vtd/qinval.c
> > @@ -27,11 +27,11 @@
> >  #include "dmar.h"
> >  #include "vtd.h"
> >  #include "extern.h"
> > +#include "../ats.h"
> 
> Earlier you said:
> >    1. a forward declaration struct pci_ats_dev*, instead of
> >       including ats.h.
>

This context is 'in extern.h', but..

> But above you still have ats.h included.
> 

.. I really need to include 'ats.h' here, as the 'struct pci_ats_dev*' is used in this file.

> >
> >  #define VTD_QI_TIMEOUT	1
> >
> > -static int __must_check invalidate_sync(struct iommu *iommu,
> > -                                        bool_t flush_dev_iotlb);
> > +static int __must_check invalidate_sync(struct iommu *iommu);
> 
> I don't understand the rationale behind. In earlier patch you introduce a new
> parameter which is however just removed later here....
> 
In earlier patch, refactor invalidate_sync() to indicate whether we need to flush device IOTLB or not.
change it back here, as I add a specific function - dev_invalidate_sync() for device IOTLB invalidation..

Quan





_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

  parent reply	other threads:[~2016-06-26  9:18 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-24  5:51 [PATCH v12 0/6] VT-d Device-TLB flush issue Xu, Quan
2016-06-24  5:51 ` [PATCH v12 1/6] IOMMU: add a timeout parameter for device IOTLB invalidation Xu, Quan
2016-06-24 11:30   ` Tian, Kevin
2016-06-27  8:03   ` Jan Beulich
2016-06-27  8:19     ` Xu, Quan
2016-06-27  8:28       ` Jan Beulich
2016-06-27  8:34         ` Xu, Quan
2016-06-24  5:51 ` [PATCH v12 2/6] vt-d: synchronize for Device-TLB flush one by one Xu, Quan
2016-06-24 11:33   ` Tian, Kevin
2016-06-24  5:51 ` [PATCH v12 3/6] vt-d: convert conditionals of qi_ctrl->qinval_maddr into ASSERT()s Xu, Quan
2016-06-24 11:35   ` Tian, Kevin
2016-06-24  5:51 ` [PATCH v12 4/6] IOMMU/x86: using a struct pci_dev* instead of SBDF Xu, Quan
2016-06-24 11:46   ` Tian, Kevin
2016-06-26  8:57     ` Xu, Quan
2016-06-26 10:32     ` Xu, Quan
2016-06-29  1:59       ` Tian, Kevin
2016-06-27  8:17   ` Jan Beulich
2016-06-27  8:25     ` Jan Beulich
2016-06-27 11:11     ` Xu, Quan
2016-06-27 15:19       ` Jan Beulich
2016-06-28  1:31         ` Xu, Quan
2016-06-24  5:51 ` [PATCH v12 5/6] IOMMU: move the domain crash logic up to the generic IOMMU layer Xu, Quan
2016-06-24 11:48   ` Tian, Kevin
2016-06-26  8:58     ` Xu, Quan
2016-06-27  8:18       ` Jan Beulich
2016-06-24  5:51 ` [PATCH v12 6/6] vt-d: fix vt-d Device-TLB flush timeout issue Xu, Quan
2016-06-24 11:55   ` Tian, Kevin
2016-06-24 12:54     ` Jan Beulich
2016-06-26  9:18     ` Xu, Quan [this message]
2016-06-27  7:56       ` Jan Beulich
2016-06-27  8:24   ` Jan Beulich
2016-06-27 12:56     ` Xu, Quan
2016-06-27 15:21       ` Jan Beulich
2016-06-28  7:06         ` Xu, Quan
2016-06-28  7:24           ` Jan Beulich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=945CA011AD5F084CBEA3E851C0AB28894B8F668C@SHSMSX101.ccr.corp.intel.com \
    --to=quan.xu@intel.com \
    --cc=dario.faggioli@citrix.com \
    --cc=feng.wu@intel.com \
    --cc=jbeulich@suse.com \
    --cc=kevin.tian@intel.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.