Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-29 Thread Alexey Kardashevskiy
On 08/30/2013 04:39 PM, Paolo Bonzini wrote: > Il 30/08/2013 08:15, Alexey Kardashevskiy ha scritto: What if you just merge the two series together? >> It will still be a function which can accept sections bigger than 2^64 and >> theoretically call int128_get64() and assert. I would think that

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-29 Thread Paolo Bonzini
Il 30/08/2013 08:15, Alexey Kardashevskiy ha scritto: >> > What if you just merge the two series together? > It will still be a function which can accept sections bigger than 2^64 and > theoretically call int128_get64() and assert. I would think that every time > when anyone calls int128_get64(), t

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-29 Thread Alexey Kardashevskiy
On 08/29/2013 06:50 PM, Paolo Bonzini wrote: > Il 29/08/2013 08:58, Alexey Kardashevskiy ha scritto: >> On 08/29/2013 04:29 PM, Paolo Bonzini wrote: >>> Il 29/08/2013 04:26, Alexey Kardashevskiy ha scritto: Right. I was planning to add my IOMMU stuff right before calculating @end. >>> >>>

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-29 Thread Paolo Bonzini
Il 29/08/2013 08:58, Alexey Kardashevskiy ha scritto: > On 08/29/2013 04:29 PM, Paolo Bonzini wrote: >> Il 29/08/2013 04:26, Alexey Kardashevskiy ha scritto: >>> >>> Right. I was planning to add my IOMMU stuff right before calculating @end. >> >> But then the non-IOMMU stuff can just use int128_get

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-29 Thread Alexey Kardashevskiy
On 08/29/2013 04:29 PM, Paolo Bonzini wrote: > Il 29/08/2013 04:26, Alexey Kardashevskiy ha scritto: >> >> Right. I was planning to add my IOMMU stuff right before calculating @end. > > But then the non-IOMMU stuff can just use int128_get64, no? So even if > this patch simply uses int128_get64, i

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-28 Thread Paolo Bonzini
Il 29/08/2013 04:26, Alexey Kardashevskiy ha scritto: > > Right. I was planning to add my IOMMU stuff right before calculating @end. But then the non-IOMMU stuff can just use int128_get64, no? So even if this patch simply uses int128_get64, it is still a suitable basis for adding IOMMU stuff. P

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-28 Thread Alexey Kardashevskiy
On 08/29/2013 11:42 AM, Alex Williamson wrote: > On Thu, 2013-08-29 at 11:03 +1000, Alexey Kardashevskiy wrote: >> On 08/29/2013 01:18 AM, Alex Williamson wrote: >>> On Thu, 2013-08-22 at 21:29 +1000, Alexey Kardashevskiy wrote: Upcoming VFIO on SPAPR PPC64 support will initialize the IOMMU >>

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-28 Thread Alex Williamson
On Thu, 2013-08-29 at 11:03 +1000, Alexey Kardashevskiy wrote: > On 08/29/2013 01:18 AM, Alex Williamson wrote: > > On Thu, 2013-08-22 at 21:29 +1000, Alexey Kardashevskiy wrote: > >> Upcoming VFIO on SPAPR PPC64 support will initialize the IOMMU > >> memory region with UINT64_MAX (2^64 bytes) size

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-28 Thread Alexey Kardashevskiy
On 08/29/2013 01:18 AM, Alex Williamson wrote: > On Thu, 2013-08-22 at 21:29 +1000, Alexey Kardashevskiy wrote: >> Upcoming VFIO on SPAPR PPC64 support will initialize the IOMMU >> memory region with UINT64_MAX (2^64 bytes) size so int128_get64() >> will assert. >> >> The patch takes care of this c

Re: [Qemu-devel] [PATCH v3 3/3] vfio: Fix 128 bit handling

2013-08-28 Thread Alex Williamson
On Thu, 2013-08-22 at 21:29 +1000, Alexey Kardashevskiy wrote: > Upcoming VFIO on SPAPR PPC64 support will initialize the IOMMU > memory region with UINT64_MAX (2^64 bytes) size so int128_get64() > will assert. > > The patch takes care of this check. The existing type1 IOMMU code > is not expected