未验证 提交 8f0cef3a 编写于 作者: 哈哈哈可是开电脑's avatar 哈哈哈可是开电脑 提交者: GitHub

[drivers][serial_v2]修复DMA+TX阻塞模式异常 (#6781)

* [drivers][serial_v2]修复DMA+TX阻塞模式异常
上级 24575c44
/*
* Copyright (c) 2006-2021, RT-Thread Development Team
* Copyright (c) 2006-2022, RT-Thread Development Team
*
* SPDX-License-Identifier: Apache-2.0
*
......@@ -694,6 +694,7 @@ static rt_err_t rt_serial_tx_enable(struct rt_device *dev,
tx_fifo->activated = RT_FALSE;
tx_fifo->put_size = 0;
rt_memset(&tx_fifo->rb, RT_NULL, sizeof(tx_fifo->rb));
rt_completion_init(&(tx_fifo->tx_cpt));
dev->open_flag |= RT_SERIAL_TX_BLOCKING;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册