Commit 689eba77 authored by Rafał Bilski's avatar Rafał Bilski Committed by Dave Jones

[CPUFREQ] Longhaul - Proper register access

In previous commit I used u32 for u16 register.
This code will work only when ACPI block address is set.
For now it is only for VT8235 and VT8237.
Signed-off-by: default avatarRafal Bilski <rafalbilski@interia.pl>
Signed-off-by: default avatarDave Jones <davej@redhat.com>
parent e8666b27
...@@ -247,7 +247,7 @@ static void longhaul_setstate(unsigned int table_index) ...@@ -247,7 +247,7 @@ static void longhaul_setstate(unsigned int table_index)
struct cpufreq_freqs freqs; struct cpufreq_freqs freqs;
unsigned long flags; unsigned long flags;
unsigned int pic1_mask, pic2_mask; unsigned int pic1_mask, pic2_mask;
u32 bm_status = 0; u16 bm_status = 0;
u32 bm_timeout = 1000; u32 bm_timeout = 1000;
unsigned int dir = 0; unsigned int dir = 0;
...@@ -281,14 +281,14 @@ static void longhaul_setstate(unsigned int table_index) ...@@ -281,14 +281,14 @@ static void longhaul_setstate(unsigned int table_index)
outb(0xFE,0x21); /* TMR0 only */ outb(0xFE,0x21); /* TMR0 only */
/* Wait while PCI bus is busy. */ /* Wait while PCI bus is busy. */
if (longhaul_flags & USE_NORTHBRIDGE if (acpi_regs_addr && (longhaul_flags & USE_NORTHBRIDGE
|| ((pr != NULL) && pr->flags.bm_control)) { || ((pr != NULL) && pr->flags.bm_control))) {
bm_status = inl(acpi_regs_addr); bm_status = inw(acpi_regs_addr);
bm_status &= 1 << 4; bm_status &= 1 << 4;
while (bm_status && bm_timeout) { while (bm_status && bm_timeout) {
outl(1 << 4, acpi_regs_addr); outw(1 << 4, acpi_regs_addr);
bm_timeout--; bm_timeout--;
bm_status = inl(acpi_regs_addr); bm_status = inw(acpi_regs_addr);
bm_status &= 1 << 4; bm_status &= 1 << 4;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment