diff options
author | Andi Kleen <andi@firstfloor.org> | 2010-01-05 06:48:06 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-03-07 20:04:47 -0500 |
commit | 8564a6c140317de04a71eb203bdbb58845d69f9c (patch) | |
tree | 92a9044e3ea45ea25fb7ec0993f4a499c7625e63 /drivers/base | |
parent | 1e395ab3d9b6aa09c5f0aa46a1b0a6fc5bd33133 (diff) |
sysdev: Fix type of sysdev class attribute in memory driver
This attribute is really a sysdev_class attribute, not a plain class attribute.
They are identical in layout currently, but this might not always be
the case.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/memory.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/base/memory.c b/drivers/base/memory.c index bd025059711f..563656ad75a1 100644 --- a/drivers/base/memory.c +++ b/drivers/base/memory.c | |||
@@ -309,17 +309,18 @@ static SYSDEV_ATTR(removable, 0444, show_mem_removable, NULL); | |||
309 | * Block size attribute stuff | 309 | * Block size attribute stuff |
310 | */ | 310 | */ |
311 | static ssize_t | 311 | static ssize_t |
312 | print_block_size(struct class *class, char *buf) | 312 | print_block_size(struct sysdev_class *class, struct sysdev_class_attribute *attr, |
313 | char *buf) | ||
313 | { | 314 | { |
314 | return sprintf(buf, "%#lx\n", (unsigned long)PAGES_PER_SECTION * PAGE_SIZE); | 315 | return sprintf(buf, "%#lx\n", (unsigned long)PAGES_PER_SECTION * PAGE_SIZE); |
315 | } | 316 | } |
316 | 317 | ||
317 | static CLASS_ATTR(block_size_bytes, 0444, print_block_size, NULL); | 318 | static SYSDEV_CLASS_ATTR(block_size_bytes, 0444, print_block_size, NULL); |
318 | 319 | ||
319 | static int block_size_init(void) | 320 | static int block_size_init(void) |
320 | { | 321 | { |
321 | return sysfs_create_file(&memory_sysdev_class.kset.kobj, | 322 | return sysfs_create_file(&memory_sysdev_class.kset.kobj, |
322 | &class_attr_block_size_bytes.attr); | 323 | &attr_block_size_bytes.attr); |
323 | } | 324 | } |
324 | 325 | ||
325 | /* | 326 | /* |