summaryrefslogtreecommitdiffstats
path: root/drivers/tty
diff options
context:
space:
mode:
authorMartyn Welch <martyn.welch@collabora.co.uk>2017-09-28 11:07:40 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-10-03 20:28:08 +0200
commitf654b23c173eb7081e1f5bd33710a53c11ea4b49 (patch)
tree3ba2cf25c654199c82d2c87b6da16ecd1db45d4e /drivers/tty
parent4139fd76cd92b350114b102f1b40b02381b198cf (diff)
downloadop-kernel-dev-f654b23c173eb7081e1f5bd33710a53c11ea4b49.zip
op-kernel-dev-f654b23c173eb7081e1f5bd33710a53c11ea4b49.tar.gz
serial: imx: Use RX_BUF_SIZE to set size of RX buffer
The imx serial driver uses PAGE_SIZE when allocating rx_buf, but then uses RX_BUF_SIZE (which is currently defined as PAGE_SIZE) to describe the length of the buffer when initialising the scatter gather list. In order to ensure that this stays consistent, use RX_BUF_SIZE in both locations. Signed-off-by: Martyn Welch <martyn.welch@collabora.co.uk> Acked-by: Uwe Kleine-König <u.kleine-könig@pengtronix.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty')
-rw-r--r--drivers/tty/serial/imx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c
index a42f386..9800fda 100644
--- a/drivers/tty/serial/imx.c
+++ b/drivers/tty/serial/imx.c
@@ -1166,7 +1166,7 @@ static int imx_uart_dma_init(struct imx_port *sport)
goto err;
}
- sport->rx_buf = kzalloc(PAGE_SIZE, GFP_KERNEL);
+ sport->rx_buf = kzalloc(RX_BUF_SIZE, GFP_KERNEL);
if (!sport->rx_buf) {
ret = -ENOMEM;
goto err;
OpenPOWER on IntegriCloud