lkml.org 
[lkml]   [2005]   [Jan]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH] sysfs: export the vfs release call of binary attribute
Initialize the allocated bin_attribute structure, otherwise unused fields
are pointing to random places.

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>

===== drivers/pci/pci-sysfs.c 1.16 vs edited =====
--- 1.16/drivers/pci/pci-sysfs.c 2005-01-06 21:30:29 +01:00
+++ edited/drivers/pci/pci-sysfs.c 2005-01-27 21:05:35 +01:00
@@ -435,6 +435,7 @@ int pci_create_sysfs_dev_files (struct p
struct bin_attribute *rom_attr;

rom_attr = kmalloc(sizeof(*rom_attr), GFP_ATOMIC);
+ memset(rom_attr, 0x00, sizeof(*rom_attr));
if (rom_attr) {
pdev->rom_attr = rom_attr;
rom_attr->size = pci_resource_len(pdev, PCI_ROM_RESOURCE);
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:09    [W:0.026 / U:0.372 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site