19 Jul, 2011

5 commits

  • As we now only update used ring after enabling
    the backend, we can write flags with __put_user:
    as that's done on data path, it matters.

    Signed-off-by: Michael S. Tsirkin

    Michael S. Tsirkin
     
  • Fix get/put refcount imbalance with zero copy,
    which caused qemu to hang forever on guest driver unload.

    Signed-off-by: Michael S. Tsirkin

    Michael S. Tsirkin
     
  • We need to log writes when updating used flags and avail event
    fields. Otherwise the guest may see a stale value after migration and
    miss notifying the host.

    Signed-off-by: Jason Wang
    Signed-off-by: Michael S. Tsirkin

    Jason Wang
     
  • Move the used ring initialization after backend was set. This
    makes it possible to disable the backend and tweak the used ring,
    then restart. This will also make it possible to log the used ring
    write correctly.

    Signed-off-by: Jason Wang
    Signed-off-by: Michael S. Tsirkin

    Jason Wang
     
  • >From: Shirley Ma

    This adds experimental zero copy support in vhost-net,
    disabled by default. To enable, set
    experimental_zcopytx module option to 1.

    This patch maintains the outstanding userspace buffers in the
    sequence it is delivered to vhost. The outstanding userspace buffers
    will be marked as done once the lower device buffers DMA has finished.
    This is monitored through last reference of kfree_skb callback. Two
    buffer indices are used for this purpose.

    The vhost-net device passes the userspace buffers info to lower device
    skb through message control. DMA done status check and guest
    notification are handled by handle_tx: in the worst case is all buffers
    in the vq are in pending/done status, so we need to notify guest to
    release DMA done buffers first before we get any new buffers from the
    vq.

    One known problem is that if the guest stops submitting
    buffers, buffers might never get used until some
    further action, e.g. device reset. This does not
    seem to affect linux guests.

    Signed-off-by: Shirley
    Signed-off-by: Michael S. Tsirkin
    Signed-off-by: David S. Miller

    Michael S. Tsirkin
     

30 May, 2011

1 commit


07 May, 2011

1 commit

  • - Documentation/kvm/ to Documentation/virtual/kvm
    - Documentation/uml/ to Documentation/virtual/uml
    - Documentation/lguest/ to Documentation/virtual/lguest
    throughout the kernel source tree.

    Signed-off-by: Rob Landley
    Signed-off-by: Randy Dunlap

    Rob Landley
     

09 Mar, 2011

2 commits


10 Jan, 2011

1 commit


09 Dec, 2010

3 commits


04 Nov, 2010

4 commits


27 Oct, 2010

1 commit


24 Oct, 2010

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1699 commits)
    bnx2/bnx2x: Unsupported Ethtool operations should return -EINVAL.
    vlan: Calling vlan_hwaccel_do_receive() is always valid.
    tproxy: use the interface primary IP address as a default value for --on-ip
    tproxy: added IPv6 support to the socket match
    cxgb3: function namespace cleanup
    tproxy: added IPv6 support to the TPROXY target
    tproxy: added IPv6 socket lookup function to nf_tproxy_core
    be2net: Changes to use only priority codes allowed by f/w
    tproxy: allow non-local binds of IPv6 sockets if IP_TRANSPARENT is enabled
    tproxy: added tproxy sockopt interface in the IPV6 layer
    tproxy: added udp6_lib_lookup function
    tproxy: added const specifiers to udp lookup functions
    tproxy: split off ipv6 defragmentation to a separate module
    l2tp: small cleanup
    nf_nat: restrict ICMP translation for embedded header
    can: mcp251x: fix generation of error frames
    can: mcp251x: fix endless loop in interrupt handler if CANINTF_MERRF is set
    can-raw: add msg_flags to distinguish local traffic
    9p: client code cleanup
    rds: make local functions/variables static
    ...

    Fix up conflicts in net/core/dev.c, drivers/net/pcmcia/smc91c92_cs.c and
    drivers/net/wireless/ath/ath9k/debug.c as per David

    Linus Torvalds
     

21 Oct, 2010

1 commit


12 Oct, 2010

1 commit


07 Oct, 2010

2 commits


05 Oct, 2010

1 commit

  • Qemu supports up to UIO_MAXIOV s/g so we have to match that because guest
    drivers may rely on this.

    Allocate indirect and log arrays dynamically to avoid using too much contigious
    memory and make the length of hdr array to match the header length since each
    iovec entry has a least one byte.

    Test with copying large files w/ and w/o migration in both linux and windows
    guests.

    Signed-off-by: Jason Wang
    Signed-off-by: Michael S. Tsirkin

    Jason Wang
     

