1. 20 Aug, 2012 1 commit
    • Tejun Heo's avatar
      workqueue: deprecate system_nrt[_freezable]_wq · 3b07e9ca
      Tejun Heo authored
      
      system_nrt[_freezable]_wq are now spurious.  Mark them deprecated and
      convert all users to system[_freezable]_wq.
      
      If you're cc'd and wondering what's going on: Now all workqueues are
      non-reentrant, so there's no reason to use system_nrt[_freezable]_wq.
      Please use system[_freezable]_wq instead.
      
      This patch doesn't make any functional difference.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Acked-By: default avatarLai Jiangshan <laijs@cn.fujitsu.com>
      
      Cc: Jens Axboe <axboe@kernel.dk>
      Cc: David Airlie <airlied@linux.ie>
      Cc: Jiri Kosina <jkosina@suse.cz>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
      Cc: David Howells <dhowells@redhat.com>
      3b07e9ca
  2. 14 Aug, 2012 1 commit
  3. 22 Jul, 2012 1 commit
  4. 30 Jun, 2012 1 commit
  5. 28 Jun, 2012 1 commit
  6. 11 Jun, 2012 1 commit
  7. 30 May, 2012 1 commit
  8. 17 May, 2012 1 commit
    • Michael S. Tsirkin's avatar
      virtio_net: invoke softirqs after __napi_schedule · ec13ee80
      Michael S. Tsirkin authored
      
      __napi_schedule might raise softirq but nothing
      causes do_softirq to trigger, so it does not in fact
      run. As a result,
      the error message "NOHZ: local_softirq_pending 08"
      sometimes occurs during boot of a KVM guest when the network service is
      started and we are oom:
      
        ...
        Bringing up loopback interface:  [  OK  ]
        Bringing up interface eth0:
        Determining IP information for eth0...NOHZ: local_softirq_pending 08
         done.
        [  OK  ]
        ...
      
      Further, receive queue processing might get delayed
      indefinitely until some interrupt triggers:
      virtio_net expected napi to be run immediately.
      
      One way to cause do_softirq to be executed is by
      invoking local_bh_enable(). As __napi_schedule is
      normally called from bh or irq context, this
      seems to make sense: disable bh before __napi_schedule
      and enable afterwards.
      
      In fact it's a very complicated way of calling do_softirq(),
      and works since this function is only used when we are not
      in interrupt context.  It's not hot at all, in any ideal scenario.
      Reported-by: default avatarUlrich Obergfell <uobergfe@redhat.com>
      Tested-by: default avatarUlrich Obergfell <uobergfe@redhat.com>
      Signed-off-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Acked-by: default avatarRusty Russell <rusty@rustcorp.com.au>
      ec13ee80
  9. 15 Apr, 2012 1 commit
    • Jason Wang's avatar
      virtio-net: send gratuitous packets when needed · 586d17c5
      Jason Wang authored
      
      As hypervior does not have the knowledge of guest network configuration, it's
      better to ask guest to send gratuitous packets when needed.
      
      This patch implements VIRTIO_NET_F_GUEST_ANNOUNCE feature: hypervisor would
      notice the guest when it thinks it's time for guest to announce the link
      presnece. Guest tests VIRTIO_NET_S_ANNOUNCE bit during config change interrupt
      and woule send gratuitous packets through netif_notify_peers() and ack the
      notification through ctrl vq.
      
      We need to make sure the atomicy of read and ack in guest otherwise we may ack
      more times than being notified. This is done through handling the whole config
      change interrupt in an non-reentrant workqueue.
      Signed-off-by: default avatarJason Wang <jasowang@redhat.com>
      Acked-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      586d17c5
  10. 13 Apr, 2012 1 commit
  11. 28 Mar, 2012 1 commit
  12. 15 Feb, 2012 1 commit
  13. 13 Feb, 2012 1 commit
  14. 12 Jan, 2012 4 commits
  15. 05 Jan, 2012 1 commit
  16. 29 Dec, 2011 2 commits
    • Rusty Russell's avatar
      virtio_net: use non-reentrant workqueue. · f1776dad
      Rusty Russell authored
      
      Michael S. Tsirkin also noticed that we could run the refill work
      multiple CPUs: if we kick off a refill on one CPU and then on another,
      they would both manipulate the queue at the same time (they use
      napi_disable to avoid racing against the receive handler itself).
      
      Tejun points out that this is what the WQ_NON_REENTRANT flag is for,
      and that there is a convenient system kthread we can use.
      Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f1776dad
    • Rusty Russell's avatar
      virtio_net: set/cancel work on ndo_open/ndo_stop · b2baed69
      Rusty Russell authored
      
      Michael S. Tsirkin noticed that we could run the refill work after
      ndo_close, which can re-enable napi - we don't disable it until
      virtnet_remove.  This is clearly wrong, so move the workqueue control
      to ndo_open and ndo_stop (aka. virtnet_open and virtnet_close).
      
      One subtle point: virtnet_probe() could simply fail if it couldn't
      allocate a receive buffer, but that's less polite in virtnet_open() so
      we schedule a refill as we do in the normal receive path if we run out
      of memory.
      Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b2baed69
  17. 20 Dec, 2011 1 commit
  18. 09 Dec, 2011 1 commit
  19. 26 Nov, 2011 1 commit
  20. 16 Nov, 2011 1 commit
  21. 02 Nov, 2011 1 commit
  22. 24 Oct, 2011 1 commit
  23. 21 Oct, 2011 1 commit
  24. 20 Oct, 2011 1 commit
  25. 19 Oct, 2011 1 commit
  26. 06 Oct, 2011 1 commit
    • Sasha Levin's avatar
      virtio-net: Verify page list size before fitting into skb · e878d78b
      Sasha Levin authored
      
      This patch verifies that the length of a buffer stored in a linked list
      of pages is small enough to fit into a skb.
      
      If the size is larger than a max size of a skb, it means that we shouldn't
      go ahead building skbs anyway since we won't be able to send the buffer as
      the user requested.
      
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: "Michael S. Tsirkin" <mst@redhat.com>
      Cc: virtualization@lists.linux-foundation.org
      Cc: netdev@vger.kernel.org
      Cc: kvm@vger.kernel.org
      Signed-off-by: default avatarSasha Levin <levinsasha928@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e878d78b
  27. 22 Sep, 2011 1 commit
  28. 18 Aug, 2011 1 commit
  29. 22 Jul, 2011 1 commit
  30. 01 Jul, 2011 1 commit
  31. 11 Jun, 2011 1 commit
    • Jason Wang's avatar
      virtio_net: introduce VIRTIO_NET_HDR_F_DATA_VALID · 10a8d94a
      Jason Wang authored
      
      There's no need for the guest to validate the checksum if it have been
      validated by host nics. So this patch introduces a new flag -
      VIRTIO_NET_HDR_F_DATA_VALID which is used to bypass the checksum
      examing in guest. The backend (tap/macvtap) may set this flag when
      met skbs with CHECKSUM_UNNECESSARY to save cpu utilization.
      
      No feature negotiation is needed as old driver just ignore this flag.
      
      Iperf shows 12%-30% performance improvement for UDP traffic. For TCP,
      when gro is on no difference as it produces skb with partial
      checksum. But when gro is disabled, 20% or even higher improvement
      could be measured by netperf.
      Signed-off-by: default avatarJason Wang <jasowang@redhat.com>
      Acked-by: default avatarMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      10a8d94a
  32. 30 May, 2011 1 commit
  33. 02 Apr, 2011 1 commit
  34. 10 Feb, 2011 1 commit
  35. 16 Dec, 2010 1 commit
  36. 12 Nov, 2010 1 commit