1. 04 2月, 2016 1 次提交
  2. 12 11月, 2015 2 次提交
  3. 12 6月, 2015 2 次提交
    • F
      Change qemu_set_fd_handler2(..., NULL, ...) to qemu_set_fd_handler · 82e1cc4b
      Fam Zheng 提交于
      Done with following Coccinelle semantic patch, plus manual cosmetic changes in
      net/*.c.
      
          @@
          expression E1, E2, E3, E4;
          @@
          -   qemu_set_fd_handler2(E1, NULL, E2, E3, E4);
          +   qemu_set_fd_handler(E1, E2, E3, E4);
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Message-id: 1433400324-7358-8-git-send-email-famz@redhat.com
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      82e1cc4b
    • F
      netmap: Drop netmap_can_send · e8dd1d9c
      Fam Zheng 提交于
      This callback is called by main loop before polling s->fd, if it returns
      false, the fd will not be polled in this iteration.
      
      This is redundant with checks inside read callback. After this patch,
      the data will be copied from s->fd to s->iov when it arrives. If the
      device can't receive, it will be queued to incoming_queue, and when the
      device status changes, this queue will be flushed.
      
      Also remove the qemu_can_send_packet() check in netmap_send. If it's
      true, we are good; if it's false, the qemu_sendv_packet_async would
      return 0 and read poll will be disabled until netmap_send_completed is
      called.
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Message-id: 1433400324-7358-5-git-send-email-famz@redhat.com
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      e8dd1d9c
  4. 27 5月, 2015 1 次提交
    • M
      net: Permit incremental conversion of init functions to Error · a30ecde6
      Markus Armbruster 提交于
      Error reporting for netdev_add is broken: the net_client_init_fun[]
      report the actual errors with (at best) error_report(), and their
      caller net_client_init1() makes up a generic error on top.
      
      For command line and HMP, this produces an mildly ugly error cascade.
      
      In QMP, the actual errors go to stderr, and the generic error becomes
      the command's error reply.
      
      To fix this, we need to convert the net_client_init_fun[] to Error.
      
      To permit fixing them one by one, add an Error ** parameter to the
      net_client_init_fun[].  If the call fails without returning an Error,
      make up the same generic Error as before.  But if it returns one, use
      that instead.  Since none of them does so far, no functional change.
      Signed-off-by: NMarkus Armbruster <armbru@redhat.com>
      Reviewed-by: NEric Blake <eblake@redhat.com>
      Message-id: 1431691143-1015-3-git-send-email-armbru@redhat.com
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      a30ecde6
  5. 25 3月, 2014 1 次提交
  6. 25 2月, 2014 2 次提交
    • V
      net: Disable netmap backend when not supported · 0a985b37
      Vincenzo Maffione 提交于
      This patch fixes configure so that the netmap backend is not compiled in if the
      host doesn't support an API version >= 11. A version upper bound (15) has been
      added so that the netmap API can be extended with some minor features without
      requiring QEMU code modifications.
      
      Moreover, some changes have been done to net/netmap.c in order to reflect the
      current netmap API/ABI (11).
      
      The NETMAP_WITH_LIBS macro makes possible to include some utilities (e.g.
      netmap ring macros, D(), RD() and other high level functions) through the netmap
      headers. In this way we get rid of the D and RD macro definitions in the QEMU
      code, and we open the way for further code simplifications that will be
      introduced by future patches.
      Signed-off-by: NVincenzo Maffione <v.maffione@gmail.com>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      0a985b37
    • V
      net: add offloading support to netmap backend · f6c65bfb
      Vincenzo Maffione 提交于
      Whit this patch, the netmap backend supports TSO/UFO/CSUM
      offloadings, and accepts the virtio-net header, similarly to what
      happens with TAP. The offloading callbacks in the NetClientInfo
      interface have been implemented.
      Signed-off-by: NVincenzo Maffione <v.maffione@gmail.com>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      f6c65bfb
  7. 09 12月, 2013 1 次提交
    • V
      net: Adding netmap network backend · 58952137
      Vincenzo Maffione 提交于
      This patch adds support for a network backend based on netmap.
      netmap is a framework for high speed packet I/O. You can use it
      to build extremely fast traffic generators, monitors, software
      switches or network middleboxes. Its companion software switch
      VALE lets you interconnect virtual machines.
      netmap and VALE are implemented as a non-intrusive kernel module,
      support NICs from multiple vendors, are part of standard FreeBSD
      distributions and available in source format for Linux too.
      
      To compile QEMU with netmap support, use the following configure
      options:
          ./configure [...] --enable-netmap --extra-cflags=-I/path/to/netmap/sys
      where "/path/to/netmap" contains the netmap source code, available at
          http://info.iet.unipi.it/~luigi/netmap/
      
      The same webpage contains more information about the netmap project
      (together with papers and presentations).
      Signed-off-by: NVincenzo Maffione <v.maffione@gmail.com>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      58952137