static int fifo_put(SerialState *s, int fifo, uint8_t chr)

{

    SerialFIFO *f = (fifo) ? &s->recv_fifo : &s->xmit_fifo;



    f->data[f->head++] = chr;



    if (f->head == UART_FIFO_LENGTH)

        f->head = 0;

    f->count++;



    return 1;

}

static int fifo_put(SerialState *s, int fifo, uint8_t chr)

{

    SerialFIFO *f = (fifo) ? &s->recv_fifo : &s->xmit_fifo;



    f->data[f->head++] = chr;



    if (f->head == UART_FIFO_LENGTH)

        f->head = 0;

    f->count++;



    return 1;

}

    f->data[f->head++] = chr;     if (f->head == UART_FIFO_LENGTH)         f->head = 0;     f->count++;
static int FUNC_0(SerialState *VAR_0, int VAR_1, uint8_t VAR_2)

{

    SerialFIFO *f = (VAR_1) ? &VAR_0->recv_fifo : &VAR_0->xmit_fifo;



    f->data[f->head++] = VAR_2;



    if (f->head == UART_FIFO_LENGTH)

        f->head = 0;

    f->count++;



    return 1;

}

static int FUNC_0(SerialState *VAR_0, int VAR_1, uint8_t VAR_2)
{ SerialFIFO *f = (VAR_1) ? &VAR_0->recv_fifo : &VAR_0->xmit_fifo; f->data[f->head++] = VAR_2; if (f->head == UART_FIFO_LENGTH)
f->head = 0; f->count++; return 1; }