[PATCH v2 24/45] drivers: tty: serial: mxs-auart: use devm_* functions

From: Enrico Weigelt, metux IT consult
Date: Thu Mar 14 2019 - 18:37:48 EST


Use the safer devm versions of memory mapping functions.

Signed-off-by: Enrico Weigelt, metux IT consult <info@xxxxxxxxx>
---
drivers/tty/serial/mxs-auart.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/tty/serial/mxs-auart.c b/drivers/tty/serial/mxs-auart.c
index 27235a5..0a43c69 100644
--- a/drivers/tty/serial/mxs-auart.c
+++ b/drivers/tty/serial/mxs-auart.c
@@ -1685,7 +1685,7 @@ static int mxs_auart_probe(struct platform_device *pdev)
}

s->port.mapbase = r->start;
- s->port.membase = ioremap(r->start, resource_size(r));
+ s->port.membase = devm_ioremap_resource(s->port.dev, r);
s->port.ops = &mxs_auart_ops;
s->port.iotype = UPIO_MEM;
s->port.fifosize = MXS_AUART_FIFO_SIZE;
--
1.9.1