termios support
Geoffroy Montel
g_montel at yahoo.com
Tue May 5 07:51:54 UTC 1998
Hi
> =============================================================
> void
> device_write_routine (int minor, char *buf, int count)
> {
> UART->output_register = *buf;
> UART->control_register |= UART_TRANSMIT_INTERRUPT_ENABLE;
> }
>
> void
> device_transmit_interrupt_routine (int vector)
> {
> UART->control_register &= ~UART_TRANSMIT_INTERRUPT_ENABLE;
> rtems_termios_dequeue_characters (device_ttyp, 1);
> }
> =============================================================
I'm satisfied with this piece of code. It prevents from adding a call
to the
driver in termios.
But, wouldn't it be better if
void rtems_termios_dequeue_characters (void *ttyp, int len)
would be stg like
int rtems_termios_dequeue_characters (void *ttyp, int len)
and we'd return the state of the buffer ? (for instance, 0 when it's
empty
so that we stop the interrupts then, and 1 otherwise)
Thanks Eric!
Geoffroy
_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com
More information about the users
mailing list