Re: [PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-09-06 Thread Lu Baolu
Hi, On 09/07/2018 07:43 AM, Jacob Pan wrote: On Thu, 6 Sep 2018 10:46:03 +0800 Lu Baolu wrote: @@ -224,7 +271,14 @@ struct pasid_entry *intel_pasid_get_entry(struct device *dev, int pasid) */ static inline void pasid_clear_entry(struct pasid_entry *pe) { - WRITE_ONCE(pe->val,

Re: [PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-09-06 Thread Jacob Pan
On Thu, 6 Sep 2018 10:46:03 +0800 Lu Baolu wrote: > >> @@ -224,7 +271,14 @@ struct pasid_entry > >> *intel_pasid_get_entry(struct device *dev, int pasid) > >>*/ > >> static inline void pasid_clear_entry(struct pasid_entry *pe) > >> { > >> - WRITE_ONCE(pe->val, 0); > >> +

Re: [PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-09-05 Thread Lu Baolu
Hi, On 09/06/2018 10:52 AM, Tian, Kevin wrote: From: Lu Baolu [mailto:baolu...@linux.intel.com] Sent: Thursday, September 6, 2018 10:46 AM [...] @@ -143,8 +142,9 @@ int intel_pasid_alloc_table(struct device *dev) return -ENOMEM; INIT_LIST_HEAD(_table->dev); -

RE: [PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-09-05 Thread Tian, Kevin
> From: Lu Baolu [mailto:baolu...@linux.intel.com] > Sent: Thursday, September 6, 2018 10:46 AM > [...] > >> @@ -143,8 +142,9 @@ int intel_pasid_alloc_table(struct device *dev) > >>return -ENOMEM; > >>INIT_LIST_HEAD(_table->dev); > >> > >> - size = sizeof(struct pasid_entry); >

Re: [PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-09-05 Thread Lu Baolu
Hi, On 09/06/2018 10:14 AM, Tian, Kevin wrote: From: Lu Baolu [mailto:baolu...@linux.intel.com] Sent: Thursday, August 30, 2018 9:35 AM In scalable mode, pasid structure is a two level table with a pasid directory table and a pasid table. Any pasid entry can be identified by a pasid value in

RE: [PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-09-05 Thread Tian, Kevin
> From: Lu Baolu [mailto:baolu...@linux.intel.com] > Sent: Thursday, August 30, 2018 9:35 AM > > In scalable mode, pasid structure is a two level table with > a pasid directory table and a pasid table. Any pasid entry > can be identified by a pasid value in below way. > >1 >9

[PATCH v2 02/12] iommu/vt-d: Manage scalalble mode PASID tables

2018-08-29 Thread Lu Baolu
In scalable mode, pasid structure is a two level table with a pasid directory table and a pasid table. Any pasid entry can be identified by a pasid value in below way. 1 9 6 5 0 .---.---. | PASID| |