Rusty Russell writes:
> I'll create some patches and see if it's too ugly to live...
Hmm, with rough userspace testing I managed to get the speed penalty
pretty low.
Here are the two patches, inline:
vringh: handle case where data goes across multiple ranges.
QEMU seems to only use separate me
Rusty Russell writes:
> "Michael S. Tsirkin" writes:
>> On Mon, Jan 21, 2013 at 10:22:03PM +1030, Rusty Russell wrote:
>>> Rusty Russell writes:
>>> > "Michael S. Tsirkin" writes:
>>> >>> + iov->iov[iov->i].iov_base = (__force __user void *)addr;
>>> >>> + iov->iov[i
We can get all the pages in one time instead of calling
gup N times.
Signed-off-by: Asias He
---
drivers/vhost/tcm_vhost.c | 54 ++-
1 file changed, 30 insertions(+), 24 deletions(-)
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
i
Signed-off-by: Asias He
---
drivers/vhost/tcm_vhost.c | 8 +++-
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
index ca35c16..796a6b0 100644
--- a/drivers/vhost/tcm_vhost.c
+++ b/drivers/vhost/tcm_vhost.c
@@ -479,11 +479,9 @
Changes in v2:
- Use GFP_KERNEL instead of GFP_ATOMIC
- Handle pages pinned less than wanted
Asias He (3):
tcm_vhost: Introduce iov_num_pages
tcm_vhost: Use iov_num_pages to calculate sgl_count
tcm_vhost: Optimize gup in vhost_scsi_map_to_sgl
drivers/vhost/tcm_vhost.c | 68
Add a helper to calculate the number of pages needed for a iov entry.
Signed-off-by: Asias He
---
drivers/vhost/tcm_vhost.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
index 3720604..ca35c16 100644
--- a/drivers/vhost/tcm_vhost.
On 01/22/2013 02:57 AM, Marcelo Tosatti wrote:
> On Mon, Jan 21, 2013 at 04:05:27PM +0800, Asias He wrote:
>> We can get all the pages in one time instead of calling
>> gup N times.
>>
>> Signed-off-by: Asias He
>> ---
>> drivers/vhost/tcm_vhost.c | 33 -
>> 1 file
sjur.brandel...@stericsson.com writes:
> From: Sjur Brændeland
>
> Allow rproc serial ports to receive data before the port
> is connected.
>
> Rproc serial ports usually talk to very simple remote devices
> with no control queue managing open/close events. So we must
> let remote devices write to
"Michael S. Tsirkin" writes:
> On Mon, Jan 21, 2013 at 10:22:03PM +1030, Rusty Russell wrote:
>> Rusty Russell writes:
>> > "Michael S. Tsirkin" writes:
>> >>> +iov->iov[iov->i].iov_base = (__force __user void *)addr;
>> >>> +iov->iov[iov->i].iov_len = desc.len;
>
sjur.brandel...@stericsson.com writes:
> From: Sjur Brændeland
>
> Add information so rproc-serial can be easily recogniced
> from user space. Add the following information to uevent:
> DRIVER=virtio_console|virtio_rproc_serial
> INTERFACE=grand-parent/parent/name
>
> Signed-off-by: Sjur Brændela
Wanlong Gao writes:
> As Michael mentioned, set affinity and select queue will not work very
> well when CPU IDs are not consecutive, this can happen with hot unplug.
> Fix this bug by traversal the online CPUs, and create a per cpu variable
> to find the mapping from CPU to the preferable virtua
sjur.brandel...@stericsson.com writes:
> From: Sjur Brændeland
>
> Use virtio device index for creating unique device port names.
> Current index allocation in virtio is based on a monotonically
> increasing variable "index". A better handling of this is to
> use device index which is allocated by
sjur.brandel...@stericsson.com writes:
> From: Sjur Brændeland
>
> Don't access uninitialized work-queue when removing device.
> The work queue is initialized only if the device multi-queue.
> So don't call cancel_work unless this is a multi-queue device.
>
> This fixes the following panic:
Thank
On Mon, Jan 21, 2013 at 04:05:27PM +0800, Asias He wrote:
> We can get all the pages in one time instead of calling
> gup N times.
>
> Signed-off-by: Asias He
> ---
> drivers/vhost/tcm_vhost.c | 33 -
> 1 file changed, 20 insertions(+), 13 deletions(-)
>
> diff -
From: Amos Kong
Date: Mon, 21 Jan 2013 19:17:20 +0800
> Currenly mac is programmed byte by byte. This means that we
> have an intermediate step where mac is wrong.
>
> Third patch introduced a new vq control command to set mac
> address, it's atomic.
>
> V2: check return of sending command, de
On Sun, Jan 20, 2013 at 10:43:08AM +0800, ak...@redhat.com wrote:
> From: Stefan Hajnoczi
>
> When we set mac address, software mac address in system and hardware mac
> address all need to be updated. Current eth_mac_addr() doesn't allow
> callers to implement error handling nicely.
>
> This pat
On Sat, Jan 19, 2013 at 09:54:27AM +0800, ak...@redhat.com wrote:
> @@ -350,6 +351,18 @@ static int virtio_net_handle_mac(VirtIONet *n, uint8_t
> cmd,
> struct virtio_net_ctrl_mac mac_data;
> size_t s;
>
> +if (cmd == VIRTIO_NET_CTRL_MAC_ADDR_SET) {
> +if (iov_size(iov, iov
On Sat, Jan 19, 2013 at 09:54:26AM +0800, ak...@redhat.com wrote:
> From: "Michael S. Tsirkin"
>
> Virtio-net code makes assumption about virtqueue descriptor layout
> (e.g. sg[0] is the header, sg[1] is the data buffer).
>
> This patch makes code not rely on the layout of descriptors.
>
> Sign
"Nicholas A. Bellinger" writes:
> Hi MST & Co,
>
> On Thu, 2013-01-17 at 18:43 +0200, Michael S. Tsirkin wrote:
>> On Fri, Sep 07, 2012 at 06:48:14AM +, Nicholas A. Bellinger wrote:
>> > From: Nicholas Bellinger
>> >
>> > Hello Anthony & Co,
>> >
>> > This is the fourth installment to add
On Mon, Jan 21, 2013 at 10:22:03PM +1030, Rusty Russell wrote:
> Rusty Russell writes:
> > "Michael S. Tsirkin" writes:
> >>> + iov->iov[iov->i].iov_base = (__force __user void *)addr;
> >>> + iov->iov[iov->i].iov_len = desc.len;
> >>
> >> The following comment from the previous v
On Mon, Jan 21, 2013 at 02:24:31PM +0200, Michael S. Tsirkin wrote:
> On Mon, Jan 21, 2013 at 10:22:03PM +1030, Rusty Russell wrote:
> > Rusty Russell writes:
> > > "Michael S. Tsirkin" writes:
> > >>> + iov->iov[iov->i].iov_base = (__force __user void *)addr;
> > >>> +
"Michael S. Tsirkin" writes:
> On Thu, Jan 17, 2013 at 12:40:29PM +1030, Rusty Russell wrote:
>> I resist sprinkling __user everywhere because it's *not* always user
>> addresses, and it's deeply misleading to anyone reading it. I'd rather
>> have it in one place with a big comment.
>> I can try
Rusty Russell writes:
> "Michael S. Tsirkin" writes:
>>> + iov->iov[iov->i].iov_base = (__force __user void *)addr;
>>> + iov->iov[iov->i].iov_len = desc.len;
>>
>> The following comment from the previous version still applies:
>> > This looks like it won't do the right t
Add a cpu notifier to virtio-net, so that we can reset the
virtqueue affinity if the cpu hotplug happens. It improve
the performance through enabling or disabling the virtqueue
affinity after doing cpu hotplug.
Cc: Rusty Russell
Cc: "Michael S. Tsirkin"
Cc: Jason Wang
Cc: Eric Dumazet
Cc: virt
As Michael mentioned, set affinity and select queue will not work very
well when CPU IDs are not consecutive, this can happen with hot unplug.
Fix this bug by traversal the online CPUs, and create a per cpu variable
to find the mapping from CPU to the preferable virtual-queue.
Cc: Rusty Russell
C
Split out the clean affinity function to virtnet_clean_affinity().
Cc: Rusty Russell
Cc: "Michael S. Tsirkin"
Cc: Jason Wang
Cc: Eric Dumazet
Cc: virtualization@lists.linux-foundation.org
Cc: net...@vger.kernel.org
Signed-off-by: Wanlong Gao
---
V5->V6: NEW
drivers/net/virtio_net.c | 67 +++
Currently we write MAC address to pci config space byte by byte,
this means that we have an intermediate step where mac is wrong.
This patch introduced a new control command to set MAC address,
it's atomic.
VIRTIO_NET_F_CTRL_MAC_ADDR is a new feature bit for compatibility.
Signed-off-by: Amos Kon
From: Stefan Hajnoczi
When we set mac address, software mac address in system and hardware mac
address all need to be updated. Current eth_mac_addr() doesn't allow
callers to implement error handling nicely.
This patch split eth_mac_addr() to prepare part and real commit part,
then we can prepar
We want to send vq command to set mac address in
virtnet_set_mac_address(), so do this function moving.
Fixed a little issue of coding style.
Signed-off-by: Amos Kong
---
drivers/net/virtio_net.c | 89 ++---
1 files changed, 44 insertions(+), 45 deletion
Currenly mac is programmed byte by byte. This means that we
have an intermediate step where mac is wrong.
Third patch introduced a new vq control command to set mac
address, it's atomic.
V2: check return of sending command, delay eth_mac_addr()
V3: restore software address when fail to set hardw
On Mon, Jan 21, 2013 at 01:04:47PM +1030, Rusty Russell wrote:
> "Michael S. Tsirkin" writes:
> > On Thu, Jan 17, 2013 at 08:59:38PM +1030, Rusty Russell wrote:
> >> +/* Returns vring->num if empty, -ve on error. */
> >> +static inline int __vringh_get_head(const struct vringh *vrh,
> >> +
On Thu, Jan 17, 2013 at 01:07:21PM -0800, Nicholas A. Bellinger wrote:
> Hi MST & Co,
>
> On Thu, 2013-01-17 at 18:43 +0200, Michael S. Tsirkin wrote:
> > On Fri, Sep 07, 2012 at 06:48:14AM +, Nicholas A. Bellinger wrote:
> > > From: Nicholas Bellinger
> > >
> > > Hello Anthony & Co,
> > >
Signed-off-by: Asias He
---
drivers/vhost/tcm_vhost.c | 8 +++-
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
index 59be442..5b77469 100644
--- a/drivers/vhost/tcm_vhost.c
+++ b/drivers/vhost/tcm_vhost.c
@@ -487,11 +487,9 @
We can get all the pages in one time instead of calling
gup N times.
Signed-off-by: Asias He
---
drivers/vhost/tcm_vhost.c | 33 -
1 file changed, 20 insertions(+), 13 deletions(-)
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
index ca35c16..
Add a helper to calculate the number of pages needed for a iov entry.
Signed-off-by: Asias He
---
drivers/vhost/tcm_vhost.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
index 3720604..ca35c16 100644
--- a/drivers/vhost/tcm_vhost.
Asias He (3):
tcm_vhost: Introduce iov_num_pages
tcm_vhost: Optimize gup in vhost_scsi_map_to_sgl
tcm_vhost: Use iov_num_pages to calculate sgl_count
drivers/vhost/tcm_vhost.c | 47 +--
1 file changed, 29 insertions(+), 18 deletions(-)
--
1.8.1
36 matches
Mail list logo