search for: send_sigio_to_port

Displaying 15 results from an estimated 15 matches for "send_sigio_to_port".

2013 Jul 25
0
[PATCH v3 8/9] virtio: console: fix locking around send_sigio_to_port()
send_sigio_to_port() checks the value of guest_connected, which we always modify under the inbuf_lock; make sure invocations of send_sigio_to_port() have take the inbuf_lock around the call. Signed-off-by: Amit Shah <amit.shah at redhat.com> --- drivers/char/virtio_console.c | 8 +++++--- 1 file changed, 5 in...
2013 Jul 25
18
[PATCH v3 0/9] virtio: console: fixes for bugs and races with unplug
...time of unplug virtio: console: fix raising SIGIO after port unplug virtio: console: return -ENODEV on all read operations after unplug virtio: console: add locks around buffer removal in port unplug path virtio: console: add locking in port unplug path virtio: console: fix locking around send_sigio_to_port() virtio: console: prevent use-after-free of port name in port unplug drivers/char/virtio_console.c | 64 +++++++++++++++++++++++++++---------------- 1 file changed, 40 insertions(+), 24 deletions(-) -- 1.8.1.4
2013 Jul 25
18
[PATCH v3 0/9] virtio: console: fixes for bugs and races with unplug
...time of unplug virtio: console: fix raising SIGIO after port unplug virtio: console: return -ENODEV on all read operations after unplug virtio: console: add locks around buffer removal in port unplug path virtio: console: add locking in port unplug path virtio: console: fix locking around send_sigio_to_port() virtio: console: prevent use-after-free of port name in port unplug drivers/char/virtio_console.c | 64 +++++++++++++++++++++++++++---------------- 1 file changed, 40 insertions(+), 24 deletions(-) -- 1.8.1.4
2013 Jul 19
12
[PATCH v2 00/11] virtio: console: fixes for port unplug
...successful open virtio: console: fix race in port_fops_poll() and port unplug virtio: console: fix raising SIGIO after port unplug virtio: console: add locks around buffer removal in port unplug path virtio: console: add locking in port unplug path virtio: console: fix locking around send_sigio_to_port() virtio: console: prevent use-after-free of port name in port unplug drivers/char/virtio_console.c | 70 +++++++++++++++++++++++++++---------------- 1 file changed, 45 insertions(+), 25 deletions(-) -- 1.8.1.4
2013 Jul 19
12
[PATCH v2 00/11] virtio: console: fixes for port unplug
...successful open virtio: console: fix race in port_fops_poll() and port unplug virtio: console: fix raising SIGIO after port unplug virtio: console: add locks around buffer removal in port unplug path virtio: console: add locking in port unplug path virtio: console: fix locking around send_sigio_to_port() virtio: console: prevent use-after-free of port name in port unplug drivers/char/virtio_console.c | 70 +++++++++++++++++++++++++++---------------- 1 file changed, 45 insertions(+), 25 deletions(-) -- 1.8.1.4
2010 Sep 02
4
[PATCH 0/3] virtio: console: async notifications for host connect / disconnect
Hey Rusty, This patchset is on top of the previous one. It sends a SIGIO signal to apps that request signals for host activity. SIGIO is sent on host connect, disconnect as well as hot-unplug (which can be seen as a special case of host disconnect). Tested using several testcases in the test-virtserial repo: http://fedorapeople.org/gitweb?p=amitshah/public_git/test-virtserial.git Please apply.
2010 Sep 02
4
[PATCH 0/3] virtio: console: async notifications for host connect / disconnect
Hey Rusty, This patchset is on top of the previous one. It sends a SIGIO signal to apps that request signals for host activity. SIGIO is sent on host connect, disconnect as well as hot-unplug (which can be seen as a special case of host disconnect). Tested using several testcases in the test-virtserial repo: http://fedorapeople.org/gitweb?p=amitshah/public_git/test-virtserial.git Please apply.
2013 Jul 25
0
[PATCH v3 4/9] virtio: console: fix raising SIGIO after port unplug
SIGIO should be sent when a port gets unplugged. It should only be sent to prcesses that have the port opened, and have asked for SIGIO to be delivered. We were clearing out guest_connected before calling send_sigio_to_port(), resulting in a sigio not getting sent to processes. Fix by setting guest_connected to false after invoking the sigio function. CC: <stable at vger.kernel.org> Signed-off-by: Amit Shah <amit.shah at redhat.com> --- drivers/char/virtio_console.c | 8 +++++--- 1 file changed, 5 inser...
2013 Jul 18
16
[PATCH 00/10] virtio: console: fixes for races with port unplug
...successful open virtio: console: fix race in port_fops_poll() and port unplug virtio: console: fix raising SIGIO after port unplug virtio: console: add locks around buffer removal in port unplug path virtio: console: add locking in port unplug path virtio: console: fix locking around send_sigio_to_port() drivers/char/virtio_console.c | 67 ++++++++++++++++++++++++++++--------------- 1 file changed, 44 insertions(+), 23 deletions(-) -- 1.8.1.4
2013 Jul 18
16
[PATCH 00/10] virtio: console: fixes for races with port unplug
...successful open virtio: console: fix race in port_fops_poll() and port unplug virtio: console: fix raising SIGIO after port unplug virtio: console: add locks around buffer removal in port unplug path virtio: console: add locking in port unplug path virtio: console: fix locking around send_sigio_to_port() drivers/char/virtio_console.c | 67 ++++++++++++++++++++++++++++--------------- 1 file changed, 44 insertions(+), 23 deletions(-) -- 1.8.1.4
2012 Feb 01
1
[PATCH 2/2] virtio-serial: setup_port_vq when adding port
...> 1 files changed, 61 insertions(+), 4 deletions(-) > > diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c > index 8e3c46d..2e5187e 100644 > --- a/drivers/char/virtio_console.c > +++ b/drivers/char/virtio_console.c > @@ -1132,6 +1132,55 @@ static void send_sigio_to_port(struct port *port) > kill_fasync(&port->async_queue, SIGIO, POLL_OUT); > } > > +static void in_intr(struct virtqueue *vq); > +static void out_intr(struct virtqueue *vq); > + > +static int setup_port_vq(struct ports_device *portdev, u32 id) > +{ > + int err,...
2012 Feb 01
1
[PATCH 2/2] virtio-serial: setup_port_vq when adding port
...> 1 files changed, 61 insertions(+), 4 deletions(-) > > diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c > index 8e3c46d..2e5187e 100644 > --- a/drivers/char/virtio_console.c > +++ b/drivers/char/virtio_console.c > @@ -1132,6 +1132,55 @@ static void send_sigio_to_port(struct port *port) > kill_fasync(&port->async_queue, SIGIO, POLL_OUT); > } > > +static void in_intr(struct virtqueue *vq); > +static void out_intr(struct virtqueue *vq); > + > +static int setup_port_vq(struct ports_device *portdev, u32 id) > +{ > + int err,...
2013 Jul 25
0
[PATCH v3 7/9] virtio: console: add locking in port unplug path
...tio_console.c @@ -1541,6 +1541,7 @@ static void unplug_port(struct port *port) list_del(&port->list); spin_unlock_irq(&port->portdev->ports_lock); + spin_lock_irq(&port->inbuf_lock); if (port->guest_connected) { /* Let the app know the port is going down. */ send_sigio_to_port(port); @@ -1551,6 +1552,7 @@ static void unplug_port(struct port *port) wake_up_interruptible(&port->waitqueue); } + spin_unlock_irq(&port->inbuf_lock); if (is_console_port(port)) { spin_lock_irq(&pdrvdata_lock); -- 1.8.1.4
2015 May 08
2
[patch] virtio_console: use snprintf() for safety
...snprintf() as well. Signed-off-by: Dan Carpenter <dan.carpenter at oracle.com> diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 50754d20..8283989 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1389,7 +1389,7 @@ static void send_sigio_to_port(struct port *port) static int add_port(struct ports_device *portdev, u32 id) { - char debugfs_name[16]; + char debugfs_name[28]; struct port *port; struct port_buffer *buf; dev_t devt; @@ -1492,8 +1492,8 @@ static int add_port(struct ports_device *portdev, u32 id) * Finally, create th...
2015 May 08
2
[patch] virtio_console: use snprintf() for safety
...snprintf() as well. Signed-off-by: Dan Carpenter <dan.carpenter at oracle.com> diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 50754d20..8283989 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1389,7 +1389,7 @@ static void send_sigio_to_port(struct port *port) static int add_port(struct ports_device *portdev, u32 id) { - char debugfs_name[16]; + char debugfs_name[28]; struct port *port; struct port_buffer *buf; dev_t devt; @@ -1492,8 +1492,8 @@ static int add_port(struct ports_device *portdev, u32 id) * Finally, create th...