1. 20 Jan, 2011 11 commits
    • Eric Dumazet's avatar
      net_sched: cleanups · cc7ec456
      Eric Dumazet authored
      Cleanup net/sched code to current CodingStyle and practices.
      
      Reduce inline abuse
      Signed-off-by: default avatarEric Dumazet <eric.dumazet@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      cc7ec456
    • Alban Crequy's avatar
    • John Fastabend's avatar
      net_sched: implement a root container qdisc sch_mqprio · b8970f0b
      John Fastabend authored
      This implements a mqprio queueing discipline that by default creates
      a pfifo_fast qdisc per tx queue and provides the needed configuration
      interface.
      
      Using the mqprio qdisc the number of tcs currently in use along
      with the range of queues alloted to each class can be configured. By
      default skbs are mapped to traffic classes using the skb priority.
      This mapping is configurable.
      
      Configurable parameters,
      
      struct tc_mqprio_qopt {
      	__u8    num_tc;
      	__u8    prio_tc_map[TC_BITMASK + 1];
      	__u8    hw;
      	__u16   count[TC_MAX_QUEUE];
      	__u16   offset[TC_MAX_QUEUE];
      };
      
      Here the count/offset pairing give the queue alignment and the
      prio_tc_map gives the mapping from skb->priority to tc.
      
      The hw bit determines if the hardware should configure the count
      and offset values. If the hardware bit is set then the operation
      will fail if the hardware does not implement the ndo_setup_tc
      operation. This is to avoid undetermined states where the hardware
      may or may not control the queue mapping. Also minimal bounds
      checking is done on the count/offset to verify a queue does not
      exceed num_tx_queues and that queue ranges do not overlap. Otherwise
      it is left to user policy or hardware configuration to create
      useful mappings.
      
      It is expected that hardware QOS schemes can be implemented by
      creating appropriate mappings of queues in ndo_tc_setup().
      
      One expected use case is drivers will use the ndo_setup_tc to map
      queue ranges onto 802.1Q traffic classes. This provides a generic
      mechanism to map network traffic onto these traffic classes and
      removes the need for lower layer drivers to know specifics about
      traffic types.
      Signed-off-by: default avatarJohn Fastabend <john.r.fastabend@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b8970f0b
    • John Fastabend's avatar
      net: implement mechanism for HW based QOS · 4f57c087
      John Fastabend authored
      This patch provides a mechanism for lower layer devices to
      steer traffic using skb->priority to tx queues. This allows
      for hardware based QOS schemes to use the default qdisc without
      incurring the penalties related to global state and the qdisc
      lock. While reliably receiving skbs on the correct tx ring
      to avoid head of line blocking resulting from shuffling in
      the LLD. Finally, all the goodness from txq caching and xps/rps
      can still be leveraged.
      
      Many drivers and hardware exist with the ability to implement
      QOS schemes in the hardware but currently these drivers tend
      to rely on firmware to reroute specific traffic, a driver
      specific select_queue or the queue_mapping action in the
      qdisc.
      
      By using select_queue for this drivers need to be updated for
      each and every traffic type and we lose the goodness of much
      of the upstream work. Firmware solutions are inherently
      inflexible. And finally if admins are expected to build a
      qdisc and filter rules to steer traffic this requires knowledge
      of how the hardware is currently configured. The number of tx
      queues and the queue offsets may change depending on resources.
      Also this approach incurs all the overhead of a qdisc with filters.
      
      With the mechanism in this patch users can set skb priority using
      expected methods ie setsockopt() or the stack can set the priority
      directly. Then the skb will be steered to the correct tx queues
      aligned with hardware QOS traffic classes. In the normal case with
      single traffic class and all queues in this class everything
      works as is until the LLD enables multiple tcs.
      
      To steer the skb we mask out the lower 4 bits of the priority
      and allow the hardware to configure upto 15 distinct classes
      of traffic. This is expected to be sufficient for most applications
      at any rate it is more then the 8021Q spec designates and is
      equal to the number of prio bands currently implemented in
      the default qdisc.
      
      This in conjunction with a userspace application such as
      lldpad can be used to implement 8021Q transmission selection
      algorithms one of these algorithms being the extended transmission
      selection algorithm currently being used for DCB.
      Signed-off-by: default avatarJohn Fastabend <john.r.fastabend@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4f57c087
    • Vlad Dogaru's avatar
      netlink: support setting devgroup parameters · e7ed828f
      Vlad Dogaru authored
      If a rtnetlink request specifies a negative or zero ifindex and has no
      interface name attribute, but has a group attribute, then the chenges
      are made to all the interfaces belonging to the specified group.
      Signed-off-by: default avatarVlad Dogaru <ddvlad@rosedu.org>
      Acked-by: default avatarJamal Hadi Salim <hadi@cyberus.ca>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e7ed828f
    • Vlad Dogaru's avatar
      net_device: add support for network device groups · cbda10fa
      Vlad Dogaru authored
      Net devices can now be grouped, enabling simpler manipulation from
      userspace. This patch adds a group field to the net_device structure, as
      well as rtnetlink support to query and modify it.
      Signed-off-by: default avatarVlad Dogaru <ddvlad@rosedu.org>
      Acked-by: default avatarJamal Hadi Salim <hadi@cyberus.ca>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      cbda10fa
    • Shan Wei's avatar
      net: cleanup unused macros in net directory · 441c793a
      Shan Wei authored
      Clean up some unused macros in net/*.
      1. be left for code change. e.g. PGV_FROM_VMALLOC, PGV_FROM_VMALLOC, KMEM_SAFETYZONE.
      2. never be used since introduced to kernel.
         e.g. P9_RDMA_MAX_SGE, UTIL_CTRL_PKT_SIZE.
      Signed-off-by: default avatarShan Wei <shanwei@cn.fujitsu.com>
      Acked-by: default avatarSjur Braendeland <sjur.brandeland@stericsson.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      441c793a
    • Jon Mason's avatar
      vxge: update driver version · 6997e618
      Jon Mason authored
      Update vxge driver version to 2.5.2
      Signed-off-by: default avatarJon Mason <jon.mason@exar.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6997e618
    • Jon Mason's avatar
      vxge: MSIX one shot mode · 16fded7d
      Jon Mason authored
      To reduce the possibility of losing an interrupt in the handler due to a
      race between an interrupt processing and disable/enable of interrupts,
      enable MSIX one shot.
      
      Also, add support for adaptive interrupt coalesing
      Signed-off-by: default avatarJon Mason <jon.mason@exar.com>
      Signed-off-by: default avatarMasroor Vettuparambil <masroor.vettuparambil@exar.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      16fded7d
    • Jon Mason's avatar
      vxge: correct eprom version detection · 1d15f81c
      Jon Mason authored
      The firmware PXE EPROM version detection is failing due to passing the
      wrong parameter into firmware query function.  Also, the version
      printing function has an extraneous newline.
      Signed-off-by: default avatarJon Mason <jon.mason@exar.com>
      Signed-off-by: default avatarSivakumar Subramani <sivakumar.subramani@exar.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1d15f81c
    • Jon Mason's avatar
      vxge: cleanup probe error paths · 6cca2003
      Jon Mason authored
      Reorder the commands to be in the inverse order of their allocations
      (instead of the random order they appear to be in), propagate return
      code on errors from pci_request_region and register_netdev, reduce the
      config_dev_cnt and total_dev_cnt counters on remove, and return the
      correct error code for vdev->vpaths kzalloc failures.  Also, prevent
      leaking of vdev->vpaths memory and netdev in vxge_probe error path due
      to freeing for these not occurring in vxge_device_unregister.
      Signed-off-by: default avatarJon Mason <jon.mason@exar.com>
      Signed-off-by: default avatarSivakumar Subramani <sivakumar.subramani@exar.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6cca2003
  2. 19 Jan, 2011 17 commits
  3. 18 Jan, 2011 12 commits