git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
vserver 2.0 rc7
[linux-2.6.git]
/
drivers
/
pci
/
hotplug
/
pci_hotplug_core.c
diff --git
a/drivers/pci/hotplug/pci_hotplug_core.c
b/drivers/pci/hotplug/pci_hotplug_core.c
index
906fd9b
..
c802f62
100644
(file)
--- a/
drivers/pci/hotplug/pci_hotplug_core.c
+++ b/
drivers/pci/hotplug/pci_hotplug_core.c
@@
-567,6
+567,11
@@
int pci_hp_register (struct hotplug_slot *slot)
return -ENODEV;
if ((slot->info == NULL) || (slot->ops == NULL))
return -EINVAL;
return -ENODEV;
if ((slot->info == NULL) || (slot->ops == NULL))
return -EINVAL;
+ if (slot->release == NULL) {
+ dbg("Why are you trying to register a hotplug slot"
+ "without a proper release function?\n");
+ return -EINVAL;
+ }
kobject_set_name(&slot->kobj, "%s", slot->name);
kobj_set_kset_s(slot, pci_hotplug_slots_subsys);
kobject_set_name(&slot->kobj, "%s", slot->name);
kobj_set_kset_s(slot, pci_hotplug_slots_subsys);