1. 15 Nov, 2018 12 commits
    • Cong Wang's avatar
      net: get rid of __tcp_checksum_complete() · 6ab6dfa6
      Cong Wang authored
      __tcp_checksum_complete() is 100% same with __skb_checksum_complete()
      and there is no other caller except tcp_checksum_complete().
      So, just use __skb_checksum_complete() there.
      Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6ab6dfa6
    • Amritha Nambiar's avatar
      net: sched: cls_flower: Classify packets using port ranges · 5c72299f
      Amritha Nambiar authored
      Added support in tc flower for filtering based on port ranges.
      
      Example:
      1. Match on a port range:
      -------------------------
      $ tc filter add dev enp4s0 protocol ip parent ffff:\
        prio 1 flower ip_proto tcp dst_port range 20-30 skip_hw\
        action drop
      
      $ tc -s filter show dev enp4s0 parent ffff:
      filter protocol ip pref 1 flower chain 0
      filter protocol ip pref 1 flower chain 0 handle 0x1
        eth_type ipv4
        ip_proto tcp
        dst_port range 20-30
        skip_hw
        not_in_hw
              action order 1: gact action drop
               random type none pass val 0
               index 1 ref 1 bind 1 installed 85 sec used 3 sec
              Action statistics:
              Sent 460 bytes 10 pkt (dropped 10, overlimits 0 requeues 0)
              backlog 0b 0p requeues 0
      
      2. Match on IP address and port range:
      --------------------------------------
      $ tc filter add dev enp4s0 protocol ip parent ffff:\
        prio 1 flower dst_ip 192.168.1.1 ip_proto tcp dst_port range 100-200\
        skip_hw action drop
      
      $ tc -s filter show dev enp4s0 parent ffff:
      filter protocol ip pref 1 flower chain 0 handle 0x2
        eth_type ipv4
        ip_proto tcp
        dst_ip 192.168.1.1
        dst_port range 100-200
        skip_hw
        not_in_hw
              action order 1: gact action drop
               random type none pass val 0
               index 2 ref 1 bind 1 installed 58 sec used 2 sec
              Action statistics:
              Sent 920 bytes 20 pkt (dropped 20, overlimits 0 requeues 0)
              backlog 0b 0p requeues 0
      
      v4:
      1. Added condition before setting port key.
      2. Organized setting and dumping port range keys into functions
         and added validation of input range.
      
      v3:
      1. Moved new fields in UAPI enum to the end of enum.
      2. Removed couple of empty lines.
      
      v2:
      Addressed Jiri's comments:
      1. Added separate functions for dst and src comparisons.
      2. Removed endpoint enum.
      3. Added new bit TCA_FLOWER_FLAGS_RANGE to decide normal/range
        lookup.
      4. Cleaned up fl_lookup function.
      Signed-off-by: default avatarAmritha Nambiar <amritha.nambiar@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5c72299f
    • Cong Wang's avatar
      net: dump more useful information in netdev_rx_csum_fault() · 7fe50ac8
      Cong Wang authored
      Currently netdev_rx_csum_fault() only shows a device name,
      we need more information about the skb for debugging csum
      failures.
      
      Sample output:
      
       ens3: hw csum failure
       dev features: 0x0000000000014b89
       skb len=84 data_len=0 pkt_type=0 gso_size=0 gso_type=0 nr_frags=0 ip_summed=0 csum=0 csum_complete_sw=0 csum_valid=0 csum_level=0
      
      Note, I use pr_err() just to be consistent with the existing one.
      Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7fe50ac8
    • Andrew Lunn's avatar
      net: dsa: mv88e6xxx: Work around mv886e6161 SERDES missing MII_PHYSID2 · ddc49acb
      Andrew Lunn authored
      We already have a workaround for a couple of switches whose internal
      PHYs only have the Marvel OUI, but no model number. We detect such
      PHYs and give them the 6390 ID as the model number. However the
      mv88e6161 has two SERDES interfaces in the same address range as its
      internal PHYs. These suffer from the same problem, the Marvell OUI,
      but no model number. As a result, these SERDES interfaces were getting
      the same PHY ID as the mv88e6390, even though they are not PHYs, and
      the Marvell PHY driver was trying to drive them.
      
      Add a special case to stop this from happen.
      Reported-by: default avatarChris Healy <Chris.Healy@zii.aero>
      Signed-off-by: default avatarAndrew Lunn <andrew@lunn.ch>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ddc49acb
    • David S. Miller's avatar
      Merge branch '100GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue · f0739e65
      David S. Miller authored
      Jeff Kirsher says:
      
      ====================
      100GbE Intel Wired LAN Driver Updates 2018-11-13
      
      This series contains updates to the ice driver only.
      
      Brett cleans up debug print messages by removing useless or duplicate
      messages, and make sure we assign the hardware head pointer to head
      instead of the software head pointer.  Resolved an issue when disabling
      SRIOV we were trying to stop queues multiple times, so make sure we
      disable SRIOV before stopping transmit and receive queues for VF.
      
      Tony fixes a potential NULL pointer dereference during a VF reset.
      
      Anirudh resolves an issue where we were releasing the VSI before
      removing the VSI scheduler node, which was resulting in an error "Failed
      to set LAN Tx queue context, error: -1".  Also fixed the guaranteed
      number of VSIs available and used by discovering the device
      capabilities to determine the 'guar_num_vsi' per function, rather than
      always using the theoretical max number of VSIs every time.
      
      Dave avoids a deadlock by nesting RTNL locking, so added a boolean to
      determine if the RTNL lock is already held.
      
      Lev fixes bad mask values which would break compilation.
      
      Piotr increases the receive queue disable timeout since it can take
      additional time to finish all pending queue requests.
      
      Usha resolves an issue of VLAN priority tagged traffic not appearing on
      all traffic classes, which was causing ETS bandwidth shaping to not work
      as expected.
      
      Henry fixes the reset path to cleanup the old scheduler tree before
      rebuilding it.
      
      Md Fahad removes a unnecessary check which was causing a driver load
      error on platforms with more than 128 cores.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f0739e65
    • David S. Miller's avatar
      Merge branch 'hns3-hwgro' · bd5196b6
      David S. Miller authored
      Salil Mehta says:
      
      ====================
      net: hns3: Add support of hardware GRO to HNS3 Driver
      
      This patch-set adds support of hardware assisted GRO feature to
      HNS3 driver on Rev B(=0x21) platform. Current hardware only
      supports TCP/IPv{4|6} flows.
      
      Change Log:
      V1->V2:
      1. Remove redundant print reported by Leon Romanovsky.
         Link: https://lkml.org/lkml/2018/11/13/715
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bd5196b6
    • Peng Li's avatar
      net: hns3: Adds GRO params to SKB for the stack · a6d53b97
      Peng Li authored
      When HW GRO enable, protocol stack will not do GRO again,
      driver should add gro param to the skb for the protocol
      stack..
      Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
      Signed-off-by: default avatarSalil Mehta <salil.mehta@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a6d53b97
    • Peng Li's avatar
      net: hns3: Add skb chain when num of RX buf exceeds MAX_SKB_FRAGS · 81ae0e04
      Peng Li authored
      MAX_SKB_FRAGS in protocol stack is defined as:
      
      MAX_SKB_FRAGS is 17 when PAGE_SIZE is 4K. If HW enable GRO, it may
      merge small packets and the rx buffer may be more than
      MAX_SKB_FRAGS. So driver will add skb chain when RX buffer num.
      more than MAX_SKB_FRAGS.
      Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
      Signed-off-by: default avatarSalil Mehta <salil.mehta@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      81ae0e04
    • Peng Li's avatar
      net: hns3: Add support for ethtool -K to enable/disable HW GRO · 5c9f6b39
      Peng Li authored
      This patch adds support of ethtool -K to enable/disable
      hardware GRO in HNS3 PF/VF driver.
      Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
      Signed-off-by: default avatarSalil Mehta <salil.mehta@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5c9f6b39
    • Peng Li's avatar
      net: hns3: Add handling of GRO Pkts not fully RX'ed in NAPI poll · e5597095
      Peng Li authored
      The "FE bit" in the description means the last description for
      a packets. When HW GRO enable, HW write data to ring every
      packet/buffer, there is greater probability that driver handle
      with the describtion but HW still not set the "FE bit".
      
      When drier handle the packet and HW still not set "FE bit",
      driver stores skb and bd_num in rx ring, and continue to use the
      skb and bd_num in next napi.
      Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
      Signed-off-by: default avatarSalil Mehta <salil.mehta@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e5597095
    • Peng Li's avatar
      net: hns3: Enable HW GRO for Rev B(=0x21) HNS3 hardware · b26a6fea
      Peng Li authored
      HNS3 hardware Revision B(=0x21) supports Hardware GRO feature. This
      patch enables this feature in the HNS3 PF/VF driver.
      Signed-off-by: default avatarPeng Li <lipeng321@huawei.com>
      Signed-off-by: default avatarSalil Mehta <salil.mehta@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b26a6fea
    • Heiner Kallweit's avatar
      net: phy: icplus: add config_intr callback · ba2f55b0
      Heiner Kallweit authored
      Move IRQ configuration for IP101A/G from config_init to config_intr
      callback. Reasons:
      
      1. This allows phylib to disable interrupts if needed.
      2. Icplus was the only driver supporting interrupts w/o defining a
         config_intr callback. Now we can add a phylib plausibility check
         disabling interrupt mode if one of the two irq-related callbacks
         isn't defined.
      
      I don't own hardware with this PHY, and the change is based on the
      datasheet for IP101A LF (which is supposed to be register-compatible
      with IP101A/G). Change is compile-tested only.
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
      Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ba2f55b0
  2. 14 Nov, 2018 26 commits
  3. 13 Nov, 2018 2 commits