qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH qemu v17 06/12] memory: Add reporting of support


From: Alexey Kardashevskiy
Subject: Re: [Qemu-devel] [PATCH qemu v17 06/12] memory: Add reporting of supported page sizes
Date: Wed, 15 Jun 2016 07:41:51 +1000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.0

On 08/06/16 16:05, Alexey Kardashevskiy wrote:
> On 08/06/16 16:00, David Gibson wrote:
>> On Mon, Jun 06, 2016 at 03:31:04PM +0200, Paolo Bonzini wrote:
>>>
>>>
>>> On 02/06/2016 05:35, David Gibson wrote:
>>>> On Wed, Jun 01, 2016 at 06:57:37PM +1000, Alexey Kardashevskiy wrote:
>>>>>> Every IOMMU has some granularity which MemoryRegionIOMMUOps::translate
>>>>>> uses when translating, however this information is not available outside
>>>>>> the translate context for various checks.
>>>>>>
>>>>>> This adds a get_page_sizes callback to MemoryRegionIOMMUOps and
>>>>>> a wrapper for it so IOMMU users (such as VFIO) can know the actual
>>>>>> page size(s) used by an IOMMU.
>>>>>>
>>>>>> As IOMMU MR represents a guest IOMMU, this uses TARGET_PAGE_SIZE
>>>>>> as fallback.
>>>>>>
>>>>>> This removes vfio_container_granularity() and uses new helper in
>>>>>> memory_region_iommu_replay() when replaying IOMMU mappings on added
>>>>>> IOMMU memory region.
>>>>>>
>>>>>> Signed-off-by: Alexey Kardashevskiy <address@hidden>
>>>>>> Reviewed-by: David Gibson <address@hidden>
>>>> Paolo,
>>>>
>>>> Looks like you were left off the CC for this one.
>>>>
>>>> I think this is ready to go - do you want to merge, comment or ack and
>>>> we'll take it either through my tree or Alex's?
>>>
>>> It's okay for you to merge, but the callback should be called
>>> "get_page_size" or "get_replay_granularity".  The plural is weird.
>>
>> Hm, no, it really could return multiple page sizes if the logical
>> (guest side) IOMMU supports them.
> 
> It could but it does not now and I cannot see it coming in near future so I
> am really confused now about the naming and what the callback should return
> - one page size or a mask. What should it be now?


Paolo, David?


> 
>> That might be useful at some point
>> in the future.  For now, it's sufficient for the replay to use the
>> smallest pagesize.
>>
> 
> 


-- 
Alexey

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]