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
linux 2.6.16.38 w/ vs2.0.3-rc1
[linux-2.6.git]
/
drivers
/
pci
/
hotplug
/
rpaphp_slot.c
diff --git
a/drivers/pci/hotplug/rpaphp_slot.c
b/drivers/pci/hotplug/rpaphp_slot.c
index
b771196
..
78943e0
100644
(file)
--- a/
drivers/pci/hotplug/rpaphp_slot.c
+++ b/
drivers/pci/hotplug/rpaphp_slot.c
@@
-84,16
+84,19
@@
struct slot *alloc_slot_struct(struct device_node *dn, int drc_index, char *drc_
{
struct slot *slot;
{
struct slot *slot;
- slot = k
zalloc(sizeof
(struct slot), GFP_KERNEL);
+ slot = k
malloc(sizeof
(struct slot), GFP_KERNEL);
if (!slot)
goto error_nomem;
if (!slot)
goto error_nomem;
- slot->hotplug_slot = kzalloc(sizeof(struct hotplug_slot), GFP_KERNEL);
+ memset(slot, 0, sizeof (struct slot));
+ slot->hotplug_slot = kmalloc(sizeof (struct hotplug_slot), GFP_KERNEL);
if (!slot->hotplug_slot)
goto error_slot;
if (!slot->hotplug_slot)
goto error_slot;
- slot->hotplug_slot->info = kzalloc(sizeof(struct hotplug_slot_info),
+ memset(slot->hotplug_slot, 0, sizeof (struct hotplug_slot));
+ slot->hotplug_slot->info = kmalloc(sizeof (struct hotplug_slot_info),
GFP_KERNEL);
if (!slot->hotplug_slot->info)
goto error_hpslot;
GFP_KERNEL);
if (!slot->hotplug_slot->info)
goto error_hpslot;
+ memset(slot->hotplug_slot->info, 0, sizeof (struct hotplug_slot_info));
slot->hotplug_slot->name = kmalloc(BUS_ID_SIZE + 1, GFP_KERNEL);
if (!slot->hotplug_slot->name)
goto error_info;
slot->hotplug_slot->name = kmalloc(BUS_ID_SIZE + 1, GFP_KERNEL);
if (!slot->hotplug_slot->name)
goto error_info;