Re: [Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-12 Thread Yu Zhang
On Tue, Nov 13, 2018 at 01:18:54PM +0800, Peter Xu wrote: > On Mon, Nov 12, 2018 at 08:38:30PM +0800, Yu Zhang wrote: > > On Mon, Nov 12, 2018 at 05:36:38PM +0800, Peter Xu wrote: > > > On Mon, Nov 12, 2018 at 05:25:48PM +0800, Yu Zhang wrote: > > > > On Mon, Nov 12, 2018 at 04:51:22PM +0800,

Re: [Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-12 Thread Peter Xu
On Mon, Nov 12, 2018 at 08:38:30PM +0800, Yu Zhang wrote: > On Mon, Nov 12, 2018 at 05:36:38PM +0800, Peter Xu wrote: > > On Mon, Nov 12, 2018 at 05:25:48PM +0800, Yu Zhang wrote: > > > On Mon, Nov 12, 2018 at 04:51:22PM +0800, Peter Xu wrote: > > > > On Fri, Nov 09, 2018 at 07:49:47PM +0800, Yu

Re: [Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-12 Thread Yu Zhang
On Mon, Nov 12, 2018 at 05:36:38PM +0800, Peter Xu wrote: > On Mon, Nov 12, 2018 at 05:25:48PM +0800, Yu Zhang wrote: > > On Mon, Nov 12, 2018 at 04:51:22PM +0800, Peter Xu wrote: > > > On Fri, Nov 09, 2018 at 07:49:47PM +0800, Yu Zhang wrote: > > > > This patch updates vtd_lookup_iotlb() to

Re: [Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-12 Thread Peter Xu
On Mon, Nov 12, 2018 at 05:25:48PM +0800, Yu Zhang wrote: > On Mon, Nov 12, 2018 at 04:51:22PM +0800, Peter Xu wrote: > > On Fri, Nov 09, 2018 at 07:49:47PM +0800, Yu Zhang wrote: > > > This patch updates vtd_lookup_iotlb() to search cached mappings only > > > for all page levels supported by

Re: [Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-12 Thread Yu Zhang
On Mon, Nov 12, 2018 at 04:51:22PM +0800, Peter Xu wrote: > On Fri, Nov 09, 2018 at 07:49:47PM +0800, Yu Zhang wrote: > > This patch updates vtd_lookup_iotlb() to search cached mappings only > > for all page levels supported by address width of current vIOMMU. Also, > > to cover 57-bit width, the

Re: [Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-12 Thread Peter Xu
On Fri, Nov 09, 2018 at 07:49:47PM +0800, Yu Zhang wrote: > This patch updates vtd_lookup_iotlb() to search cached mappings only > for all page levels supported by address width of current vIOMMU. Also, > to cover 57-bit width, the shift of source id(VTD_IOTLB_SID_SHIFT) and > of page

[Qemu-devel] [PATCH v1 3/3] intel-iommu: search iotlb for levels supported by the address width.

2018-11-09 Thread Yu Zhang
This patch updates vtd_lookup_iotlb() to search cached mappings only for all page levels supported by address width of current vIOMMU. Also, to cover 57-bit width, the shift of source id(VTD_IOTLB_SID_SHIFT) and of page level(VTD_IOTLB_LVL_SHIFT) are enlarged by 9 - the stride of one paging