Skip to content

Commit

Permalink
MIPS: Loongson: CS5536: Fix ISA support
Browse files Browse the repository at this point in the history
The function _wrmsr() called by divil_lbar_disable()/enable() should be
called with the offset as the argument.

Signed-off-by: Wu Zhangjin <[email protected]>
Cc: [email protected]
Cc: Zhang Le <[email protected]>
Patchwork: http://patchwork.linux-mips.org/patch/1252/
Signed-off-by: Ralf Baechle <[email protected]>
  • Loading branch information
lzufalcon authored and ralfbaechle committed Jul 5, 2010
1 parent aa5f858 commit 4085467
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arch/mips/loongson/common/cs5536/cs5536_isa.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ static void divil_lbar_enable(void)
for (offset = DIVIL_LBAR_SMB; offset <= DIVIL_LBAR_PMS; offset++) {
_rdmsr(DIVIL_MSR_REG(offset), &hi, &lo);
hi |= 0x01;
_wrmsr(DIVIL_MSR_REG(DIVIL_LBAR_SMB), hi, lo);
_wrmsr(DIVIL_MSR_REG(offset), hi, lo);
}
}

Expand All @@ -76,7 +76,7 @@ static void divil_lbar_disable(void)
for (offset = DIVIL_LBAR_SMB; offset <= DIVIL_LBAR_PMS; offset++) {
_rdmsr(DIVIL_MSR_REG(offset), &hi, &lo);
hi &= ~0x01;
_wrmsr(DIVIL_MSR_REG(DIVIL_LBAR_SMB), hi, lo);
_wrmsr(DIVIL_MSR_REG(offset), hi, lo);
}
}

Expand Down

0 comments on commit 4085467

Please sign in to comment.