search for: max_nr_port

Displaying 20 results from an estimated 94 matches for "max_nr_port".

Did you mean: max_nr_ports
2016 Dec 06
0
[PATCH 01/10] virtio_console: drop unused config fields
struct ports_device includes a config field including the whole virtio_console_config, but only max_nr_ports in there is ever updated or used. The rest is unused and in fact does not even mirror the device config. Drop everything except max_nr_ports, saving some memory. Signed-off-by: Michael S. Tsirkin <mst at redhat.com> --- drivers/char/virtio_console.c | 14 +++++++------- 1 file changed, 7 i...
2010 Mar 30
3
[PATCH 4/4] virtio: disable multiport console support.
...-removed earlier, we call - * add_port to add the port. - */ - struct port *port; - - port = find_port_by_id(portdev, 0); - if (!port) - add_port(portdev, 0); - else - send_control_msg(port, VIRTIO_CONSOLE_PORT_READY, 1); - return; - } - if (virtconconf.nr_ports > portdev->config.max_nr_ports) { - dev_warn(&vdev->dev, - "More ports specified (%u) than allowed (%u)", - portdev->config.nr_ports + 1, - portdev->config.max_nr_ports); - return; - } - if (virtconconf.nr_ports < portdev->config.nr_ports) - return; - - /* Hot-add ports */ - while (virtc...
2010 Mar 30
3
[PATCH 4/4] virtio: disable multiport console support.
...-removed earlier, we call - * add_port to add the port. - */ - struct port *port; - - port = find_port_by_id(portdev, 0); - if (!port) - add_port(portdev, 0); - else - send_control_msg(port, VIRTIO_CONSOLE_PORT_READY, 1); - return; - } - if (virtconconf.nr_ports > portdev->config.max_nr_ports) { - dev_warn(&vdev->dev, - "More ports specified (%u) than allowed (%u)", - portdev->config.nr_ports + 1, - portdev->config.max_nr_ports); - return; - } - if (virtconconf.nr_ports < portdev->config.nr_ports) - return; - - /* Hot-add ports */ - while (virtc...
2011 Aug 14
2
[PATCH 1/3] virtio-console: Use virtio_config_val() for retrieving config
...t a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index fb68b12..ed99f3b 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1675,13 +1675,11 @@ static int __devinit virtcons_probe(struct virtio_device *vdev) multiport = false; portdev->config.max_nr_ports = 1; - if (virtio_has_feature(vdev, VIRTIO_CONSOLE_F_MULTIPORT)) { + if (virtio_config_val(vdev, VIRTIO_CONSOLE_F_MULTIPORT, + offsetof(struct virtio_console_config, + max_nr_ports), + &portdev->config.max_nr_ports) == 0) multiport = true; - vdev->config-&gt...
2011 Aug 14
2
[PATCH 1/3] virtio-console: Use virtio_config_val() for retrieving config
...t a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c index fb68b12..ed99f3b 100644 --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1675,13 +1675,11 @@ static int __devinit virtcons_probe(struct virtio_device *vdev) multiport = false; portdev->config.max_nr_ports = 1; - if (virtio_has_feature(vdev, VIRTIO_CONSOLE_F_MULTIPORT)) { + if (virtio_config_val(vdev, VIRTIO_CONSOLE_F_MULTIPORT, + offsetof(struct virtio_console_config, + max_nr_ports), + &portdev->config.max_nr_ports) == 0) multiport = true; - vdev->config-&gt...
2012 Sep 19
2
[PATCHv2] virtio_console: Add support for remoteproc serial
.../ -static int __devinit virtcons_probe(struct virtio_device *vdev) +static int virtcons_probe(struct virtio_device *vdev) { struct ports_device *portdev; int err; @@ -1724,10 +1804,12 @@ static int __devinit virtcons_probe(struct virtio_device *vdev) multiport = false; portdev->config.max_nr_ports = 1; - if (virtio_config_val(vdev, VIRTIO_CONSOLE_F_MULTIPORT, - offsetof(struct virtio_console_config, - max_nr_ports), - &portdev->config.max_nr_ports) == 0) + if (is_rproc_serial(vdev)) + multiport = false; + else if (virtio_config_val(vdev, VIRTIO_CONSOLE_F_MU...
2012 Sep 19
2
[PATCHv2] virtio_console: Add support for remoteproc serial
.../ -static int __devinit virtcons_probe(struct virtio_device *vdev) +static int virtcons_probe(struct virtio_device *vdev) { struct ports_device *portdev; int err; @@ -1724,10 +1804,12 @@ static int __devinit virtcons_probe(struct virtio_device *vdev) multiport = false; portdev->config.max_nr_ports = 1; - if (virtio_config_val(vdev, VIRTIO_CONSOLE_F_MULTIPORT, - offsetof(struct virtio_console_config, - max_nr_ports), - &portdev->config.max_nr_ports) == 0) + if (is_rproc_serial(vdev)) + multiport = false; + else if (virtio_config_val(vdev, VIRTIO_CONSOLE_F_MU...
2016 Dec 06
26
[PATCH 00/10] virtio: sparse fixes
I run latest sparse from git on virtio drivers (turns out the version I had was rather outdated). This patchset fixes a couple of bugs this uncovered, and adds some annotations to make it sparse-clean. In particular, endian-ness is often tricky, so this patchset enabled endian-ness checks for sparse builds. Michael S. Tsirkin (10): virtio_console: drop unused config fields drm/virtio: fix
2016 Dec 06
26
[PATCH 00/10] virtio: sparse fixes
I run latest sparse from git on virtio drivers (turns out the version I had was rather outdated). This patchset fixes a couple of bugs this uncovered, and adds some annotations to make it sparse-clean. In particular, endian-ness is often tricky, so this patchset enabled endian-ness checks for sparse builds. Michael S. Tsirkin (10): virtio_console: drop unused config fields drm/virtio: fix
2009 Aug 05
0
[PATCH] virtio_serial: A char device for simple guest <-> host communication
...chedule_work(&virtserial.tx_work); +} + +static void config_intr(struct virtio_device *vdev) +{ + schedule_work(&virtserial.config_work); +} + +static u32 virtserial_get_hot_add_port(struct virtio_serial_config *config) +{ + u32 i; + u32 port_nr; + + for (i = 0; i < virtserial.config->max_nr_ports / 32; i++) { + port_nr = ffs(config->ports_map[i] ^ virtserial.config->ports_map[i]); + if (port_nr) + break; + } + if (unlikely(!port_nr)) + return VIRTIO_SERIAL_BAD_ID; + + /* We used ffs above */ + port_nr--; + + /* FIXME: Do this only when add_port is successful */ + virtserial.conf...
2009 Aug 05
0
[PATCH] virtio_serial: A char device for simple guest <-> host communication
...chedule_work(&virtserial.tx_work); +} + +static void config_intr(struct virtio_device *vdev) +{ + schedule_work(&virtserial.config_work); +} + +static u32 virtserial_get_hot_add_port(struct virtio_serial_config *config) +{ + u32 i; + u32 port_nr; + + for (i = 0; i < virtserial.config->max_nr_ports / 32; i++) { + port_nr = ffs(config->ports_map[i] ^ virtserial.config->ports_map[i]); + if (port_nr) + break; + } + if (unlikely(!port_nr)) + return VIRTIO_SERIAL_BAD_ID; + + /* We used ffs above */ + port_nr--; + + /* FIXME: Do this only when add_port is successful */ + virtserial.conf...
2010 Apr 08
3
[PATCH 00/11] (v6) virtio: console: Fixes, new way of discovering ports
Hello, This series reworks the ABI to allow port discovery (only) via the control queue and enable multiport again. In addition, it adds support for non-blocking write() support, which means no spinning. This works fine with the recent patches that are on qemu-devel. Also included is removal of hvc_remove() as removing one such console port causes other console ports (registered with hvc) to
2010 Apr 08
3
[PATCH 00/11] (v6) virtio: console: Fixes, new way of discovering ports
Hello, This series reworks the ABI to allow port discovery (only) via the control queue and enable multiport again. In addition, it adds support for non-blocking write() support, which means no spinning. This works fine with the recent patches that are on qemu-devel. Also included is removal of hvc_remove() as removing one such console port causes other console ports (registered with hvc) to
2010 Mar 19
2
[PATCH 0/9] virtio-serial fixes, ABI updates
Hello, This series fixes a few issues pointed out by Avi and Juan. Avi pointed out we should do full scatter/gather processing of guest data even if current (well-behaved) guests don't send multiple iovs per element. Juan pointed out a few migration-related bugs. In handling the migration fixes, I noticed hot-plug/unplug isn't handled perfectly for the migration case: ports are
2010 Mar 19
2
[PATCH 0/9] virtio-serial fixes, ABI updates
Hello, This series fixes a few issues pointed out by Avi and Juan. Avi pointed out we should do full scatter/gather processing of guest data even if current (well-behaved) guests don't send multiple iovs per element. Juan pointed out a few migration-related bugs. In handling the migration fixes, I noticed hot-plug/unplug isn't handled perfectly for the migration case: ports are
2009 Jul 27
3
virtio-serial: An interface for host-guest communication
Hello all, This are the latest version of the patches. Lots of things have changed since the last submission. A few of which I remember: - VNC copy / paste works* (* conditions apply) - client vnc copies get propagated to guest port 3 (/dev/vmch3) - guest writes to port 3 (/dev/vmch3) go straight to client's clipboard - sysfs hooks to autodiscover ports - support for 64 ports in this
2009 Jul 27
3
virtio-serial: An interface for host-guest communication
Hello all, This are the latest version of the patches. Lots of things have changed since the last submission. A few of which I remember: - VNC copy / paste works* (* conditions apply) - client vnc copies get propagated to guest port 3 (/dev/vmch3) - guest writes to port 3 (/dev/vmch3) go straight to client's clipboard - sysfs hooks to autodiscover ports - support for 64 ports in this
2011 Mar 09
1
[PATCH] virtio console: don't manually set or finalize VIRTIO_CONSOLE_F_MULTIPORT.
...com Signed-off-by: Rusty Russell <rusty at rustcorp.com.au> diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1680,17 +1680,12 @@ static int __devinit virtcons_probe(stru portdev->config.max_nr_ports = 1; if (virtio_has_feature(vdev, VIRTIO_CONSOLE_F_MULTIPORT)) { multiport = true; - vdev->features[0] |= 1 << VIRTIO_CONSOLE_F_MULTIPORT; - vdev->config->get(vdev, offsetof(struct virtio_console_config, max_nr_ports), &portdev->config.max_nr_ports,...
2011 Mar 09
1
[PATCH] virtio console: don't manually set or finalize VIRTIO_CONSOLE_F_MULTIPORT.
...com Signed-off-by: Rusty Russell <rusty at rustcorp.com.au> diff --git a/drivers/char/virtio_console.c b/drivers/char/virtio_console.c --- a/drivers/char/virtio_console.c +++ b/drivers/char/virtio_console.c @@ -1680,17 +1680,12 @@ static int __devinit virtcons_probe(stru portdev->config.max_nr_ports = 1; if (virtio_has_feature(vdev, VIRTIO_CONSOLE_F_MULTIPORT)) { multiport = true; - vdev->features[0] |= 1 << VIRTIO_CONSOLE_F_MULTIPORT; - vdev->config->get(vdev, offsetof(struct virtio_console_config, max_nr_ports), &portdev->config.max_nr_ports,...
2013 May 20
1
[PATCH] virtio-spec: tweak wording for console control vq
...iff --git a/virtio-spec.lyx b/virtio-spec.lyx index 921388b..3ef96a9 100644 --- a/virtio-spec.lyx +++ b/virtio-spec.lyx @@ -6833,8 +6833,13 @@ VIRTIO_CONSOLE_F_SIZE \begin_layout Description VIRTIO_CONSOLE_F_MULTIPORT(1) Device has support for multiple ports; configurati -on fields nr_ports and max_nr_ports are valid and control virtqueues will - be used. +on fields nr_ports and max_nr_ports are valid +\change_inserted 1986246365 1347188404 +; if this bit is negotiated, +\change_deleted 1986246365 1347188406 + and +\change_unchanged + control virtqueues will be used. \change_inserted 1112500848 1368...