I believe that BUG_ON is different issue.
I'm not sure what's the correct locking scheme for tty->read_buf. I
guess that it's allocated as part of tty initialization, and only
removed during n_tty_close(), correct? So we should not need any lock there.
Perhaps we should change that BUG_ON(!tty->read_buf); to just return
-EAGAIN, as e.g. n_tty_receive_buf does?
if (!tty->read_buf)
return;
I will submit a separate patch changing the BUG_ON to return, I believe
it's still better to drop a n_tty_read() rather than panic whole system.
But I still don't understand how this can happen - that we have a tty
operational without a buffer allocated. There still must be some other race.
-Stanislav
Should this also be removing the BUG_ON check you noted in the other
email was not valid now ?
Alan
--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html