[SCSI] arcmsr: fix up bin_attr functions
authorJames Bottomley <James.Bottomley@suse.de>
Tue, 27 Jul 2010 17:30:24 +0000 (12:30 -0500)
committerJames Bottomley <James.Bottomley@suse.de>
Wed, 28 Jul 2010 14:05:27 +0000 (09:05 -0500)
Commit

commit 2c3c8bea608866d8bd9dcf92657d57fdcac011c5
Author: Chris Wright <chrisw@sous-sol.org>
Date:   Wed May 12 18:28:57 2010 -0700

    sysfs: add struct file* to bin_attr callbacks

Added an extra struct file * parameter at the beginning, which the
arcmsr binary attribute additions didn't have.  Fix this to prevent
nasty crashes.

Cc: Nick Cheng <nick.cheng@areca.com.tw>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/arcmsr/arcmsr_attr.c

index 69f8346aa288348a86a8d9885dbfd1759867c5ad..07fdfe57e38e07eaf501ddc83a8aba77ed3ca39c 100644 (file)
@@ -59,7 +59,8 @@
 
 struct device_attribute *arcmsr_host_attrs[];
 
-static ssize_t arcmsr_sysfs_iop_message_read(struct kobject *kobj,
+static ssize_t arcmsr_sysfs_iop_message_read(struct file *filp,
+                                            struct kobject *kobj,
                                             struct bin_attribute *bin,
                                             char *buf, loff_t off,
                                             size_t count)
@@ -105,7 +106,8 @@ static ssize_t arcmsr_sysfs_iop_message_read(struct kobject *kobj,
        return (allxfer_len);
 }
 
-static ssize_t arcmsr_sysfs_iop_message_write(struct kobject *kobj,
+static ssize_t arcmsr_sysfs_iop_message_write(struct file *filp,
+                                             struct kobject *kobj,
                                              struct bin_attribute *bin,
                                              char *buf, loff_t off,
                                              size_t count)
@@ -153,7 +155,8 @@ static ssize_t arcmsr_sysfs_iop_message_write(struct kobject *kobj,
        }
 }
 
-static ssize_t arcmsr_sysfs_iop_message_clear(struct kobject *kobj,
+static ssize_t arcmsr_sysfs_iop_message_clear(struct file *filp,
+                                             struct kobject *kobj,
                                              struct bin_attribute *bin,
                                              char *buf, loff_t off,
                                              size_t count)