1. 11 Nov, 2017 36 commits
  2. 10 Nov, 2017 4 commits
    • Girish Moodalbail's avatar
      net: fix incorrect comment with regard to VLAN packet handling · 54985120
      Girish Moodalbail authored
      The commit bcc6d479 ("net: vlan: make non-hw-accel rx path similar
      to hw-accel") unified accel and non-accel path for VLAN RX. With that
      fix we do not register any packet_type handler for VLANs anymore, so fix
      the incorrect comment.
      Signed-off-by: default avatarGirish Moodalbail <girish.moodalbail@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      54985120
    • David S. Miller's avatar
      Merge branch 'act_vlan-rcu' · b79c069a
      David S. Miller authored
      Manish Kurup says:
      
      ====================
      net_sched actions: act_vlan now uses RCU
      
      This commit consists of 3 patches:
      
      patch1 (1/3):
      The VLAN action maintains one set of stats across all cores, and uses a
      spinlock to synchronize updates to it from the same. Changed this to use a
      per-CPU stats context instead.
      This change will result in better performance.
      
      patch2 (2/3):
      Modified netronome nfp flower action to use VLAN helper functions instead
      of accessing/referencing TC act_vlan private structures directly.
      
      patch3 (3/3):
      Using a spinlock in the VLAN action causes performance issues when the VLAN
      action is used on multiple cores. Rewrote the VLAN action to use RCU read
      locking for reads and updates instead.
      All functions now use an RCU dereferenced pointer to access the VLAN action
      context. Modified helper functions used by other modules, to use the RCU as
      opposed to directly accessing the structure.
      
      As part of this review, there were some changes suggested by reviewers.
      I have incorporated all the changes that were requested.
      
      Here're the changes:
      v2: Fixed all helper functions to use RCU (rtnl_dereference) - Eric, Jamal
      v2: Fixed indentation, extra line nits - Jamal, Jiri
      v2: Moved rcu_head to the end of the struct - Jiri
      v2: Re-formatted locals to reverse-christmas-tree - Jiri
      v2: Removed mismatched spin_lock() - Cong
      v2: Removed spin_lock_bh() in tcf_vlan_init, rtnl_dereference() should
          suffice - Cong, Jiri
      v4: Modified the nfp flower action code to use the VLAN helper functions
          instead of referencing the structure directly. Isolated this into a
          separate patch - Pieter Jansen
      v5: Got rid of the unlikely() for the allocation case - Simon Horman
      v6: Had forgotten cleanup functions for RCU alloc, added them - Dave Miller
      v7: Re-formatted more locals to reverse-christmas-tree - Pieter V
      v8: Reverted reverse-christmas-tree(v7), not required when dependencies
          make it difficult to implement - Alexander D
      v9: Cover letter subject change - Jamal
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b79c069a
    • Manish Kurup's avatar
      act_vlan: VLAN action rewrite to use RCU lock/unlock and update · 4c5b9d96
      Manish Kurup authored
      Using a spinlock in the VLAN action causes performance issues when the VLAN
      action is used on multiple cores. Rewrote the VLAN action to use RCU read
      locking for reads and updates instead.
      All functions now use an RCU dereferenced pointer to access the VLAN action
      context. Modified helper functions used by other modules, to use the RCU as
      opposed to directly accessing the structure.
      Acked-by: default avatarJamal Hadi Salim <jhs@mojatatu.com>
      Acked-by: default avatarJiri Pirko <jiri@mellanox.com>
      Signed-off-by: default avatarManish Kurup <manish.kurup@verizon.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4c5b9d96
    • Manish Kurup's avatar
      nfp flower action: Modified to use VLAN helper functions · bf068bdd
      Manish Kurup authored
      Modified netronome nfp flower action to use VLAN helper functions instead
      of accessing/referencing TC act_vlan private structures directly.
      Reviewed-by: default avatarPieter Jansen van Vuuren <pieter.jansenvanvuuren@netronome.com>
      Signed-off-by: default avatarManish Kurup <manish.kurup@verizon.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bf068bdd