[PATCH tty/serial 4/5] tty: serial: fsl_lpuart: remove sg_set_buf() for sport->rx_sgl

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Fugang Duan <fugang.duan@xxxxxxx>

Since .sg_init_one() already set sg entry page like below code.
	sg_init_one()
		sg_init_table(sg, 1);
		sg_set_buf(sg, buf, buflen);

So it should not set sg entry page again, remove the redundant code.

Signed-off-by: Fugang Duan <fugang.duan@xxxxxxx>
---
 drivers/tty/serial/fsl_lpuart.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/tty/serial/fsl_lpuart.c b/drivers/tty/serial/fsl_lpuart.c
index 746681b..ba87b58 100644
--- a/drivers/tty/serial/fsl_lpuart.c
+++ b/drivers/tty/serial/fsl_lpuart.c
@@ -1102,7 +1102,6 @@ static inline int lpuart_start_rx_dma(struct lpuart_port *sport)
 		return -ENOMEM;
 
 	sg_init_one(&sport->rx_sgl, ring->buf, sport->rx_dma_rng_buf_len);
-	sg_set_buf(&sport->rx_sgl, ring->buf, sport->rx_dma_rng_buf_len);
 	nent = dma_map_sg(sport->port.dev, &sport->rx_sgl, 1, DMA_FROM_DEVICE);
 
 	if (!nent) {
-- 
2.7.4




[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux