[lkml]   [2008]   [Oct]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
Subject[patch 26/27] PCI hotplug: cpqphp: fix kernel NULL pointer dereference
2.6.27-stable review patch.  If anyone has any objections, please let us 

From: Kenji Kaneshige <>
commit d2174c3c07adad88dd9ba37a731e0b00b746822a upstream

The following patch fixes the regression in 2.6.27 that causes kernel
NULL pointer dereference at cpqphp driver probe time. This patch should
be backported to the .27 stable series.

Seems to have been introduced by

The root cause of this problem seems that cpqphp driver calls
pci_hp_register() wrongly. In current implementation, cpqphp driver
passes 'ctrl->pci_dev->subordinate' as a second parameter for
pci_hp_register(). But because hotplug slots and it's hotplug controller
(exists as a pci funcion) are on the same bus, it should be
'ctrl->pci_dev->bus' instead.

Tested-by: Ingo Molnar <>
Signed-off-by: Kenji Kaneshige <>
Signed-off-by: Jesse Barnes <>
Signed-off-by: Greg Kroah-Hartman <>

drivers/pci/hotplug/cpqphp_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/pci/hotplug/cpqphp_core.c
+++ b/drivers/pci/hotplug/cpqphp_core.c
@@ -435,7 +435,7 @@ static int ctrl_slot_setup(struct contro
slot->number, ctrl->slot_device_offset,
result = pci_hp_register(hotplug_slot,
- ctrl->pci_dev->subordinate,
+ ctrl->pci_dev->bus,
if (result) {
err("pci_hp_register failed with error %d\n", result);

 \ /
  Last update: 2008-10-24 07:09    [from the cache]
©2003-2014 Jasper Spaans. hosted at Digital Ocean