ia64/xen-unstable

changeset 4989:bdc5114b6f20

bitkeeper revision 1.1454 (428b74f28LLau4r-iQuz14PpSU28DA)

Manual merge.
author kaf24@firebug.cl.cam.ac.uk
date Wed May 18 17:01:38 2005 +0000 (2005-05-18)
parents 6dbad1e6c50c aa22e2575a10
children 60da48aa3edc
files xen/drivers/char/console.c
line diff
     1.1 --- a/xen/drivers/char/console.c	Wed May 18 16:36:50 2005 +0000
     1.2 +++ b/xen/drivers/char/console.c	Wed May 18 17:01:38 2005 +0000
     1.3 @@ -263,15 +263,13 @@ static void switch_serial_input(void)
     1.4  static void __serial_rx(unsigned char c, struct cpu_user_regs *regs)
     1.5  {
     1.6      if ( xen_rx )
     1.7 -    {
     1.8 -        handle_keypress(c, regs);
     1.9 -    }
    1.10 -    else if ( (serial_rx_prod-serial_rx_cons) != SERIAL_RX_SIZE )
    1.11 -    {
    1.12 -        serial_rx_ring[SERIAL_RX_MASK(serial_rx_prod)] = c;
    1.13 -        if ( serial_rx_prod++ == serial_rx_cons )
    1.14 -            send_guest_virq(dom0->exec_domain[0], VIRQ_CONSOLE);
    1.15 -    }
    1.16 +        return handle_keypress(c, regs);
    1.17 +
    1.18 +    /* Deliver input to guest buffer, unless it is already full. */
    1.19 +    if ( (serial_rx_prod-serial_rx_cons) != SERIAL_RX_SIZE )
    1.20 +        serial_rx_ring[SERIAL_RX_MASK(serial_rx_prod++)] = c;
    1.21 +    /* Always notify the guest: prevents receive path from getting stuck. */
    1.22 +    send_guest_virq(dom0->exec_domain[0], VIRQ_CONSOLE);
    1.23  }
    1.24  
    1.25  static void serial_rx(unsigned char c, struct cpu_user_regs *regs)