diff options
-rw-r--r-- | drivers/pci/pci-sysfs.c | 4 | ||||
-rw-r--r-- | include/linux/sysfs.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c index 9fa183cfb0e9..de296452c957 100644 --- a/drivers/pci/pci-sysfs.c +++ b/drivers/pci/pci-sysfs.c | |||
@@ -642,7 +642,7 @@ void pci_create_legacy_files(struct pci_bus *b) | |||
642 | if (!b->legacy_io) | 642 | if (!b->legacy_io) |
643 | goto kzalloc_err; | 643 | goto kzalloc_err; |
644 | 644 | ||
645 | sysfs_bin_attr_init(&b->legacy_io); | 645 | sysfs_bin_attr_init(b->legacy_io); |
646 | b->legacy_io->attr.name = "legacy_io"; | 646 | b->legacy_io->attr.name = "legacy_io"; |
647 | b->legacy_io->size = 0xffff; | 647 | b->legacy_io->size = 0xffff; |
648 | b->legacy_io->attr.mode = S_IRUSR | S_IWUSR; | 648 | b->legacy_io->attr.mode = S_IRUSR | S_IWUSR; |
@@ -655,7 +655,7 @@ void pci_create_legacy_files(struct pci_bus *b) | |||
655 | goto legacy_io_err; | 655 | goto legacy_io_err; |
656 | 656 | ||
657 | /* Allocated above after the legacy_io struct */ | 657 | /* Allocated above after the legacy_io struct */ |
658 | sysfs_bin_attr_init(&b->legacy_mem); | 658 | sysfs_bin_attr_init(b->legacy_mem); |
659 | b->legacy_mem = b->legacy_io + 1; | 659 | b->legacy_mem = b->legacy_io + 1; |
660 | b->legacy_mem->attr.name = "legacy_mem"; | 660 | b->legacy_mem->attr.name = "legacy_mem"; |
661 | b->legacy_mem->size = 1024*1024; | 661 | b->legacy_mem->size = 1024*1024; |
diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h index d77cde6d0498..f0496b3d1811 100644 --- a/include/linux/sysfs.h +++ b/include/linux/sysfs.h | |||
@@ -110,7 +110,7 @@ struct bin_attribute { | |||
110 | * enabled. Lockdep gives a nice error when your attribute is | 110 | * enabled. Lockdep gives a nice error when your attribute is |
111 | * added to sysfs if you don't have this. | 111 | * added to sysfs if you don't have this. |
112 | */ | 112 | */ |
113 | #define sysfs_bin_attr_init(bin_attr) sysfs_attr_init(&bin_attr->attr) | 113 | #define sysfs_bin_attr_init(bin_attr) sysfs_attr_init(&(bin_attr)->attr) |
114 | 114 | ||
115 | struct sysfs_ops { | 115 | struct sysfs_ops { |
116 | ssize_t (*show)(struct kobject *, struct attribute *,char *); | 116 | ssize_t (*show)(struct kobject *, struct attribute *,char *); |