1. 10 9月, 2019 4 次提交
  2. 05 9月, 2019 1 次提交
  3. 31 8月, 2019 2 次提交
  4. 23 8月, 2019 13 次提交
  5. 18 8月, 2019 2 次提交
  6. 11 8月, 2019 1 次提交
  7. 06 8月, 2019 8 次提交
  8. 31 7月, 2019 1 次提交
  9. 24 7月, 2019 1 次提交
  10. 23 7月, 2019 1 次提交
  11. 10 7月, 2019 3 次提交
  12. 29 6月, 2019 1 次提交
    • H
      i40e: Add macvlan support on i40e · 1d8d80b4
      Harshitha Ramamurthy 提交于
      This patch enables macvlan offloads for i40e. The idea is to use
      channels as macvlan interfaces. The channels are VSIs of
      type VMDQ. When the first macvlan is created, the maximum number of
      channels possible are created. From then on, as a macvlan interface
      is created, a macvlan filter is added to these already created
      channels (VSIs).
      
      This patch utilizes subordinate device traffic classes to make queue
      groups(channels) available for an upper device like a macvlan.
      
      Steps to configure macvlan offloads:
      1. ethtool -K ethx l2-fwd-offload on
      2. ip link add link ethx name macvlan1 type macvlan
      3. ip addr add <address> dev macvlan1
      4. ip link set macvlan1 up
      Signed-off-by: NHarshitha Ramamurthy <harshitha.ramamurthy@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      1d8d80b4
  13. 28 6月, 2019 1 次提交
  14. 27 6月, 2019 1 次提交
    • G
      i40e/i40e_virtchnl_pf: Use struct_size() in kzalloc() · fae6cad1
      Gustavo A. R. Silva 提交于
      One of the more common cases of allocation size calculations is finding
      the size of a structure that has a zero-sized array at the end, along
      with memory for some number of elements for that array. For example:
      
      struct virtchnl_iwarp_qvlist_info {
      	...
              struct virtchnl_iwarp_qv_info qv_info[1];
      };
      
      size = sizeof(struct virtchnl_iwarp_qvlist_info) + (sizeof(struct virtchnl_iwarp_qv_info) * count;
      instance = kzalloc(size, GFP_KERNEL);
      
      and
      
      struct virtchnl_vf_resource {
      	...
              struct virtchnl_vsi_resource vsi_res[1];
      };
      
      size = sizeof(struct virtchnl_vf_resource) + sizeof(struct virtchnl_vsi_resource) * count;
      instance = kzalloc(size, GFP_KERNEL);
      
      Instead of leaving these open-coded and prone to type mistakes, we can
      now use the new struct_size() helper:
      
      instance = kzalloc(struct_size(instance, qv_info, count), GFP_KERNEL);
      
      and
      
      instance = kzalloc(struct_size(instance, vsi_res, count), GFP_KERNEL);
      
      Notice that, in the first case above, variable size is not necessary, hence it
      is removed.
      
      This code was detected with the help of Coccinelle.
      Signed-off-by: N"Gustavo A. R. Silva" <gustavo@embeddedor.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      fae6cad1