diff options
| author | misonyo <[email protected]> | 2019-05-13 15:52:20 +0800 |
|---|---|---|
| committer | misonyo <[email protected]> | 2019-05-13 15:57:04 +0800 |
| commit | f58e947da6c451fd730bff9ac47130f85dd4a39c (patch) | |
| tree | 7e22c06c5cb794d466fb64ba7299041148c3de9c /components | |
| parent | 9f7cc78b06e45b18d1385a4827e4c03364a13a8f (diff) | |
[components/drivers/serial]add low level DMA TX config support.
Diffstat (limited to 'components')
| -rw-r--r-- | components/drivers/serial/serial.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/components/drivers/serial/serial.c b/components/drivers/serial/serial.c index d4cf35414c..c3e96fc77b 100644 --- a/components/drivers/serial/serial.c +++ b/components/drivers/serial/serial.c @@ -675,6 +675,8 @@ static rt_err_t rt_serial_open(struct rt_device *dev, rt_uint16_t oflag) serial->serial_tx = tx_dma; dev->open_flag |= RT_DEVICE_FLAG_DMA_TX; + /* configure low level device */ + serial->ops->control(serial, RT_DEVICE_CTRL_CONFIG, (void *)RT_DEVICE_FLAG_DMA_TX); } #endif /* RT_SERIAL_USING_DMA */ else |
