[2/2] Input: edt-ft5x06 - rename sysfs attribute report_rate to report_rate_hz
Commit Message
The sysfs attribute has been renamed to report_rate_hz to match the
report-rate-hz property from device tree, making it clear that the same
parameter can be set via sysfs or device tree and behaves identically.
Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
---
drivers/input/touchscreen/edt-ft5x06.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
Comments
Hi Dario,
On Mon, Sep 15, 2025 at 10:16:32PM +0200, Dario Binacchi wrote:
> The sysfs attribute has been renamed to report_rate_hz to match the
> report-rate-hz property from device tree, making it clear that the same
> parameter can be set via sysfs or device tree and behaves identically.
No, this attribute was defined since forever and we should avoid
gratuitous renames: they will break existing users.
Thanks.
Hello Dmitry,
On Tue, Sep 16, 2025 at 2:38 AM Dmitry Torokhov
<dmitry.torokhov@gmail.com> wrote:
>
> Hi Dario,
>
> On Mon, Sep 15, 2025 at 10:16:32PM +0200, Dario Binacchi wrote:
> > The sysfs attribute has been renamed to report_rate_hz to match the
> > report-rate-hz property from device tree, making it clear that the same
> > parameter can be set via sysfs or device tree and behaves identically.
>
> No, this attribute was defined since forever and we should avoid
> gratuitous renames: they will break existing users.
OK, I understand.
Do you think patch 1/2 is correct?
Thanks and regards,
Dario
>
> Thanks.
>
> --
> Dmitry
@@ -543,8 +543,8 @@ static int edt_ft5x06_report_rate_get(struct edt_ft5x06_ts_data *tsdata)
return 0;
}
-static ssize_t report_rate_show(struct device *dev,
- struct device_attribute *dattr, char *buf)
+static ssize_t report_rate_hz_show(struct device *dev,
+ struct device_attribute *dattr, char *buf)
{
struct i2c_client *client = to_i2c_client(dev);
struct edt_ft5x06_ts_data *tsdata = i2c_get_clientdata(client);
@@ -597,9 +597,9 @@ static int edt_ft5x06_report_rate_set(struct edt_ft5x06_ts_data *tsdata,
val);
}
-static ssize_t report_rate_store(struct device *dev,
- struct device_attribute *dattr,
- const char *buf, size_t count)
+static ssize_t report_rate_hz_store(struct device *dev,
+ struct device_attribute *dattr,
+ const char *buf, size_t count)
{
struct i2c_client *client = to_i2c_client(dev);
struct edt_ft5x06_ts_data *tsdata = i2c_get_clientdata(client);
@@ -645,7 +645,7 @@ static ssize_t report_rate_store(struct device *dev,
return error ?: count;
}
-static DEVICE_ATTR_RW(report_rate);
+static DEVICE_ATTR_RW(report_rate_hz);
static ssize_t model_show(struct device *dev, struct device_attribute *attr,
char *buf)
@@ -699,7 +699,7 @@ static struct attribute *edt_ft5x06_attrs[] = {
&edt_ft5x06_attr_offset_x.dattr.attr,
&edt_ft5x06_attr_offset_y.dattr.attr,
&edt_ft5x06_attr_threshold.dattr.attr,
- &dev_attr_report_rate.attr,
+ &dev_attr_report_rate_hz.attr,
&dev_attr_model.attr,
&dev_attr_fw_version.attr,
&dev_attr_header_errors.attr,