aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kernel/quirks.c29
1 files changed, 26 insertions, 3 deletions
diff --git a/arch/x86/kernel/quirks.c b/arch/x86/kernel/quirks.c
index 5fe6bd5cc4c7..ddbf34d16a01 100644
--- a/arch/x86/kernel/quirks.c
+++ b/arch/x86/kernel/quirks.c
@@ -175,6 +175,12 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_ICH9_7,
175 175
176static struct pci_dev *cached_dev; 176static struct pci_dev *cached_dev;
177 177
178static void hpet_print_force_info(void)
179{
180 printk(KERN_INFO "HPET not enabled in BIOS. "
181 "You might try hpet=force boot option\n");
182}
183
178static void old_ich_force_hpet_resume(void) 184static void old_ich_force_hpet_resume(void)
179{ 185{
180 u32 val; 186 u32 val;
@@ -254,6 +260,8 @@ static void old_ich_force_enable_hpet_user(struct pci_dev *dev)
254{ 260{
255 if (hpet_force_user) 261 if (hpet_force_user)
256 old_ich_force_enable_hpet(dev); 262 old_ich_force_enable_hpet(dev);
263 else
264 hpet_print_force_info();
257} 265}
258 266
259DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82801CA_0, 267DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82801CA_0,
@@ -291,8 +299,13 @@ static void vt8237_force_enable_hpet(struct pci_dev *dev)
291{ 299{
292 u32 uninitialized_var(val); 300 u32 uninitialized_var(val);
293 301
294 if (!hpet_force_user || hpet_address || force_hpet_address) 302 if (hpet_address || force_hpet_address)
303 return;
304
305 if (!hpet_force_user) {
306 hpet_print_force_info();
295 return; 307 return;
308 }
296 309
297 pci_read_config_dword(dev, 0x68, &val); 310 pci_read_config_dword(dev, 0x68, &val);
298 /* 311 /*
@@ -341,8 +354,13 @@ static void ati_force_enable_hpet(struct pci_dev *dev)
341{ 354{
342 u32 uninitialized_var(val); 355 u32 uninitialized_var(val);
343 356
344 if (!hpet_force_user || hpet_address || force_hpet_address) 357 if (hpet_address || force_hpet_address)
358 return;
359
360 if (!hpet_force_user) {
361 hpet_print_force_info();
345 return; 362 return;
363 }
346 364
347 pci_write_config_dword(dev, 0x14, 0xfed00000); 365 pci_write_config_dword(dev, 0x14, 0xfed00000);
348 pci_read_config_dword(dev, 0x14, &val); 366 pci_read_config_dword(dev, 0x14, &val);
@@ -369,8 +387,13 @@ static void nvidia_force_enable_hpet(struct pci_dev *dev)
369{ 387{
370 u32 uninitialized_var(val); 388 u32 uninitialized_var(val);
371 389
372 if (!hpet_force_user || hpet_address || force_hpet_address) 390 if (hpet_address || force_hpet_address)
391 return;
392
393 if (!hpet_force_user) {
394 hpet_print_force_info();
373 return; 395 return;
396 }
374 397
375 pci_write_config_dword(dev, 0x44, 0xfed00001); 398 pci_write_config_dword(dev, 0x44, 0xfed00001);
376 pci_read_config_dword(dev, 0x44, &val); 399 pci_read_config_dword(dev, 0x44, &val);