kvmarm.lists.cs.columbia.edu archive mirror
 help / color / mirror / Atom feed
* unmap_ptes is not complete
@ 2017-11-27 21:10 Raz
  2017-11-29 18:08 ` Christoffer Dall
  0 siblings, 1 reply; 2+ messages in thread
From: Raz @ 2017-11-27 21:10 UTC (permalink / raw)
  To: kvmarm


[-- Attachment #1.1: Type: text/plain, Size: 306 bytes --]

Hey
in mmu.c unmap_ptes() you invalidate *pte but not the pte itself. This
leads to inconsistency in el2 translation tables. ie; the pte entry is
cleared in the cached memory but not in the RAM, so the entry may still be
valid in EL2 translation tables.
You should also clear pte itself.

Kind Regards
Raz

[-- Attachment #1.2: Type: text/html, Size: 395 bytes --]

[-- Attachment #2: Type: text/plain, Size: 151 bytes --]

_______________________________________________
kvmarm mailing list
kvmarm@lists.cs.columbia.edu
https://lists.cs.columbia.edu/mailman/listinfo/kvmarm

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: unmap_ptes is not complete
  2017-11-27 21:10 unmap_ptes is not complete Raz
@ 2017-11-29 18:08 ` Christoffer Dall
  0 siblings, 0 replies; 2+ messages in thread
From: Christoffer Dall @ 2017-11-29 18:08 UTC (permalink / raw)
  To: Raz; +Cc: kvmarm

Hi Raz,

On Mon, Nov 27, 2017 at 09:10:56PM +0000, Raz wrote:
> Hey
> in mmu.c unmap_ptes() you invalidate *pte but not the pte itself. This
> leads to inconsistency in el2 translation tables. ie; the pte entry is
> cleared in the cached memory but not in the RAM, so the entry may still be
> valid in EL2 translation tables.

I'm not sure which code you're talking about.  Perhaps try sending a
patch?

> You should also clear pte itself.
> 

If you're talking about unmap_stage2_ptes(), then I must be missing
something, because I don't see why setting the pointer to 0 should
matter, and what you say about cached memory and RAM doesn't sound
correct, as all virtualization-capable ARM CPUs have coherent page table
walks.

Thanks,
-Christoffer

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-11-29 18:05 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-11-27 21:10 unmap_ptes is not complete Raz
2017-11-29 18:08 ` Christoffer Dall

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).