lkml.org 
[lkml]   [2008]   [Oct]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [BUG][PATCH] cpqphp: fix kernel NULL pointer dereference
* Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>:
>
> 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.
>
> Cc: <stable@kernel.org>

Acked-by: Alex Chiang <achiang@hp.com>

> Tested-by: Ingo Molnar <mingo@elte.hu>
> Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
>
> ---
> drivers/pci/hotplug/cpqphp_core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> Index: linux-2.6-tip/drivers/pci/hotplug/cpqphp_core.c
> ===================================================================
> --- linux-2.6-tip.orig/drivers/pci/hotplug/cpqphp_core.c
> +++ linux-2.6-tip/drivers/pci/hotplug/cpqphp_core.c
> @@ -435,7 +435,7 @@ static int ctrl_slot_setup(struct contro
> slot->number, ctrl->slot_device_offset,
> slot_number);
> result = pci_hp_register(hotplug_slot,
> - ctrl->pci_dev->subordinate,
> + ctrl->pci_dev->bus,
> slot->device);
> if (result) {
> err("pci_hp_register failed with error %d\n", result);
>


\
 
 \ /
  Last update: 2008-10-17 02:37    [W:0.053 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site