Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 182071
b: refs/heads/master
c: 2a88098
h: refs/heads/master
i:
  182069: 289a1c6
  182067: 55ba490
  182063: 2bc59f9
v: v3
  • Loading branch information
David Daney authored and Ralf Baechle committed Feb 27, 2010
1 parent a60ea4c commit 2ba4cf4
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 32 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f868ba29723be46e0981226d7455090d515b08ef
refs/heads/master: 2a880986d899f556f5a327bc77cc8760d5bb9c64
31 changes: 0 additions & 31 deletions trunk/arch/mips/mm/tlb-r4k.c
Original file line number Diff line number Diff line change
Expand Up @@ -447,34 +447,6 @@ __init int add_temporary_entry(unsigned long entrylo0, unsigned long entrylo1,
return ret;
}

static void __cpuinit probe_tlb(unsigned long config)
{
struct cpuinfo_mips *c = &current_cpu_data;
unsigned int reg;

/*
* If this isn't a MIPS32 / MIPS64 compliant CPU. Config 1 register
* is not supported, we assume R4k style. Cpu probing already figured
* out the number of tlb entries.
*/
if ((c->processor_id & 0xff0000) == PRID_COMP_LEGACY)
return;
#ifdef CONFIG_MIPS_MT_SMTC
/*
* If TLB is shared in SMTC system, total size already
* has been calculated and written into cpu_data tlbsize
*/
if((smtc_status & SMTC_TLB_SHARED) == SMTC_TLB_SHARED)
return;
#endif /* CONFIG_MIPS_MT_SMTC */

reg = read_c0_config1();
if (!((config >> 7) & 3))
panic("No TLB present");

c->tlbsize = ((reg >> 25) & 0x3f) + 1;
}

static int __cpuinitdata ntlb;
static int __init set_ntlb(char *str)
{
Expand All @@ -486,16 +458,13 @@ __setup("ntlb=", set_ntlb);

void __cpuinit tlb_init(void)
{
unsigned int config = read_c0_config();

/*
* You should never change this register:
* - On R4600 1.7 the tlbp never hits for pages smaller than
* the value in the c0_pagemask register.
* - The entire mm handling assumes the c0_pagemask register to
* be set to fixed-size pages.
*/
probe_tlb(config);
write_c0_pagemask(PM_DEFAULT_MASK);
write_c0_wired(0);
if (current_cpu_type() == CPU_R10000 ||
Expand Down

0 comments on commit 2ba4cf4

Please sign in to comment.