diff options
Diffstat (limited to 'arch/x86/kernel/early-quirks.c')
-rw-r--r-- | arch/x86/kernel/early-quirks.c | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/arch/x86/kernel/early-quirks.c b/arch/x86/kernel/early-quirks.c index 24bb5faf5efa..733c4f8d42ea 100644 --- a/arch/x86/kernel/early-quirks.c +++ b/arch/x86/kernel/early-quirks.c | |||
@@ -95,6 +95,52 @@ static void __init nvidia_bugs(int num, int slot, int func) | |||
95 | 95 | ||
96 | } | 96 | } |
97 | 97 | ||
98 | static u32 ati_ixp4x0_rev(int num, int slot, int func) | ||
99 | { | ||
100 | u32 d; | ||
101 | u8 b; | ||
102 | |||
103 | b = read_pci_config_byte(num, slot, func, 0xac); | ||
104 | b &= ~(1<<5); | ||
105 | write_pci_config_byte(num, slot, func, 0xac, b); | ||
106 | |||
107 | d = read_pci_config(num, slot, func, 0x70); | ||
108 | d |= 1<<8; | ||
109 | write_pci_config(num, slot, func, 0x70, d); | ||
110 | |||
111 | d = read_pci_config(num, slot, func, 0x8); | ||
112 | d &= 0xff; | ||
113 | return d; | ||
114 | } | ||
115 | |||
116 | static void __init ati_bugs(int num, int slot, int func) | ||
117 | { | ||
118 | #if defined(CONFIG_ACPI) && defined (CONFIG_X86_IO_APIC) | ||
119 | u32 d; | ||
120 | u8 b; | ||
121 | |||
122 | if (acpi_use_timer_override) | ||
123 | return; | ||
124 | |||
125 | d = ati_ixp4x0_rev(num, slot, func); | ||
126 | if (d < 0x82) | ||
127 | acpi_skip_timer_override = 1; | ||
128 | else { | ||
129 | /* check for IRQ0 interrupt swap */ | ||
130 | outb(0x72, 0xcd6); b = inb(0xcd7); | ||
131 | if (!(b & 0x2)) | ||
132 | acpi_skip_timer_override = 1; | ||
133 | } | ||
134 | |||
135 | if (acpi_skip_timer_override) { | ||
136 | printk(KERN_INFO "SB4X0 revision 0x%x\n", d); | ||
137 | printk(KERN_INFO "Ignoring ACPI timer override.\n"); | ||
138 | printk(KERN_INFO "If you got timer trouble " | ||
139 | "try acpi_use_timer_override\n"); | ||
140 | } | ||
141 | #endif | ||
142 | } | ||
143 | |||
98 | #ifdef CONFIG_DMAR | 144 | #ifdef CONFIG_DMAR |
99 | static void __init intel_g33_dmar(int num, int slot, int func) | 145 | static void __init intel_g33_dmar(int num, int slot, int func) |
100 | { | 146 | { |
@@ -128,6 +174,8 @@ static struct chipset early_qrk[] __initdata = { | |||
128 | PCI_CLASS_BRIDGE_PCI, PCI_ANY_ID, QFLAG_APPLY_ONCE, via_bugs }, | 174 | PCI_CLASS_BRIDGE_PCI, PCI_ANY_ID, QFLAG_APPLY_ONCE, via_bugs }, |
129 | { PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_K8_NB, | 175 | { PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_K8_NB, |
130 | PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, fix_hypertransport_config }, | 176 | PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, fix_hypertransport_config }, |
177 | { PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_IXP400_SMBUS, | ||
178 | PCI_CLASS_SERIAL_SMBUS, PCI_ANY_ID, 0, ati_bugs }, | ||
131 | #ifdef CONFIG_DMAR | 179 | #ifdef CONFIG_DMAR |
132 | { PCI_VENDOR_ID_INTEL, 0x29c0, | 180 | { PCI_VENDOR_ID_INTEL, 0x29c0, |
133 | PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, intel_g33_dmar }, | 181 | PCI_CLASS_BRIDGE_HOST, PCI_ANY_ID, 0, intel_g33_dmar }, |