[PATCH 1/1] powerpc: mm: Check if serialize_against_pte_lookup() really needs to run
Leonardo Bras
leonardo at linux.ibm.com
Wed Sep 18 07:21:22 AEST 2019
Hello Aneesh, thanks for the feedback!
On Tue, 2019-09-17 at 08:26 +0530, Aneesh Kumar K.V wrote:
> We could possibly avoid that serialize for a full task exit unmap. ie,
> when tlb->fullmm == 1 . But that won't help the Qemu case because it
> does an umap of the guest ram range for which tlb->fullmm != 1.
Yes, in qemu we can hot-add memory to guests using memory allocated by
qemu using mmap(). If we want/need to free this memory to other
processes (or guests), we remove it from this guest and do a common
munmap(). This happens without exiting qemu, or pausing the guest.
> That is not correct. We need to keep the count updated across the
> local_irq_disable()/local_irq_enable().
So, by that you mean incrementing the counter before
local_irq_{disable,save} and decrementing only after
local_irq_{enable,restore}?
> That is we mostly should have a variant like
> start_lockless_pgtbl_walk()/end_lockless_pgtbl_walk().
And with that, you mean replacing the current local_irq_{disable,save}
with a start_lockless_pgtbl_walk() (that contains increment + irq
disable)? (and doing similarly with local_irq_{enable,restore} and
end_lockless_pgtbl_walk())
> Also there is hash_page_mm which we need to make sure we are protected
> against w.r.t collapse pmd.
I did not get what I need to do here.
Is it a new thing to protect?
If so, I need to better understand how to protect it.
If not, I would like to understand how it's protected by current
behavior.
> Move that to ppc64 specific mm_context_t.
Ok, fixed! I will send that on v2.
Best regards,
Leonardo Bras
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20190917/2ba012cd/attachment-0001.sig>
More information about the Linuxppc-dev
mailing list