Skip to contentSkip to conversation

pnpbios: bail out on strange errors

PATCH RESEND New Alan Cox 1 participant 1 message Jan 20, 2015 Pnp support

lore
Share & tools
lore

Alan Cox

author
#0 lore raw

PATCH RESEND 1/1 pnpbios: bail out on strange errors

A small number of systems respond to PnP dock queries with bogus values. This causes us to keep logging an error every 2 seconds. Instead of trying again just assume the BIOS is crapware and doesn't actually have dock functionality.

---
 drivers/pnp/pnpbios/core.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/pnp/pnpbios/core.c +2 -1
index 074569e..facd43b 100644
@@ -181,7 +181,8 @@ static int pnp_dock_thread(void *unused)
 			break;
 		default:
 			pnpbios_print_status("pnp_dock_thread", status);
-			continue;
+			printk(KERN_WARNING "PnPBIOS: disabling dock monitoring.\n");
+			complete_and_exit(&unload_sem, 0);
 		}
 		if (d != docked) {
 			if (pnp_dock_event(d, &now) == 0) {