summaryrefslogtreecommitdiff
path: root/drivers/tty
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2021-10-12 17:39:42 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-10-13 14:33:59 +0200
commit70b4d23226c85a30affd612a05c5898a724bcd62 (patch)
tree0369cccc3cbb3bbff7b99b0f0f77c413fe87f7a6 /drivers/tty
parent2cb3315107b5b3312b0f434efdb3ad354274e2a5 (diff)
serial: max310x: Make max310x_remove() return void
Up to now max310x_remove() returns zero unconditionally. Make it return void instead which makes it easier to see in the callers that there is no error to handle. Also the return value of spi remove callbacks is ignored anyway. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20211012153945.2651412-18-u.kleine-koenig@pengutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty')
-rw-r--r--drivers/tty/serial/max310x.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/tty/serial/max310x.c b/drivers/tty/serial/max310x.c
index 3df0788ddeb0..dde0824b2fa5 100644
--- a/drivers/tty/serial/max310x.c
+++ b/drivers/tty/serial/max310x.c
@@ -1426,7 +1426,7 @@ out_clk:
return ret;
}
-static int max310x_remove(struct device *dev)
+static void max310x_remove(struct device *dev)
{
struct max310x_port *s = dev_get_drvdata(dev);
int i;
@@ -1441,8 +1441,6 @@ static int max310x_remove(struct device *dev)
}
clk_disable_unprepare(s->clk);
-
- return 0;
}
static const struct of_device_id __maybe_unused max310x_dt_ids[] = {
@@ -1491,7 +1489,8 @@ static int max310x_spi_probe(struct spi_device *spi)
static int max310x_spi_remove(struct spi_device *spi)
{
- return max310x_remove(&spi->dev);
+ max310x_remove(&spi->dev);
+ return 0;
}
static const struct spi_device_id max310x_id_table[] = {