if (actual < 0) {
netdev_err(elm->dev, "Failed to write to tty %s.\n", elm->tty->name);
elm327_hw_failure(elm);
+ return;
}
elm->txleft = len - actual;
*/
pr_err("RX buffer overflow. Faulty ELM327 connected?\n");
elm327_hw_failure(elm);
+ return;
} else if (len == elm->rxfill) {
if (elm->state == ELM_RECEIVING
&& elm->rxbuf[elm->rxfill - 1] == ELM327_READY_CHAR) {
if (actual < 0) {
netdev_err(elm->dev, "Failed to write to tty %s.\n", elm->tty->name);
elm327_hw_failure(elm);
+ spin_unlock_bh(&elm->lock);
+ return;
}
elm->txleft -= actual;
To Do list for future development
----------------------------------
-- Stop current function when in ``elm327_panic()``
-
- DMA capable rx/tx buffers
- flushing of ``tx_work`` is too late in ``ldisc_close()``