diff options
| author | Thomas Weißschuh <linux@weissschuh.net> | 2024-11-03 17:03:39 +0000 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-11-05 14:00:28 +0100 |
| commit | 562e932a077cb35173d8dc11e5005f9c5acd22f0 (patch) | |
| tree | b56484e8d2d0d75726021d55e88d69228eb1afe3 /drivers/base/topology.c | |
| parent | eb2e6c3a8d66ff37b2ee26cd32334ae0e05fd596 (diff) | |
driver core: Constify attribute arguments of binary attributes
As preparation for the constification of struct bin_attribute,
constify the arguments of the read and write callbacks.
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Acked-by: Krzysztof Wilczyński <kw@linux.com>
Link: https://lore.kernel.org/r/20241103-sysfs-const-bin_attr-v2-10-71110628844c@weissschuh.net
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/base/topology.c')
| -rw-r--r-- | drivers/base/topology.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/base/topology.c b/drivers/base/topology.c index 89f98be5c5b9..1090751d7f45 100644 --- a/drivers/base/topology.c +++ b/drivers/base/topology.c @@ -23,7 +23,7 @@ static ssize_t name##_show(struct device *dev, \ #define define_siblings_read_func(name, mask) \ static ssize_t name##_read(struct file *file, struct kobject *kobj, \ - struct bin_attribute *attr, char *buf, \ + const struct bin_attribute *attr, char *buf, \ loff_t off, size_t count) \ { \ struct device *dev = kobj_to_dev(kobj); \ @@ -33,7 +33,7 @@ static ssize_t name##_read(struct file *file, struct kobject *kobj, \ } \ \ static ssize_t name##_list_read(struct file *file, struct kobject *kobj, \ - struct bin_attribute *attr, char *buf, \ + const struct bin_attribute *attr, char *buf, \ loff_t off, size_t count) \ { \ struct device *dev = kobj_to_dev(kobj); \ |
