Commit 73a985a1 authored by Mariusz Kozlowski's avatar Mariusz Kozlowski Committed by Greg Kroah-Hartman

PCI Hotplug: cpqphp_ctrl.c: kmalloc + memset conversion to kzalloc

 drivers/pci/hotplug/cpqphp_ctrl.c | 79698 -> 79638 (-60 bytes)
 drivers/pci/hotplug/cpqphp_ctrl.o | 192896 -> 192736 (-160 bytes)
Signed-off-by: default avatarMariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 782e3b3b
...@@ -973,16 +973,13 @@ struct pci_func *cpqhp_slot_create(u8 busnumber) ...@@ -973,16 +973,13 @@ struct pci_func *cpqhp_slot_create(u8 busnumber)
struct pci_func *new_slot; struct pci_func *new_slot;
struct pci_func *next; struct pci_func *next;
new_slot = kmalloc(sizeof(*new_slot), GFP_KERNEL); new_slot = kzalloc(sizeof(*new_slot), GFP_KERNEL);
if (new_slot == NULL) { if (new_slot == NULL) {
/* I'm not dead yet! /* I'm not dead yet!
* You will be. */ * You will be. */
return new_slot; return new_slot;
} }
memset(new_slot, 0, sizeof(struct pci_func));
new_slot->next = NULL; new_slot->next = NULL;
new_slot->configured = 1; new_slot->configured = 1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment