aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug
diff options
context:
space:
mode:
authorKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>2006-02-21 18:45:38 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2006-03-23 17:35:12 -0500
commit09e1218eccf58f6174fa68360a7c8dcfe457fe9b (patch)
tree6651cb6ad8d8e47747e8f4f5e33ad77c5bfe631f /drivers/pci/hotplug
parentbbe8f9a3e76c551973ee739de10b26581d78b45f (diff)
[PATCH] shpchp: Remove unused pci_bus member from controller structure
This patch removes unused 'pci_bus' member from controller structure. This patch have no functional change. Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/hotplug')
-rw-r--r--drivers/pci/hotplug/shpchp.h1
-rw-r--r--drivers/pci/hotplug/shpchp_core.c13
2 files changed, 1 insertions, 13 deletions
diff --git a/drivers/pci/hotplug/shpchp.h b/drivers/pci/hotplug/shpchp.h
index dc12b0dbb9b2..ce792b3cf9de 100644
--- a/drivers/pci/hotplug/shpchp.h
+++ b/drivers/pci/hotplug/shpchp.h
@@ -85,7 +85,6 @@ struct controller {
85 int num_slots; /* Number of slots on ctlr */ 85 int num_slots; /* Number of slots on ctlr */
86 int slot_num_inc; /* 1 or -1 */ 86 int slot_num_inc; /* 1 or -1 */
87 struct pci_dev *pci_dev; 87 struct pci_dev *pci_dev;
88 struct pci_bus *pci_bus;
89 struct event_info event_queue[10]; 88 struct event_info event_queue[10];
90 struct list_head slot_list; 89 struct list_head slot_list;
91 struct hpc_ops *hpc_ops; 90 struct hpc_ops *hpc_ops;
diff --git a/drivers/pci/hotplug/shpchp_core.c b/drivers/pci/hotplug/shpchp_core.c
index cb4ac43ea95c..8b21fc206712 100644
--- a/drivers/pci/hotplug/shpchp_core.c
+++ b/drivers/pci/hotplug/shpchp_core.c
@@ -386,14 +386,6 @@ static int shpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
386 386
387 pci_set_drvdata(pdev, ctrl); 387 pci_set_drvdata(pdev, ctrl);
388 388
389 ctrl->pci_bus = kmalloc(sizeof(*ctrl->pci_bus), GFP_KERNEL);
390 if (!ctrl->pci_bus) {
391 err("out of memory\n");
392 rc = -ENOMEM;
393 goto err_out_unmap_mmio_region;
394 }
395
396 memcpy (ctrl->pci_bus, pdev->bus, sizeof (*ctrl->pci_bus));
397 ctrl->bus = pdev->bus->number; 389 ctrl->bus = pdev->bus->number;
398 ctrl->slot_bus = pdev->subordinate->number; 390 ctrl->slot_bus = pdev->subordinate->number;
399 ctrl->device = PCI_SLOT(pdev->devfn); 391 ctrl->device = PCI_SLOT(pdev->devfn);
@@ -408,7 +400,7 @@ static int shpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
408 rc = get_ctlr_slot_config(ctrl); 400 rc = get_ctlr_slot_config(ctrl);
409 if (rc) { 401 if (rc) {
410 err(msg_initialization_err, rc); 402 err(msg_initialization_err, rc);
411 goto err_out_free_ctrl_bus; 403 goto err_out_unmap_mmio_region;
412 } 404 }
413 first_device_num = ctrl->slot_device_offset; 405 first_device_num = ctrl->slot_device_offset;
414 num_ctlr_slots = ctrl->num_slots; 406 num_ctlr_slots = ctrl->num_slots;
@@ -446,8 +438,6 @@ static int shpc_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
446 438
447err_out_free_ctrl_slot: 439err_out_free_ctrl_slot:
448 cleanup_slots(ctrl); 440 cleanup_slots(ctrl);
449err_out_free_ctrl_bus:
450 kfree(ctrl->pci_bus);
451err_out_unmap_mmio_region: 441err_out_unmap_mmio_region:
452 ctrl->hpc_ops->release_ctlr(ctrl); 442 ctrl->hpc_ops->release_ctlr(ctrl);
453err_out_free_ctrl: 443err_out_free_ctrl:
@@ -481,7 +471,6 @@ static void __exit unload_shpchpd(void)
481 ctrl = list_entry(tmp, struct controller, ctrl_list); 471 ctrl = list_entry(tmp, struct controller, ctrl_list);
482 shpchp_remove_ctrl_files(ctrl); 472 shpchp_remove_ctrl_files(ctrl);
483 cleanup_slots(ctrl); 473 cleanup_slots(ctrl);
484 kfree (ctrl->pci_bus);
485 ctrl->hpc_ops->release_ctlr(ctrl); 474 ctrl->hpc_ops->release_ctlr(ctrl);
486 kfree(ctrl); 475 kfree(ctrl);
487 } 476 }