Skip to content
  • Jason Wang's avatar
    virtio_net: multiqueue support · 986a4f4d
    Jason Wang authored
    
    
    This patch adds the multiqueue (VIRTIO_NET_F_MQ) support to virtio_net
    driver. VIRTIO_NET_F_MQ capable device could allow the driver to do packet
    transmission and reception through multiple queue pairs and does the packet
    steering to get better performance. By default, one one queue pair is used, user
    could change the number of queue pairs by ethtool in the next patch.
    
    When multiple queue pairs is used and the number of queue pairs is equal to the
    number of vcpus. Driver does the following optimizations to implement per-cpu
    virt queue pairs:
    
    - select the txq based on the smp processor id.
    - smp affinity hint to the cpu that owns the queue pairs.
    
    This could be used with the flow steering support of the device to guarantee the
    packets of a single flow is handled by the same cpu.
    
    Signed-off-by: default avatarKrishna Kumar <krkumar2@in.ibm.com>
    Signed-off-by: default avatarJason Wang <jasowang@redhat.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    986a4f4d