From dce8c96281dc66082c4f2ad686d3f699fb52439d Mon Sep 17 00:00:00 2001 From: Jiuzhu Dong Date: Fri, 31 Dec 2021 15:22:50 +0800 Subject: [PATCH] uart_rpmsg: fix data loss Signed-off-by: Jiuzhu Dong --- drivers/serial/uart_rpmsg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/serial/uart_rpmsg.c b/drivers/serial/uart_rpmsg.c index c00839ba09..b63a2deb86 100644 --- a/drivers/serial/uart_rpmsg.c +++ b/drivers/serial/uart_rpmsg.c @@ -255,7 +255,7 @@ static void uart_rpmsg_dmasend(FAR struct uart_dev_s *dev) if (len > xfer->length) { memcpy(msg->data, xfer->buffer, xfer->length); - memcpy(msg->data, xfer->nbuffer, len - xfer->length); + memcpy(msg->data + xfer->length, xfer->nbuffer, len - xfer->length); } else {