Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 40560
b: refs/heads/master
c: 70e46f4
h: refs/heads/master
v: v3
  • Loading branch information
Ralf Baechle committed Oct 31, 2006
1 parent c798b67 commit cf4b06f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 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: e79f55a8c7aaae5a33e8c2b29682ec8e603b5434
refs/heads/master: 70e46f48cb5933119712ee27945309a4bfc98282
2 changes: 2 additions & 0 deletions trunk/arch/mips/kernel/smp-mt.c
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,8 @@ static void __init smp_copy_vpe_config(void)

/* Propagate Config7 */
write_vpe_c0_config7(read_c0_config7());

write_vpe_c0_count(read_c0_count());
}

static unsigned int __init smp_vpe_init(unsigned int tc, unsigned int mvpconf0,
Expand Down
5 changes: 3 additions & 2 deletions trunk/arch/mips/mips-boards/generic/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,7 @@ static unsigned int __init estimate_cpu_frequency(void)
#endif
#if defined(CONFIG_MIPS_ATLAS) || defined(CONFIG_MIPS_MALTA)
unsigned long flags;
unsigned int start;

local_irq_save(flags);

Expand All @@ -217,13 +218,13 @@ static unsigned int __init estimate_cpu_frequency(void)
while (!(CMOS_READ(RTC_REG_A) & RTC_UIP));

/* Start r4k counter. */
write_c0_count(0);
start = read_c0_count();

/* Read counter exactly on falling edge of update flag */
while (CMOS_READ(RTC_REG_A) & RTC_UIP);
while (!(CMOS_READ(RTC_REG_A) & RTC_UIP));

count = read_c0_count();
count = read_c0_count() - start;

/* restore interrupts */
local_irq_restore(flags);
Expand Down
2 changes: 2 additions & 0 deletions trunk/include/asm-mips/mipsmtregs.h
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,8 @@ do { \
#define write_vpe_c0_vpecontrol(val) mttc0(1, 1, val)
#define read_vpe_c0_vpeconf0() mftc0(1, 2)
#define write_vpe_c0_vpeconf0(val) mttc0(1, 2, val)
#define read_vpe_c0_count() mftc0(9, 0)
#define write_vpe_c0_count(val) mttc0(9, 0, val)
#define read_vpe_c0_status() mftc0(12, 0)
#define write_vpe_c0_status(val) mttc0(12, 0, val)
#define read_vpe_c0_cause() mftc0(13, 0)
Expand Down

0 comments on commit cf4b06f

Please sign in to comment.