Skip to contentSkip to conversation

remove frv usage of flush_tlb_pgtables()

PATCH/RFC Benjamin Herrenschmidt 2 participants 3 messages Jul 26, 2007 – Jul 27, 2007 Memory management

lore
Share & tools
lore
#0 lore raw

frv is the last user in the tree of that dubious hook, and it's my understanding that it's not even needed. It's only called by memory.c free_pgd_range() which is always called within an mmu_gather, and tlb_flush() on frv will do a flush_tlb_mm(), which from my reading of the code, seems to do what flush_tlb_ptables() does, which is to clear the cached PGE.

---

Hi David ! I want to get rid of flush_tlb_pgtables() as part of my work on the mmu_gather and frv seems to be the only one to still use it. I don't think it needs it though, can you double check ?

Thanks !
Ben.

include/asm-frv/tlbflush.h +1 -2
Index: linux-work/include/asm-frv/tlbflush.h
===================================================================
@@ -57,8 +57,7 @@ do {								\
 #define __flush_tlb_global()			flush_tlb_all()
 #define flush_tlb()				flush_tlb_all()
 #define flush_tlb_kernel_range(start, end)	flush_tlb_all()
-#define flush_tlb_pgtables(mm,start,end) \
-	asm volatile("movgs %0,scr0 ! movgs %0,scr1" :: "r"(ULONG_MAX) : "memory");
+#define flush_tlb_pgtables(mm,start,end)	do { } while(0)
 
 #else
 

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>

Acked-by
#1 lore raw
Quoted 6 lines · Benjamin Herrenschmidt

frv is the last user in the tree of that dubious hook, and it's my understanding that it's not even needed. It's only called by memory.c free_pgd_range() which is always called within an mmu_gather, and tlb_flush() on frv will do a flush_tlb_mm(), which from my reading of the code, seems to do what flush_tlb_ptables() does, which is to clear the cached PGE.

Yeah... I hadn't got around to killing myself yet.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>

#2 lore raw
Quoted 9 lines · David Howells
Quoted 2 lines

frv is the last user in the tree of that dubious hook, and it's my understanding that it's not even needed. It's only called by

memory.c

Quoted 4 lines

free_pgd_range() which is always called within an mmu_gather, and tlb_flush() on frv will do a flush_tlb_mm(), which from my reading of the code, seems to do what flush_tlb_ptables() does, which is to clear the cached PGE.

Yeah... I hadn't got around to killing myself yet.

Ahem... hopefully you won't get around to it any time soon :-)

Cheers,
Ben.

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to [email protected]. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>