1. 04 5月, 2016 2 次提交
    • A
      ixgbe: Match on multiple headers for cls_u32 offloads · 1cdaaf54
      Amritha Nambiar 提交于
      Adds support to set filters with multiple header fields (L3,L4)to match on.
      This is achieved in the following order:
      1. Create a leaf hash table for the next header.
      2. Create a link to the leaf hash table from the base hash table with
         matches on next header type and current header fields.
      3. Add filter in leaf hash table with match on next header fields and
         action.
      
      Verified with the following filters :
      
      Match TCP and DIP:
              handle 1: u32 divisor 1
              u32 ht 800: order 1 link 1: \
              offset at 0 mask 0f00 shift 6 plus 0 eat \
              match ip protocol 6 ff match ip dst 10.0.0.1/32
              match tcp src 28 ffff action drop
      
      Delete the filter:
      
      Match on DIP, SIP, UDP (SPort, DPort):
              handle 2: u32 divisor 1
              u32 ht 800: order 2 link 2: \
              offset at 0 mask 0f00 shift 6 plus 0 eat \
              match ip dst 15.0.0.2/32 match ip protocol 17 ff \
              match ip src 15.0.0.1/32
              match udp src 30 ffff match udp dst 32 ffff action drop
      Signed-off-by: NAmritha Nambiar <amritha.nambiar@intel.com>
      Acked-by: NSridhar Samudrala <sridhar.samudrala@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      1cdaaf54
    • S
      ixgbe: Add support for redirect action to cls_u32 offloads · 947f8a45
      Sridhar Samudrala 提交于
      This patch enables 'redirect' to a SRIOV VF or a offloaded macvlan
      device queue via tc 'mirred' action.
      
      Verified with the following script that creates SRIOV VFs,  offloaded
      macvlan and adds tc u32 filters with redirect action to the associated
      netdevs.
      
       # add ingress qdisc.
       tc qdisc add dev p4p1 ingress
      
       # enable hw tc offload.
       ethtool -K p4p1 hw-tc-offload on
      
       # create 4 sriov VFs and bring up the first one.
       echo 4 > /sys/class/net/p4p1/device/sriov_numvfs
       sleep 1
       ip link set p4p1 up
       ip link set p4p1_0 up
      
       # create a offloaded macvlan device and bring it up.
       ethtool -K p4p1 l2-fwd-offload on
       ip link add link p4p1 name mvlan_1 type macvlan
       ip link set mvlan_1 up
      
       # add u32 filter with action to redirect to VF netdev
       tc filter add dev p4p1 parent ffff: protocol ip prio 99 \
          handle 800:0:1 u32 ht 800: \
          match ip src 192.168.1.3/32 \
          action mirred egress redirect dev p4p1_0
      
       # add u32 filter with action to redirect to macvlan netdev
       tc filter add dev p4p1 parent ffff: protocol ip prio 99 \
          handle 800:0:2 u32 ht 800: \
          match ip src 192.168.2.3/32 \
          action mirred egress redirect dev mvlan_1
      Signed-off-by: NSridhar Samudrala <sridhar.samudrala@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      947f8a45
  2. 25 4月, 2016 11 次提交
  3. 22 4月, 2016 1 次提交
  4. 08 4月, 2016 18 次提交
  5. 05 4月, 2016 8 次提交