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

Re: [Xen-devel] [RFC 15/16] xen/arm: Implement Set/Way operations



Hi Stefano,

On 06/11/2018 17:31, Stefano Stabellini wrote:
On Mon, 5 Nov 2018, Julien Grall wrote:
This will affect all the registers trapped with TVM. Shouldn't we only
call p2m_toggle_cache when relevant? i.e. when changing SCTLR?
I think it would be better to only modify the SCTLR emulation handler.

This is made on purpose, you increase the chance to disable TVM as soon as
possible. If you only rely on SCTLR, you may end up to trap a lot of registers
for a long time.

FWIW, as I already wrote in the commit message, this is based on what KVM
does.

I missed that. As you explain it, it makes sense. Maybe worth adding an
explicit statement about it: "On ARM64, we call p2m_toggle_cache from on
the TVM-trapped register handlers to increase the chances of disabling
TVM as soon as possible."

I am assuming you meant arm32 here? Looking at the code, it looks like I implemented the arm64 differently. But we probably want apply to call p2m_toggle_cache in all TVM trapped registers.

This would keep the logic everywhere the same.

Cheers,

--
Julien Grall

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

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