Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 10674
b: refs/heads/master
c: 934199e
h: refs/heads/master
v: v3
  • Loading branch information
linas authored and Greg Kroah-Hartman committed Oct 28, 2005
1 parent 4c1ad45 commit 047d2ab
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b7924c38c9a9c6151213bc0d91776eace614e761
refs/heads/master: 934199e95d6ac28f42686fe3009877eff33e06c3
3 changes: 2 additions & 1 deletion trunk/drivers/pci/hotplug/rpaphp.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,9 +92,10 @@ extern struct pci_bus *rpaphp_find_pci_bus(struct device_node *dn);
extern int rpaphp_claim_resource(struct pci_dev *dev, int resource);
extern int rpaphp_enable_pci_slot(struct slot *slot);
extern int register_pci_slot(struct slot *slot);
extern int rpaphp_unconfig_pci_adapter(struct slot *slot);
extern int rpaphp_get_pci_adapter_status(struct slot *slot, int is_init, u8 * value);

extern int rpaphp_config_pci_adapter(struct pci_bus *bus);
extern int rpaphp_unconfig_pci_adapter(struct pci_bus *bus);

/* rpaphp_core.c */
extern int rpaphp_add_slot(struct device_node *dn);
Expand Down
5 changes: 4 additions & 1 deletion trunk/drivers/pci/hotplug/rpaphp_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -426,8 +426,11 @@ static int disable_slot(struct hotplug_slot *hotplug_slot)

dbg("DISABLING SLOT %s\n", slot->name);
down(&rpaphp_sem);
retval = rpaphp_unconfig_pci_adapter(slot);
retval = rpaphp_unconfig_pci_adapter(slot->bus);
up(&rpaphp_sem);
slot->state = NOT_CONFIGURED;
info("%s: devices in slot[%s] unconfigured.\n", __FUNCTION__,
slot->name);
exit:
dbg("%s - Exit: rc[%d]\n", __FUNCTION__, retval);
return retval;
Expand Down
11 changes: 3 additions & 8 deletions trunk/drivers/pci/hotplug/rpaphp_pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -319,20 +319,15 @@ static void rpaphp_eeh_remove_bus_device(struct pci_dev *dev)
return;
}

int rpaphp_unconfig_pci_adapter(struct slot *slot)
int rpaphp_unconfig_pci_adapter(struct pci_bus *bus)
{
struct pci_dev *dev, *tmp;
int retval = 0;

list_for_each_entry_safe(dev, tmp, slot->pci_devs, bus_list) {
list_for_each_entry_safe(dev, tmp, &bus->devices, bus_list) {
rpaphp_eeh_remove_bus_device(dev);
pci_remove_bus_device(dev);
}

slot->state = NOT_CONFIGURED;
info("%s: devices in slot[%s] unconfigured.\n", __FUNCTION__,
slot->name);
return retval;
return 0;
}

static int setup_pci_hotplug_slot_info(struct slot *slot)
Expand Down

0 comments on commit 047d2ab

Please sign in to comment.