diff --git a/arch/at91sam3x8e/serial.c b/arch/at91sam3x8e/serial.c index ca14e9f..715d149 100644 --- a/arch/at91sam3x8e/serial.c +++ b/arch/at91sam3x8e/serial.c @@ -99,11 +99,11 @@ ssize_t serial_write_dma(struct serial_device *dev, struct dmabuf *buf) uint16_t len; struct arch_serial_device *arch_dev = to_arch_serial_device(dev); - dmabuf_get(buf); - if (arch_dev->tx_next != NULL) return -EBUSY; + dmabuf_get(buf); + if (buf->len >= 0xffff) len = 0xffff; else