1. 21 8月, 2012 1 次提交
    • T
      workqueue: deprecate system_nrt[_freezable]_wq · 3b07e9ca
      Tejun Heo 提交于
      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: NTejun Heo <tj@kernel.org>
      Acked-By: NLai 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. 15 8月, 2012 1 次提交
  3. 23 7月, 2012 1 次提交
  4. 30 6月, 2012 1 次提交
  5. 28 6月, 2012 1 次提交
  6. 11 6月, 2012 1 次提交
  7. 31 5月, 2012 1 次提交
  8. 17 5月, 2012 1 次提交
    • M
      virtio_net: invoke softirqs after __napi_schedule · ec13ee80
      Michael S. Tsirkin 提交于
      __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: NUlrich Obergfell <uobergfe@redhat.com>
      Tested-by: NUlrich Obergfell <uobergfe@redhat.com>
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      Acked-by: NRusty Russell <rusty@rustcorp.com.au>
      ec13ee80
  9. 15 4月, 2012 1 次提交
    • J
      virtio-net: send gratuitous packets when needed · 586d17c5
      Jason Wang 提交于
      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: NJason Wang <jasowang@redhat.com>
      Acked-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      586d17c5
  10. 13 4月, 2012 1 次提交
  11. 28 3月, 2012 1 次提交
  12. 16 2月, 2012 1 次提交
  13. 14 2月, 2012 1 次提交
  14. 12 1月, 2012 4 次提交
  15. 06 1月, 2012 1 次提交
  16. 30 12月, 2011 2 次提交
    • R
      virtio_net: use non-reentrant workqueue. · f1776dad
      Rusty Russell 提交于
      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: NRusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f1776dad
    • R
      virtio_net: set/cancel work on ndo_open/ndo_stop · b2baed69
      Rusty Russell 提交于
      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: NRusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b2baed69
  17. 20 12月, 2011 1 次提交
  18. 09 12月, 2011 1 次提交
  19. 27 11月, 2011 1 次提交
  20. 17 11月, 2011 1 次提交
  21. 02 11月, 2011 1 次提交
  22. 24 10月, 2011 1 次提交
  23. 21 10月, 2011 1 次提交
  24. 20 10月, 2011 1 次提交
  25. 19 10月, 2011 1 次提交
  26. 07 10月, 2011 1 次提交
    • S
      virtio-net: Verify page list size before fitting into skb · e878d78b
      Sasha Levin 提交于
      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: NSasha Levin <levinsasha928@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e878d78b
  27. 23 9月, 2011 1 次提交
  28. 18 8月, 2011 1 次提交
  29. 22 7月, 2011 1 次提交
  30. 01 7月, 2011 1 次提交
  31. 12 6月, 2011 1 次提交
    • J
      virtio_net: introduce VIRTIO_NET_HDR_F_DATA_VALID · 10a8d94a
      Jason Wang 提交于
      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: NJason Wang <jasowang@redhat.com>
      Acked-by: NMichael S. Tsirkin <mst@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      10a8d94a
  32. 30 5月, 2011 1 次提交
  33. 02 4月, 2011 1 次提交
  34. 11 2月, 2011 1 次提交
  35. 17 12月, 2010 1 次提交
  36. 13 11月, 2010 1 次提交