INIT: version 2.88 booting

发现调试串口启动时,INIT: 卡了30s, version 2.88 booting 又卡了30s,通过分析sysvinit代码发现串口执行close时,阻塞到tx_empty函数,在串口驱动中添加uart_update_timeout(port, termios->c_cflag, baud);即可解决这个问题。

下面是具体的分析流程

串口执行close时,最后调用

    while (!port->ops->tx_empty(port)) {
        msleep_interruptible(jiffies_to_msecs(char_time));
        if (signal_pending(current))
            break;
        if (time_after(jiffies, expire))
            break;
    }

这个msleep_interruptible就是导致那个30s 

原文地址:https://www.cnblogs.com/yangv/p/11679839.html