Skip to content

Commit

Permalink
powerpc/fsl-booke: Remove num_tlbcam_entries
Browse files Browse the repository at this point in the history
This is a global variable defined in fsl_booke_mmu.c with a value that gets
initialized in assembly code in head_fsl_booke.S.

It's never used.

If some code ever does want to know the number of entries in TLB1, then
"numcams = mfspr(SPRN_TLB1CFG) & 0xfff", is a whole lot simpler than a
global initialized during kernel boot from assembly.

Signed-off-by: Trent Piepho <tpiepho@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
  • Loading branch information
Trent Piepho authored and Kumar Gala committed Jan 7, 2009
1 parent 19f5465 commit 6fd8be4
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 7 deletions.
4 changes: 0 additions & 4 deletions arch/powerpc/kernel/head_fsl_booke.S
Original file line number Diff line number Diff line change
Expand Up @@ -389,10 +389,6 @@ skpinv: addi r6,r6,1 /* Increment */
#endif
#endif

mfspr r3,SPRN_TLB1CFG
andi. r3,r3,0xfff
lis r4,num_tlbcam_entries@ha
stw r3,num_tlbcam_entries@l(r4)
/*
* Decide what sort of machine this is and initialize the MMU.
*/
Expand Down
1 change: 0 additions & 1 deletion arch/powerpc/mm/fsl_booke_mmu.c
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@

extern void loadcam_entry(unsigned int index);
unsigned int tlbcam_index;
unsigned int num_tlbcam_entries;
static unsigned long __cam0, __cam1, __cam2;

#define NUM_TLBCAMS (16)
Expand Down
2 changes: 0 additions & 2 deletions arch/powerpc/mm/mmu_decl.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,6 @@ extern unsigned int rtas_data, rtas_size;
struct hash_pte;
extern struct hash_pte *Hash, *Hash_end;
extern unsigned long Hash_size, Hash_mask;

extern unsigned int num_tlbcam_entries;
#endif

extern unsigned long ioremap_bot;
Expand Down

0 comments on commit 6fd8be4

Please sign in to comment.