search for: pdrvdata_lock

Displaying 20 results from an estimated 28 matches for "pdrvdata_lock".

2011 Nov 08
3
[PATCH RFC v2 0/3] Support multiple VirtioConsoles.
(Amit pointed out that the patches never went out. This is a resend of the series meant to go out on 11/2/2011; I've marked it "v2".) This patchset applies to linux-next/next-20111102. This series implements support for multiple virtio_consoles using KVM. This patchset addresses several issues associated with trying to establish multiple virtio consoles. I'm trying to
2011 Nov 08
3
[PATCH RFC v2 0/3] Support multiple VirtioConsoles.
(Amit pointed out that the patches never went out. This is a resend of the series meant to go out on 11/2/2011; I've marked it "v2".) This patchset applies to linux-next/next-20111102. This series implements support for multiple virtio_consoles using KVM. This patchset addresses several issues associated with trying to establish multiple virtio consoles. I'm trying to
2011 Nov 08
3
[PATCH RFC v3 0/3] Support multiple VirtioConsoles.
(Amit pointed out that the patches never went out. This was a resend of the series meant to go out on 11/2/2011; Now it's a resend of the mail this morning, with everyone copied on the same mail. So sorry for the spam! This is v3.) This patchset applies to linux-next/next-20111102. This series implements support for multiple virtio_consoles using KVM. This patchset addresses several issues
2011 Nov 08
3
[PATCH RFC v3 0/3] Support multiple VirtioConsoles.
(Amit pointed out that the patches never went out. This was a resend of the series meant to go out on 11/2/2011; Now it's a resend of the mail this morning, with everyone copied on the same mail. So sorry for the spam! This is v3.) This patchset applies to linux-next/next-20111102. This series implements support for multiple virtio_consoles using KVM. This patchset addresses several issues
2011 Nov 08
3
[PATCH RFC v3 0/3] Support multiple VirtioConsoles.
(Amit pointed out that the patches never went out. This was a resend of the series meant to go out on 11/2/2011; Now it's a resend of the mail this morning, with everyone copied on the same mail. So sorry for the spam! This is v3.) This patchset applies to linux-next/next-20111102. This series implements support for multiple virtio_consoles using KVM. This patchset addresses several issues
2011 Nov 08
3
[PATCH RFC v2 0/3] Support multiple VirtioConsoles.
(Amit pointed out that the patches never went out. This is a resend of the series meant to go out on 11/2/2011; I''ve marked it "v2".) This patchset applies to linux-next/next-20111102. This series implements support for multiple virtio_consoles using KVM. This patchset addresses several issues associated with trying to establish multiple virtio consoles. I''m
2013 Jan 17
4
[PATCH] virtio_console: Use virtio device index to generate port name
...ortdev->vdev->index, id); port->debugfs_file = debugfs_create_file(debugfs_name, 0444, pdrvdata.debugfs_dir, port, @@ -1961,16 +1955,12 @@ static int virtcons_probe(struct virtio_device *vdev) portdev->vdev = vdev; vdev->priv = portdev; - spin_lock_irq(&pdrvdata_lock); - portdev->drv_index = pdrvdata.index++; - spin_unlock_irq(&pdrvdata_lock); - portdev->chr_major = register_chrdev(0, "virtio-portsdev", &portdev_fops); if (portdev->chr_major < 0) { dev_err(&vdev->dev, "Error %d registering chrdev f...
2013 Jan 17
4
[PATCH] virtio_console: Use virtio device index to generate port name
...ortdev->vdev->index, id); port->debugfs_file = debugfs_create_file(debugfs_name, 0444, pdrvdata.debugfs_dir, port, @@ -1961,16 +1955,12 @@ static int virtcons_probe(struct virtio_device *vdev) portdev->vdev = vdev; vdev->priv = portdev; - spin_lock_irq(&pdrvdata_lock); - portdev->drv_index = pdrvdata.index++; - spin_unlock_irq(&pdrvdata_lock); - portdev->chr_major = register_chrdev(0, "virtio-portsdev", &portdev_fops); if (portdev->chr_major < 0) { dev_err(&vdev->dev, "Error %d registering chrdev f...
2010 Sep 02
14
[PATCH 00/14] virtio: console: Hot-unplug fixes
Hey Rusty, These are the patches that rework a few bits to make hot-unplug while ports are open not crash apps (or kernels). The problem is when hot-unplug is performed when a port is open, the cdev struct is kept around by the file pointers and when the app later does a 'close', things go boom-boom. This patch series makes sure port as well as device hot-unplug is now safe to perform
2010 Sep 02
14
[PATCH 00/14] virtio: console: Hot-unplug fixes
Hey Rusty, These are the patches that rework a few bits to make hot-unplug while ports are open not crash apps (or kernels). The problem is when hot-unplug is performed when a port is open, the cdev struct is kept around by the file pointers and when the app later does a 'close', things go boom-boom. This patch series makes sure port as well as device hot-unplug is now safe to perform
2011 Mar 14
1
[PATCH] virtio: console: Enable call to hvc_remove() on console port remove
...0 insertions(+), 11 deletions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 84b164d..838568a 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1280,18 +1280,7 @@ static void unplug_port(struct port *port) spin_lock_irq(&pdrvdata_lock); list_del(&port->cons.list); spin_unlock_irq(&pdrvdata_lock); -#if 0 - /* - * hvc_remove() not called as removing one hvc port - * results in other hvc ports getting frozen. - * - * Once this is resolved in hvc, this functionality - * will be enabled. Till that is done...
2011 Mar 14
1
[PATCH] virtio: console: Enable call to hvc_remove() on console port remove
...0 insertions(+), 11 deletions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 84b164d..838568a 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1280,18 +1280,7 @@ static void unplug_port(struct port *port) spin_lock_irq(&pdrvdata_lock); list_del(&port->cons.list); spin_unlock_irq(&pdrvdata_lock); -#if 0 - /* - * hvc_remove() not called as removing one hvc port - * results in other hvc ports getting frozen. - * - * Once this is resolved in hvc, this functionality - * will be enabled. Till that is done...
2013 Apr 06
2
[PATCH -next] virtio_console: make local symbols static
...letions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 13ad9b1..f73ad64 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -78,8 +78,8 @@ struct ports_driver_data { }; static struct ports_driver_data pdrvdata; -DEFINE_SPINLOCK(pdrvdata_lock); -DECLARE_COMPLETION(early_console_added); +static DEFINE_SPINLOCK(pdrvdata_lock); +static DECLARE_COMPLETION(early_console_added); /* This struct holds information that's relevant only for console ports */ struct console { @@ -1202,7 +1202,7 @@ int __init virtio_cons_early_init(int (*put_...
2013 Apr 06
2
[PATCH -next] virtio_console: make local symbols static
...letions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 13ad9b1..f73ad64 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -78,8 +78,8 @@ struct ports_driver_data { }; static struct ports_driver_data pdrvdata; -DEFINE_SPINLOCK(pdrvdata_lock); -DECLARE_COMPLETION(early_console_added); +static DEFINE_SPINLOCK(pdrvdata_lock); +static DECLARE_COMPLETION(early_console_added); /* This struct holds information that's relevant only for console ports */ struct console { @@ -1202,7 +1202,7 @@ int __init virtio_cons_early_init(int (*put_...
2018 Apr 20
13
[PATCH 0/6] virtio-console: spec compliance fixes
Turns out virtio console tries to take a buffer out of an active vq. Works by sheer luck, and is explicitly forbidden by spec. And while going over it I saw that error handling is also broken - failure is easy to trigger if I force allocations to fail. Lightly tested. Michael S. Tsirkin (6): virtio_console: don't tie bufs to a vq virtio: add ability to iterate over vqs virtio_console:
2018 Apr 20
13
[PATCH 0/6] virtio-console: spec compliance fixes
Turns out virtio console tries to take a buffer out of an active vq. Works by sheer luck, and is explicitly forbidden by spec. And while going over it I saw that error handling is also broken - failure is easy to trigger if I force allocations to fail. Lightly tested. Michael S. Tsirkin (6): virtio_console: don't tie bufs to a vq virtio: add ability to iterate over vqs virtio_console:
2019 Mar 19
0
[PATCH] virtio_console: initialize vtermno value for ports
...b/drivers/char/virtio_console.c @@ -75,7 +75,7 @@ struct ports_driver_data { /* All the console devices handled by this driver */ struct list_head consoles; }; -static struct ports_driver_data pdrvdata; +static struct ports_driver_data pdrvdata = { .next_vtermno = 1}; static DEFINE_SPINLOCK(pdrvdata_lock); static DECLARE_COMPLETION(early_console_added); @@ -1394,6 +1394,7 @@ static int add_port(struct ports_device *portdev, u32 id) port->async_queue = NULL; port->cons.ws.ws_row = port->cons.ws.ws_col = 0; + port->cons.vtermno = 0; port->host_connected = port->guest_conn...
2010 Mar 23
0
[PATCH 09/11] virtio: console: Don't always create a port 0 if using multiport
...d, 15 insertions(+), 17 deletions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 4087248..7d45fcc 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -784,6 +784,13 @@ int init_port_console(struct port *port) spin_unlock_irq(&pdrvdata_lock); port->guest_connected = true; + /* + * Start using the new console output if this is the first + * console to come up. + */ + if (early_put_chars) + early_put_chars = NULL; + /* Notify host of port being opened */ send_control_msg(port, VIRTIO_CONSOLE_PORT_OPEN, 1); @@ -1056,14 +...
2010 Mar 23
0
[PATCH 09/11] virtio: console: Don't always create a port 0 if using multiport
...d, 15 insertions(+), 17 deletions(-) diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index 4087248..7d45fcc 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -784,6 +784,13 @@ int init_port_console(struct port *port) spin_unlock_irq(&pdrvdata_lock); port->guest_connected = true; + /* + * Start using the new console output if this is the first + * console to come up. + */ + if (early_put_chars) + early_put_chars = NULL; + /* Notify host of port being opened */ send_control_msg(port, VIRTIO_CONSOLE_PORT_OPEN, 1); @@ -1056,14 +...
2013 Jul 25
0
[PATCH v3 7/9] virtio: console: add locking in port unplug path
.../* 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