22 Sep, 2010

1 commit


06 Sep, 2010

2 commits

  • vhost should set worker to NULL on cgroups attach failure,
    so that we won't try to destroy the worker again on close.

    Signed-off-by: Michael S. Tsirkin

    Michael S. Tsirkin
     
  • Since 2.6.36-rc1, non-root users of vhost-net fail to attach
    if they are in any cgroups.

    The reason is that when qemu uses vhost, vhost wants to attach
    its thread to all cgroups that qemu has. But we got the API backwards,
    so a non-priveledged process (Qemu) tried to control
    the priveledged one (vhost), which fails.

    Fix this by switching to the new cgroup_attach_task_all,
    and running it from the vhost thread.

    Signed-off-by: Michael S. Tsirkin

    Michael S. Tsirkin
     

02 Sep, 2010

1 commit


22 Aug, 2010

1 commit


28 Jul, 2010

3 commits

  • This adds support for mergeable buffers in vhost-net: this is needed
    for older guests without indirect buffer support, as well
    as for zero copy with some devices.

    Includes changes by Michael S. Tsirkin to make the
    patch as low risk as possible (i.e., close to no changes
    when feature is disabled).

    Signed-off-by: David Stevens
    Signed-off-by: Michael S. Tsirkin

    David Stevens
     
  • Apply the cgroup of the owner task to the created vhost worker.

    Based on patches from Sridhar Samudrala's and Tejun Heo.
    Later we'll need to also apply cpumask and probably priority
    of the owner process.

    Discussion on the best way to do this is still ongoing.

    Signed-off-by: Michael S. Tsirkin
    Cc: Tejun Heo
    Cc: Sridhar Samudrala
    Cc: Li Zefan

    Michael S. Tsirkin
     
  • Replace vhost_workqueue with per-vhost kthread. Other than callback
    argument change from struct work_struct * to struct vhost_work *,
    there's no visible change to vhost_poll_*() interface.

    This conversion is to make each vhost use a dedicated kthread so that
    resource control via cgroup can be applied.

    Partially based on Sridhar Samudrala's patch.

    * Updated to use sub structure vhost_work instead of directly using
    vhost_poll at Michael's suggestion.

    * Added flusher wake_up() optimization at Michael's suggestion.

    Changes by MST:
    * Converted atomics/barrier use to a spinlock.
    * Create thread on SET_OWNER
    * Fix flushing

    Signed-off-by: Tejun Heo
    Signed-off-by: Michael S. Tsirkin
    Cc: Sridhar Samudrala

    Tejun Heo
     

08 Jul, 2010

1 commit


02 Jul, 2010

1 commit


27 Jun, 2010

1 commit

  • When ring parsing fails, we currently handle this
    as ring empty condition. This means that we enable
    kicks and recheck ring empty: if this not empty,
    we re-start polling which of course will fail again.

    Instead, let's return a negative error code and stop polling.

    Signed-off-by: Michael S. Tsirkin

    Michael S. Tsirkin
     

02 Jun, 2010

1 commit


29 May, 2010

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (22 commits)
    netlink: bug fix: wrong size was calculated for vfinfo list blob
    netlink: bug fix: don't overrun skbs on vf_port dump
    xt_tee: use skb_dst_drop()
    netdev/fec: fix ifconfig eth0 down hang issue
    cnic: Fix context memory init. on 5709.
    drivers/net: Eliminate a NULL pointer dereference
    drivers/net/hamradio: Eliminate a NULL pointer dereference
    be2net: Patch removes redundant while statement in loop.
    ipv6: Add GSO support on forwarding path
    net: fix __neigh_event_send()
    vhost: fix the memory leak which will happen when memory_access_ok fails
    vhost-net: fix to check the return value of copy_to/from_user() correctly
    vhost: fix to check the return value of copy_to/from_user() correctly
    vhost: Fix host panic if ioctl called with wrong index
    net: fix lock_sock_bh/unlock_sock_bh
    net/iucv: Add missing spin_unlock
    net: ll_temac: fix checksum offload logic
    net: ll_temac: fix interrupt bug when interrupt 0 is used
    sctp: dubious bitfields in sctp_transport
    ipmr: off by one in __ipmr_fill_mroute()
    ...

    Linus Torvalds
     

27 May, 2010

3 commits