serial: sh-sci: Use DEVICE_ATTR_RW() for rx_fifo_trigger

While commit b6b996b6cd ("treewide: Use DEVICE_ATTR_RW") converted
the rx_fifo_timeout attribute, it forgot to convert rx_fifo_trigger due
to a slightly different function naming.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Ulrich Hecht <uli+renesas@fpond.eu>
Link: https://lore.kernel.org/r/20190731124555.14349-1-geert+renesas@glider.be
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Geert Uytterhoeven 2019-07-31 14:45:55 +02:00 committed by Greg Kroah-Hartman
parent ce73460054
commit 7027e62a7d
1 changed files with 6 additions and 8 deletions

View File

@ -1092,9 +1092,8 @@ static void rx_fifo_timer_fn(struct timer_list *t)
scif_set_rtrg(port, 1); scif_set_rtrg(port, 1);
} }
static ssize_t rx_trigger_show(struct device *dev, static ssize_t rx_fifo_trigger_show(struct device *dev,
struct device_attribute *attr, struct device_attribute *attr, char *buf)
char *buf)
{ {
struct uart_port *port = dev_get_drvdata(dev); struct uart_port *port = dev_get_drvdata(dev);
struct sci_port *sci = to_sci_port(port); struct sci_port *sci = to_sci_port(port);
@ -1102,10 +1101,9 @@ static ssize_t rx_trigger_show(struct device *dev,
return sprintf(buf, "%d\n", sci->rx_trigger); return sprintf(buf, "%d\n", sci->rx_trigger);
} }
static ssize_t rx_trigger_store(struct device *dev, static ssize_t rx_fifo_trigger_store(struct device *dev,
struct device_attribute *attr, struct device_attribute *attr,
const char *buf, const char *buf, size_t count)
size_t count)
{ {
struct uart_port *port = dev_get_drvdata(dev); struct uart_port *port = dev_get_drvdata(dev);
struct sci_port *sci = to_sci_port(port); struct sci_port *sci = to_sci_port(port);
@ -1123,7 +1121,7 @@ static ssize_t rx_trigger_store(struct device *dev,
return count; return count;
} }
static DEVICE_ATTR(rx_fifo_trigger, 0644, rx_trigger_show, rx_trigger_store); static DEVICE_ATTR_RW(rx_fifo_trigger);
static ssize_t rx_fifo_timeout_show(struct device *dev, static ssize_t rx_fifo_timeout_show(struct device *dev,
struct device_attribute *attr, struct device_attribute *attr,