virtio: console: Send SIGIO on new data arrival on ports
authorAmit Shah <amit.shah@redhat.com>
Thu, 2 Sep 2010 13:17:53 +0000 (18:47 +0530)
committerRusty Russell <rusty@rustcorp.com.au>
Thu, 21 Oct 2010 07:14:04 +0000 (17:44 +1030)
Send a SIGIO signal when new data arrives on a port. This is sent only
when the process has requested for the signal to be sent using fcntl().

Signed-off-by: Amit Shah <amit.shah@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
drivers/char/virtio_console.c

index c4ca436942339da8f8ff5433f5b7c497fa0b636f..6d5c579b1693d1663d46639e60eef07cc3eb20e8 100644 (file)
@@ -1483,6 +1483,9 @@ static void in_intr(struct virtqueue *vq)
 
        wake_up_interruptible(&port->waitqueue);
 
+       /* Send a SIGIO indicating new data in case the process asked for it */
+       send_sigio_to_port(port);
+
        if (is_console_port(port) && hvc_poll(port->cons.hvc))
                hvc_kick();
 }