1. 30 9月, 2020 1 次提交
    • H
      net: hns3: replace macro HNS3_MAX_NON_TSO_BD_NUM · fd665b3d
      Huazhong Tan 提交于
      Currently, the driver is able to query the device's specifications,
      which includes the maximum BD number of non TSO packet, so replace
      macro HNS3_MAX_NON_TSO_BD_NUM with the queried value, and rewrite
      macro HNS3_MAX_NON_TSO_SIZE whose value depends on the the maximum
      BD number of non TSO packet.
      
      Also, add a new parameter max_non_tso_bd_num to function
      hns3_tx_bd_num() and hns3_skb_need_linearized(), then they can get
      the maximum BD number of non TSO packet from the caller instead of
      calculating by themself, The note of hns3_skb_need_linearized()
      should be update as well.
      Signed-off-by: NHuazhong Tan <tanhuazhong@huawei.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fd665b3d
  2. 28 9月, 2020 2 次提交
  3. 25 9月, 2020 4 次提交
  4. 18 9月, 2020 6 次提交
  5. 09 9月, 2020 2 次提交
  6. 27 8月, 2020 1 次提交
  7. 26 8月, 2020 1 次提交
  8. 24 8月, 2020 1 次提交
  9. 29 7月, 2020 2 次提交
  10. 22 7月, 2020 3 次提交
  11. 07 7月, 2020 1 次提交
  12. 19 6月, 2020 5 次提交
  13. 31 5月, 2020 1 次提交
  14. 15 5月, 2020 1 次提交
  15. 26 4月, 2020 3 次提交
    • J
      net: hns3: optimize the filter table entries handling when resetting · 039ba863
      Jian Shen 提交于
      Currently, the PF driver removes all (including its VFs') MAC/VLAN
      flow director table entries when resetting, and restores them after
      reset completed.
      
      In fact, the hardware will clear all table entries only in IMP
      reset and global reset. So driver only needs to restore the table
      entries in these cases, and needs do nothing when PF reset, FLR
      or other function level reset.
      
      This patch optimizes it by removing unnecessary table entries clear
      and restoring handling in the reset flow, and doing the restoring
      after reset completed.
      Signed-off-by: NJian Shen <shenjian15@huawei.com>
      Signed-off-by: NHuazhong Tan <tanhuazhong@huawei.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      039ba863
    • J
      net: hns3: refactor the promisc mode setting · c631c696
      Jian Shen 提交于
      As the HNS3 driver doesn't update the MAC address directly in
      function hns3_set_rx_mode() now, it can't know whether the
      MAC table is full from __dev_uc_sync() and __dev_mc_sync(),
      so it's senseless to handle the overflow promisc here.
      
      This patch removes the handle of overflow promisc from function
      hns3_set_rx_mode(), and updates the promisc mode in the service
      task.
      Signed-off-by: NJian Shen <shenjian15@huawei.com>
      Signed-off-by: NHuazhong Tan <tanhuazhong@huawei.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c631c696
    • J
      net: hns3: refactor the MAC address configure · ee4bcd3b
      Jian Shen 提交于
      Currently, the HNS3 driver sync and unsync MAC address in function
      hns3_set_rx_mode(). For PF, it adds and deletes MAC address directly
      in the path of dev_set_rx_mode(). If failed, it won't retry until
      next calling of hns3_set_rx_mode(). On the other hand, if request
      add and remove a same address many times at a short interval, each
      request must be done one by one, can't be merged. For VF, it sends
      mailbox messages to PF to request adding or deleting MAC address in
      the path of function hns3_set_rx_mode(), no matter the address is
      configured success.
      
      This patch refines it by recording the MAC address in function
      hns3_set_rx_mode(), and updating MAC address in the service task.
      If failed, it will retry by the next calling of periodical service
      task. It also uses some state to mark the state of each MAC address
      in the MAC list, which can help merge configure request for a same
      address. With these changes, when global reset or IMP reset occurs,
      we can restore the MAC table with the MAC list.
      Signed-off-by: NJian Shen <shenjian15@huawei.com>
      Signed-off-by: NHuazhong Tan <tanhuazhong@huawei.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ee4bcd3b
  16. 22 4月, 2020 1 次提交
  17. 31 3月, 2020 1 次提交
  18. 13 3月, 2020 1 次提交
  19. 10 3月, 2020 1 次提交
  20. 21 1月, 2020 2 次提交