[Top] [All Lists]

[PATCH] MIPS: Keep TLB cache hot while flushing

To: David Daney <>
Subject: [PATCH] MIPS: Keep TLB cache hot while flushing
From: Hillf Danton <>
Date: Fri, 28 Oct 2011 22:15:58 +0800
Cc: Ralf Baechle <>,
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=gamma; h=mime-version:date:message-id:subject:from:to:cc:content-type; bh=LBf7UXzJ7pBejJekoEgK3LG20/CVh9pG47iG2thq12c=; b=Sxwq/ysc0xnlu6j1apb5c5ywpVontfgtgDovujhu/4UtqwuKTt63rVCT0iiVQJETBV THETAIRDcz8KZzXhAz8qeDBBuktTifB6PVkhppAUJomd42qpcRLogSY7uK3gZmecxARu 3hi0P7sSNe+ISzIS/OVzRfl1hN2RL3sBJcUss=
Hi David,

If we only flush the TLB of the given huge page, the TLB cache remains hot for
the relevant mm as it is, and less will be refilled after flush, huge or not.

As always all comments and ideas welcome.


Signed-off-by: Hillf Danton <>

--- a/arch/mips/include/asm/hugetlb.h   Sat May 14 15:21:01 2011
+++ b/arch/mips/include/asm/hugetlb.h   Fri Oct 28 22:08:05 2011
@@ -70,7 +70,7 @@ static inline pte_t huge_ptep_get_and_cl
 static inline void huge_ptep_clear_flush(struct vm_area_struct *vma,
                                         unsigned long addr, pte_t *ptep)
-       flush_tlb_mm(vma->vm_mm);
+       flush_tlb_page(vma, addr & huge_page_mask(hstate_vma(vma)));

 static inline int huge_pte_none(pte_t pte)

<Prev in Thread] Current Thread [Next in Thread>