From: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
To: Hillf Danton <hillf.zj@alibaba-inc.com>
Cc: 'linux-kernel' <linux-kernel@vger.kernel.org>, linux-mm@kvack.org
Subject: Re: [RFC PATCH 2/4] mm: Change the interface for __tlb_remove_page
Date: Tue, 31 May 2016 12:20:49 +0530 [thread overview]
Message-ID: <87h9de201i.fsf@skywalker.in.ibm.com> (raw)
In-Reply-To: <002b01d1baef$e6246530$b26d2f90$@alibaba-inc.com>
Hillf Danton <hillf.zj@alibaba-inc.com> writes:
>> >> @@ -1202,7 +1205,12 @@ again:
>> >> if (force_flush) {
>> >> force_flush = 0;
>> >> tlb_flush_mmu_free(tlb);
>> >> -
>> >> + if (pending_page) {
>> >> + /* remove the page with new size */
>> >> + __tlb_adjust_range(tlb, tlb->addr);
>> >
>> > Would you please specify why tlb->addr is used here?
>> >
>>
>> That is needed because tlb_flush_mmu_tlbonly() does a __tlb_reset_range().
>>
> If ->addr is updated in resetting, then it is a noop here to deliver tlb->addr to
> __tlb_adjust_range().
> On the other hand, if ->addr is not updated in resetting, then it is also a noop here.
>
> Do you want to update ->addr here?
>
I don't get that question. We wanted to track the alst adjusted addr in
tlb->addr because when we do a tlb_flush_mmu_tlbonly() we does a
__tlb_reset_range(), which clears tlb->start and tlb->end. Now we need
to update the range again with the last adjusted addr before we can call
__tlb_remove_page(). Look for VM_BUG_ON(!tlb->end); in
__tlb_remove_page().
-aneesh
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2016-05-31 6:51 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <001701d1ba44$b9c0d560$2d428020$@alibaba-inc.com>
2016-05-30 8:07 ` Hillf Danton
2016-05-30 15:34 ` Aneesh Kumar K.V
2016-05-31 3:52 ` Hillf Danton
2016-05-31 6:50 ` Aneesh Kumar K.V [this message]
2016-05-31 7:26 ` Hillf Danton
2016-05-30 5:44 [RFC PATCH 1/4] mm/hugetlb: Simplify hugetlb unmap Aneesh Kumar K.V
2016-05-30 5:44 ` [RFC PATCH 2/4] mm: Change the interface for __tlb_remove_page Aneesh Kumar K.V
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87h9de201i.fsf@skywalker.in.ibm.com \
--to=aneesh.kumar@linux.vnet.ibm.com \
--cc=hillf.zj@alibaba-inc.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox