diff options
author | Eric Sesterhenn <snakebyte@gmx.de> | 2006-02-28 09:34:49 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-03-23 17:35:17 -0500 |
commit | f5afe8064f3087bead8fea7e32547c2a3ada5fd0 (patch) | |
tree | de6a9d60aad6ee262c04290d73e414cd92b4ad5d /drivers/pci/pci-sysfs.c | |
parent | 7c8f25da12a3dda46fb730699582895d5fc51287 (diff) |
[PATCH] PCI: kzalloc() conversion in drivers/pci
this patch converts drivers/pci to kzalloc usage.
Compile tested with allyes config.
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/pci/pci-sysfs.c')
-rw-r--r-- | drivers/pci/pci-sysfs.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c index 965a5934623a..56ac2bc003c7 100644 --- a/drivers/pci/pci-sysfs.c +++ b/drivers/pci/pci-sysfs.c | |||
@@ -501,9 +501,8 @@ int pci_create_sysfs_dev_files (struct pci_dev *pdev) | |||
501 | if (pci_resource_len(pdev, PCI_ROM_RESOURCE)) { | 501 | if (pci_resource_len(pdev, PCI_ROM_RESOURCE)) { |
502 | struct bin_attribute *rom_attr; | 502 | struct bin_attribute *rom_attr; |
503 | 503 | ||
504 | rom_attr = kmalloc(sizeof(*rom_attr), GFP_ATOMIC); | 504 | rom_attr = kzalloc(sizeof(*rom_attr), GFP_ATOMIC); |
505 | if (rom_attr) { | 505 | if (rom_attr) { |
506 | memset(rom_attr, 0x00, sizeof(*rom_attr)); | ||
507 | pdev->rom_attr = rom_attr; | 506 | pdev->rom_attr = rom_attr; |
508 | rom_attr->size = pci_resource_len(pdev, PCI_ROM_RESOURCE); | 507 | rom_attr->size = pci_resource_len(pdev, PCI_ROM_RESOURCE); |
509 | rom_attr->attr.name = "rom"; | 508 | rom_attr->attr.name = "rom"; |