diff options
author | Chris Wright <chrisw@sous-sol.org> | 2010-05-12 21:28:57 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-05-21 12:37:31 -0400 |
commit | 2c3c8bea608866d8bd9dcf92657d57fdcac011c5 (patch) | |
tree | f509b958d0a65c46c831dbdd447a81e706dd995a /drivers/scsi/ibmvscsi | |
parent | 68d75ed4b84a0806ecd4bc14da4759713b23a532 (diff) |
sysfs: add struct file* to bin_attr callbacks
This allows bin_attr->read,write,mmap callbacks to check file specific data
(such as inode owner) as part of any privilege validation.
Signed-off-by: Chris Wright <chrisw@sous-sol.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/scsi/ibmvscsi')
-rw-r--r-- | drivers/scsi/ibmvscsi/ibmvfc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/ibmvscsi/ibmvfc.c b/drivers/scsi/ibmvscsi/ibmvfc.c index d18f45c95639..3eb2b7b3d8b0 100644 --- a/drivers/scsi/ibmvscsi/ibmvfc.c +++ b/drivers/scsi/ibmvscsi/ibmvfc.c | |||
@@ -2919,6 +2919,7 @@ static DEVICE_ATTR(log_level, S_IRUGO | S_IWUSR, | |||
2919 | #ifdef CONFIG_SCSI_IBMVFC_TRACE | 2919 | #ifdef CONFIG_SCSI_IBMVFC_TRACE |
2920 | /** | 2920 | /** |
2921 | * ibmvfc_read_trace - Dump the adapter trace | 2921 | * ibmvfc_read_trace - Dump the adapter trace |
2922 | * @filp: open sysfs file | ||
2922 | * @kobj: kobject struct | 2923 | * @kobj: kobject struct |
2923 | * @bin_attr: bin_attribute struct | 2924 | * @bin_attr: bin_attribute struct |
2924 | * @buf: buffer | 2925 | * @buf: buffer |
@@ -2928,7 +2929,7 @@ static DEVICE_ATTR(log_level, S_IRUGO | S_IWUSR, | |||
2928 | * Return value: | 2929 | * Return value: |
2929 | * number of bytes printed to buffer | 2930 | * number of bytes printed to buffer |
2930 | **/ | 2931 | **/ |
2931 | static ssize_t ibmvfc_read_trace(struct kobject *kobj, | 2932 | static ssize_t ibmvfc_read_trace(struct file *filp, struct kobject *kobj, |
2932 | struct bin_attribute *bin_attr, | 2933 | struct bin_attribute *bin_attr, |
2933 | char *buf, loff_t off, size_t count) | 2934 | char *buf, loff_t off, size_t count) |
2934 | { | 2935 | { |