From 6897454200570aa9fab28f600a84e89ceb1d420d Mon Sep 17 00:00:00 2001 From: Kristen Accardi Date: Wed, 28 Jun 2006 03:09:54 -0400 Subject: [PATCH] --- yaml --- r: 31443 b: refs/heads/master c: 95b38b3f453c16de0f8cddcde3e71050bbfb37b9 h: refs/heads/master i: 31441: 785849bc707dbc1e92f9dd9ae0eca9d588a95872 31439: ae7de97037b98053adbd7cfbcb440895f9608ef6 v: v3 --- [refs] | 2 +- trunk/drivers/pci/hotplug/acpiphp_glue.c | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 1920b27cd019..1dc5616bca64 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 2b85e1307fe3a84eca2e1a21c6c857359908dab4 +refs/heads/master: 95b38b3f453c16de0f8cddcde3e71050bbfb37b9 diff --git a/trunk/drivers/pci/hotplug/acpiphp_glue.c b/trunk/drivers/pci/hotplug/acpiphp_glue.c index b3899cfcab6b..ef95d12fb32c 100644 --- a/trunk/drivers/pci/hotplug/acpiphp_glue.c +++ b/trunk/drivers/pci/hotplug/acpiphp_glue.c @@ -219,8 +219,13 @@ register_slot(acpi_handle handle, u32 lvl, void *context, void **rv) newfunc->flags |= FUNC_HAS_DCK; status = acpi_evaluate_integer(handle, "_SUN", NULL, &sun); - if (ACPI_FAILURE(status)) - sun = -1; + if (ACPI_FAILURE(status)) { + /* + * use the count of the number of slots we've found + * for the number of the slot + */ + sun = bridge->nr_slots+1; + } /* search for objects that share the same slot */ for (slot = bridge->slots; slot; slot = slot->next)