Safe-mode on amd64 broken

Alexander Motin mav at
Thu Sep 30 05:23:53 UTC 2010

David Naylor wrote:
> On Wednesday 29 September 2010 18:25:13 Alexander Motin wrote:
>> David Naylor wrote:
>>> On Wednesday 29 September 2010 16:19:08 Andriy Gapon wrote:
>>>> What do you try to actually achieve?
>>> I was trying to boot a system and it was panicking due to stray
>>> interrupts. It turned out to be caused by HPET.  I found
>>> `hint.hpet.0.clock=0' which fixed the problem.
>>> This means HPET does not work on any of my machines.  The other one's
>>> symptoms are hda losing interrupts after a period of up-time.
>> What chipset do you use? Nvidia MCP5x? Could you send me your verbose
>> dmesg?
> Yes, the one is a MCP51, the other is a ICH8M.  
> The desktop is a Gigabyte N650SLI-DS4L.  Its symptom is hda losing interrupts 
> after a period of time.  

There are too many reports about different lost interrupts problems on
different controllers of MCP5x. I don't know the reason. Attached patch
should disable using regular HPET interrupts on NVidia chipsets. I hope
it will work as workaround. May be it is too aggressive, but better to
be safe then sorry. I assume that legacy_route mode may still work fine
there. It would be nice to test it.

> The laptop is a Acer 2920.  Its symptom for a GENERIC is a panic saying stray 
> interrupt (irq7), with a custom kernel booting stalls.  

This is strange, as my Acer with the same ICH8M works fine in all
possible modes. Also IMHO stray interrupts are not a reason to panic.
Could you show what it looks like?

Alexander Motin
-------------- next part --------------
--- acpi_hpet.c.prev	2010-09-13 10:25:36.000000000 +0300
+++ acpi_hpet.c	2010-09-30 08:09:34.000000000 +0300
@@ -58,6 +58,7 @@ __FBSDID("$FreeBSD: head/sys/dev/acpica/
 #define HPET_VENDID_AMD		0x4353
 #define HPET_VENDID_INTEL	0x8086
+#define HPET_VENDID_NVIDIA	0x10de
 ACPI_SERIAL_DECL(hpet, "ACPI HPET support");
@@ -492,6 +493,12 @@ hpet_attach(device_t dev)
 	if (vendor == HPET_VENDID_AMD)
 		sc->allowed_irqs = 0x00000000;
+	 * NVidia MCP5x chipsets have number of unexplained interrupt
+	 * problems. For some reason, using HPET interrupts breaks HDA sound.
+	 */
+	if (vendor == HPET_VENDID_NVIDIA && rev <= 0x01)
+		sc->allowed_irqs = 0x00000000;
+	/*
 	 * Neither QEMU nor VirtualBox report supported IRQs correctly.
 	 * The only way to use HPET there is to specify IRQs manually
 	 * and/or use legacy_route. Legacy_route mode work on both.

More information about the freebsd-current mailing list