summaryrefslogtreecommitdiff
path: root/components/drivers/serial
diff options
context:
space:
mode:
authorliuxianliang <[email protected]>2021-04-06 10:42:58 +0800
committerliuxianliang <[email protected]>2021-04-06 10:42:58 +0800
commit233e1cd8bc7cbdc38006dfc18adde8bc2595620f (patch)
treecec4669f56b09734b7dcc2682d854fef325722b8 /components/drivers/serial
parent4431c4796fb3e26fb66c012feb8bf47f3292b473 (diff)
parentc5a0df2254bd6fadc941a33d9066ce6b972c4274 (diff)
Merge branch 'master' of https://github.com/RT-Thread/rt-thread into develop_one
Diffstat (limited to 'components/drivers/serial')
-rw-r--r--components/drivers/serial/serial.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/components/drivers/serial/serial.c b/components/drivers/serial/serial.c
index d9a20f05a0..32161ad0cb 100644
--- a/components/drivers/serial/serial.c
+++ b/components/drivers/serial/serial.c
@@ -816,11 +816,11 @@ static rt_err_t rt_serial_close(struct rt_device *dev)
/* configure low level device */
serial->ops->control(serial, RT_DEVICE_CTRL_CLR_INT, (void *) RT_DEVICE_FLAG_DMA_TX);
}
+#endif /* RT_SERIAL_USING_DMA */
serial->ops->control(serial, RT_DEVICE_CTRL_CLOSE, RT_NULL);
dev->flag &= ~RT_DEVICE_FLAG_ACTIVATED;
-#endif /* RT_SERIAL_USING_DMA */
return RT_EOK;
}