From 78d65a24de3cb781dae0f604680d48e1a295a641 Mon Sep 17 00:00:00 2001 From: Matthew Wilcox Date: Wed, 28 Jan 2004 22:26:41 -0800 Subject: [PATCH] [PATCH] PCI Hotplug: Better reporting of PCI frequency / bus mode problems for acpi driver When plugging a 33MHz card into a bus that's running at 66MHz, I'd like to see a better error message than: acpiphp_glue: notify_handler: unknown event type 0x5 for \_SB_.SBA0.PCI4.S2F0 The following patch would give us: Device \_SB_.SBA0.PCI4.S2F0 cannot be configured due to a frequency mismatch which I think is clearer. --- drivers/pci/hotplug/acpiphp_glue.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c index 9f5591f21bea0..bbf25f2b84ec5 100644 --- a/drivers/pci/hotplug/acpiphp_glue.c +++ b/drivers/pci/hotplug/acpiphp_glue.c @@ -974,6 +974,21 @@ static void handle_hotplug_event_bridge (acpi_handle handle, u32 type, void *con dbg("%s: Device eject notify on %s\n", __FUNCTION__, objname); break; + case ACPI_NOTIFY_FREQUENCY_MISMATCH: + printk(KERN_ERR "Device %s cannot be configured due" + " to a frequency mismatch\n", objname); + break; + + case ACPI_NOTIFY_BUS_MODE_MISMATCH: + printk(KERN_ERR "Device %s cannot be configured due" + " to a bus mode mismatch\n", objname); + break; + + case ACPI_NOTIFY_POWER_FAULT: + printk(KERN_ERR "Device %s has suffered a power fault\n", + objname); + break; + default: warn("notify_handler: unknown event type 0x%x for %s\n", type, objname); break; -- 2.53.0