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

Re: [PATCH 12/12] xen/arm: call iomem_permit_access for passthrough devices


On 30/04/2020 14:01, Julien Grall wrote:
On 29/04/2020 21:47, Stefano Stabellini wrote:
On Wed, 15 Apr 2020, Julien Grall wrote: But doesn't it make sense to give domU permission if it is going to get
the memory mapped? But admittedly I can't think of something that would
break because of the lack of the iomem_permit_access call in this code

On Arm, the permissions are only useful if you plan you DomU to delegate the regions to another domain. As your domain is not even aware it is running on Xen (we don't expose 'xen' node in the DT), it makes little sense to add the permission.

I actually found one use when helping a user last week. You can dump the list of MMIO regions assigned to a guest from Xen Console.

This will use d->iomem_caps that is modified via iomem_permit_access(). Without it, there is no easy way to confirm the list of MMIO regions assigned to a guest. Although...

Even today, you can map IOMEM to a DomU and then revert the permission right after. They IOMEM will still be mapped in the guest and it will act normaly.

... this would not help the case where permissions are reverted. But I am assuming this shouldn't happen for Dom0less.

Stefano, I am not sure what's your plan for the series itself for Xen 4.14. I think this patch could go in now. Any thoughts?


Julien Grall



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.