#include <devtty.h>
#include <rc2014.h>
-static char tbuf1[TTYSIZ];
-static char tbuf2[TTYSIZ];
+static uint8_t tbuf1[TTYSIZ];
+static uint8_t tbuf2[TTYSIZ];
static uint8_t sleeping;
0x02 /* 115200 */
};
-static void sio2_setup(uint8_t minor, uint8_t flags)
+static void sio2_setup(uint_fast8_t minor, uint_fast8_t flags)
{
struct termios *t = &ttydata[minor].termios;
uint8_t r;
sio_r[5] = 0x8A | ((t->c_cflag & CSIZE) << 1);
}
-void tty_setup(uint8_t minor, uint8_t flags)
+void tty_setup(uint_fast8_t minor, uint_fast8_t flags)
{
if (sio_present) {
sio2_setup(minor, flags);
}
}
-int tty_carrier(uint8_t minor)
+int tty_carrier(uint_fast8_t minor)
{
uint8_t c;
uint8_t port;
}
}
-void tty_putc(uint8_t minor, unsigned char c)
+void tty_putc(uint_fast8_t minor, uint_fast8_t c)
{
if (acia_present)
SIOA_D = c;
}
}
-void tty_sleeping(uint8_t minor)
+void tty_sleeping(uint_fast8_t minor)
{
sleeping |= (1 << minor);
}
Need to review this we should be ok as the IRQ handler always leaves
us pointing at RR0 */
-ttyready_t tty_writeready(uint8_t minor)
+ttyready_t tty_writeready(uint_fast8_t minor)
{
irqflags_t irq;
uint8_t c;
return TTY_READY_SOON;
}
-void tty_data_consumed(uint8_t minor)
+void tty_data_consumed(uint_fast8_t minor)
{
used(minor);
}
/* kernel writes to system console -- never sleep! */
-void kputchar(char c)
+void kputchar(uint_fast8_t c)
{
while(tty_writeready(TTYDEV - 512) != TTY_READY_NOW);
if (c == '\n')
tty_putc(TTYDEV - 512, c);
}
-int rctty_open(uint8_t minor, uint16_t flag)
+int rctty_open(uint_fast8_t minor, uint16_t flag)
{
if (acia_present && minor != 1) {
udata.u_error = ENODEV;
#ifndef __DEVTTY_DOT_H__
#define __DEVTTY_DOT_H__
-void tty_putc(uint8_t minor, unsigned char c);
+void tty_putc(uint_fast8_t minor, uint_fast8_t c);
void tty_pollirq_sio0(void);
void tty_pollirq_sio1(void);
void tty_pollirq_acia(void);
-int rctty_open(uint8_t minor, uint16_t flag);
+int rctty_open(uint_fast8_t minor, uint16_t flag);
#endif