mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
synced 2025-04-19 20:58:31 +09:00
fsi: core: Use const 'struct bin_attribute' callbacks
The sysfs core now provides callback variants that explicitly take a const pointer. Make use of it to match the attribute definition. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Reviewed-by: Eddie James <eajames@linux.ibm.com> Link: https://lore.kernel.org/r/20241215-sysfs-const-bin_attr-fsi-v1-1-b717f76a0146@weissschuh.net Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
600aa8d31a
commit
4ab0279857
@ -554,7 +554,7 @@ static unsigned long aligned_access_size(size_t offset, size_t count)
|
||||
}
|
||||
|
||||
static ssize_t fsi_slave_sysfs_raw_read(struct file *file,
|
||||
struct kobject *kobj, struct bin_attribute *attr, char *buf,
|
||||
struct kobject *kobj, const struct bin_attribute *attr, char *buf,
|
||||
loff_t off, size_t count)
|
||||
{
|
||||
struct fsi_slave *slave = to_fsi_slave(kobj_to_dev(kobj));
|
||||
@ -581,7 +581,7 @@ static ssize_t fsi_slave_sysfs_raw_read(struct file *file,
|
||||
}
|
||||
|
||||
static ssize_t fsi_slave_sysfs_raw_write(struct file *file,
|
||||
struct kobject *kobj, struct bin_attribute *attr,
|
||||
struct kobject *kobj, const struct bin_attribute *attr,
|
||||
char *buf, loff_t off, size_t count)
|
||||
{
|
||||
struct fsi_slave *slave = to_fsi_slave(kobj_to_dev(kobj));
|
||||
@ -613,8 +613,8 @@ static const struct bin_attribute fsi_slave_raw_attr = {
|
||||
.mode = 0600,
|
||||
},
|
||||
.size = 0,
|
||||
.read = fsi_slave_sysfs_raw_read,
|
||||
.write = fsi_slave_sysfs_raw_write,
|
||||
.read_new = fsi_slave_sysfs_raw_read,
|
||||
.write_new = fsi_slave_sysfs_raw_write,
|
||||
};
|
||||
|
||||
static void fsi_slave_release(struct device *dev)
|
||||
|
Loading…
x
Reference in New Issue
Block a user