1. 23 Jan, 2019 25 commits
  2. 22 Jan, 2019 15 commits
    • Xue Chaojing's avatar
      hinic: Add pci device ids · 6679cf09
      Xue Chaojing authored
      This patch adds PCI device IDs to support following cards:
      
      1. Add device id 0x0205 for HINIC 100GE dual port mezz card.
      2. Add device id 0x0210 for HINIC 25GE quad port mezz card.
      3. Delete device id 0x0201 for HINIC 100GE dual port card, because
      this is used by other product.
      4. Macro of device id 0x200 is modified for HINIC 100GE dual port card.
      Signed-off-by: default avatarXue Chaojing <xuechaojing@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6679cf09
    • Heiner Kallweit's avatar
      r8169: remove PCI DAC support · 10b63e85
      Heiner Kallweit authored
      The old non-PCIe chip versions support PCI DAC, however this feature
      seems to be fragile, see comment in the PCI error handler. Therefore
      it's disabled per default. I think meanwhile it's time remove support
      for this legacy feature. This helps to reduce complexity of the driver.
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      10b63e85
    • Heiner Kallweit's avatar
      r8169: improve rx buffer allocation · 6dc8b74b
      Heiner Kallweit authored
      8 years ago, as part of 6f0333b8 ("r8169: use 50% less ram for RX
      ring"), the alignment requirement for rx buffers was silently changed
      from 8 bytes to 16 bytes. I found nothing explaining this, also the
      chip specs I have only mention an 8 byte requirement.
      AFAICS kmalloc_node() guarantees allocated memory to be at least
      "long long" aligned, what is 8 bytes on a 32 bit machine.
      So we can take this memory as-is and avoid some overhead by changing
      the alignment requirement back to 8 bytes.
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6dc8b74b
    • Heiner Kallweit's avatar
      net: phy: improve phy_init_hw · a5996989
      Heiner Kallweit authored
      Currently the soft reset (if defined) is done only if the driver also
      implements the config_init callback. I think this dependency is a
      mistake, so let's remove it.
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a5996989
    • Heiner Kallweit's avatar
      net: phy: fix issue with loading PHY driver w/o initramfs · 21e19442
      Heiner Kallweit authored
      It was reported that on a system with nfsboot and w/o initramfs network
      fails because trying to load the PHY driver returns -ENOENT. Reason was
      that due to missing initramfs the modprobe binary isn't available.
      So we have to ignore error code -ENOENT.
      
      Fixes: 13d0ab67 ("net: phy: check return code when requesting PHY driver module")
      Reported-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Tested-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      21e19442
    • David S. Miller's avatar
      Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue · 0da2b183
      David S. Miller authored
      Jeff Kirsher says:
      
      ====================
      40GbE Intel Wired LAN Driver Updates 2019-01-22
      
      This series contains updates to i40e and xsk.
      
      Jan exports xdp_get_umem_from_qid() for other drivers/modules to use.
      Refactored the code use the netdev provided umems, instead of containing
      them inside our i40e_vsi.
      
      Aleksandr fixes an issue where RSS queues were misconfigured, so limit
      the RSS queue number to the online CPU number.
      
      Damian adds support for ethtool's setting and getting the FEC
      configuration.
      
      Grzegorz fixes a type mismatch, where the return value was not matching
      the function declaration.
      
      Sergey adds checks in the queue configuration handler to ensure the
      number of queue pairs requested by the VF is less than maximum possible.
      
      Lihong cleans up code left around from earlier silicon validation in the
      i40e debugfs code.
      
      Julia Lawall and Colin Ian King clean up white space indentation issues
      found.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      0da2b183
    • David S. Miller's avatar
      Merge branch 'bonding-add-3ad-stats-and-export-them-via-xstats' · cc648f85
      David S. Miller authored
      Nikolay Aleksandrov says:
      
      ====================
      bonding: add 3ad stats and export them via xstats
      
      This set adds support for counting some 3ad-specific packet types and
      exports the new stats via the xstats API. atomic64 counters are used
      since these are not fastpaths and we can avoid the per-cpu allocations.
      Each 3ad counter is exported as a separate attribute to be easily
      extensible since we plan to add more later. The stats are per-slave and
      when the master stats are requested the slaves' stats are summed up.
      Patches 01 and 02 do minor cleanups in preparation for the new stats
      API. Patch 03 adds the new stats and patch 04 adds xstats support to
      export them.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      cc648f85
    • Nikolay Aleksandrov's avatar
      bonding: add support for xstats and export 3ad stats · a258aeac
      Nikolay Aleksandrov authored
      This patch adds support for extended statistics (xstats) call to the
      bonding. The first user would be the 3ad code which counts the following
      events:
       - LACPDU Rx/Tx
       - LACPDU unknown type Rx
       - LACPDU illegal Rx
       - Marker Rx/Tx
       - Marker response Rx/Tx
       - Marker unknown type Rx
      
      All of these are exported via netlink as separate attributes to be
      easily extensible as we plan to add more in the future.
      Similar to how the bridge and other xstats exports, the structure
      inside is:
       [ IFLA_STATS_LINK_XSTATS ]
         -> [ LINK_XSTATS_TYPE_BOND ]
              -> [ BOND_XSTATS_3AD ]
                   -> [ 3ad stats attributes ]
      
      With this structure it's easy to add more stat types later.
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      a258aeac
    • Nikolay Aleksandrov's avatar
      bonding: add 3ad stats · 267c095a
      Nikolay Aleksandrov authored
      Count the following types of 3ad packets per slave:
       - rx/tx lacpdu
       - rx/tx marker
       - rx/tx marker response
       - rx illegal lacpdus (right now counted on wrong length)
       - rx unknown lacpdu type
       - rx unknown marker type
      
      The counters are using atomic64 since this is not fast path.
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      267c095a
    • Nikolay Aleksandrov's avatar
      bonding: 3ad: remove bond_3ad_rx_indication's length argument · dadeb61d
      Nikolay Aleksandrov authored
      Since the received lacpdu is accessed via skb_header_pointer() in
      bond_3ad_lacpdu_recv() we no longer need to check for skb->len's length.
      If the returned lacpdu pointer is not null that should be enough.
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      dadeb61d
    • Nikolay Aleksandrov's avatar
      bonding: adjust style of bond_3ad_rx_indication · 3d021715
      Nikolay Aleksandrov authored
      No functional changes, adjust the style of bond_3ad_rx_indication to
      prepare it for the stats changes:
       - reduce indentation by returning early on wrong length
       - remove extra new lines between switch cases
       - add marker local variable and use it to reduce line length
       - rearrange local variables in reverse xmas tree
       - separate final return
      Signed-off-by: default avatarNikolay Aleksandrov <nikolay@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      3d021715
    • Atul Gupta's avatar
      cxgb4: TLS record offload enable · 1435d997
      Atul Gupta authored
      Enable Inline TLS record by default
      Signed-off-by: default avatarAtul Gupta <atul.gupta@chelsio.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1435d997
    • Atul Gupta's avatar
      net/tls: free ctx in sock destruct · 76f7164d
      Atul Gupta authored
      free tls context in sock destruct. close may not be the last
      call to free sock but force releasing the ctx in close
      will result in GPF when ctx referred again in tcp_done
      
      [  515.330477] general protection fault: 0000 [#1] SMP PTI
      [  515.330539] CPU: 5 PID: 0 Comm: swapper/5 Not tainted 4.20.0-rc7+ #10
      [  515.330657] Hardware name: Supermicro X8ST3/X8ST3, BIOS 2.0b
      11/07/2013
      [  515.330844] RIP: 0010:tls_hw_unhash+0xbf/0xd0
      [
      [  515.332220] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [  515.332340] CR2: 00007fab32c55000 CR3: 000000009261e000 CR4:
      00000000000006e0
      [  515.332519] Call Trace:
      [  515.332632]  <IRQ>
      [  515.332793]  tcp_set_state+0x5a/0x190
      [  515.332907]  ? tcp_update_metrics+0xe3/0x350
      [  515.333023]  tcp_done+0x31/0xd0
      [  515.333130]  tcp_rcv_state_process+0xc27/0x111a
      [  515.333242]  ? __lock_is_held+0x4f/0x90
      [  515.333350]  ? tcp_v4_do_rcv+0xaf/0x1e0
      [  515.333456]  tcp_v4_do_rcv+0xaf/0x1e0
      Signed-off-by: default avatarAtul Gupta <atul.gupta@chelsio.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      76f7164d
    • Atul Gupta's avatar
      net/tls: build_protos moved to common routine · 63a6b3fe
      Atul Gupta authored
      build protos is required for tls_hw_prot also hence moved to
      'tls_build_proto' and called as required from tls_init
      and tls_hw_proto. This is required since build_protos
      for v4 is moved from tls_register to tls_init in
      commit <28cb6f1e>
      Signed-off-by: default avatarAtul Gupta <atul.gupta@chelsio.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      63a6b3fe
    • Cong Wang's avatar
      net: introduce a knob to control whether to inherit devconf config · 856c395c
      Cong Wang authored
      There have been many people complaining about the inconsistent
      behaviors of IPv4 and IPv6 devconf when creating new network
      namespaces.  Currently, for IPv4, we inherit all current settings
      from init_net, but for IPv6 we reset all setting to default.
      
      This patch introduces a new /proc file
      /proc/sys/net/core/devconf_inherit_init_net to control the
      behavior of whether to inhert sysctl current settings from init_net.
      This file itself is only available in init_net.
      
      As demonstrated below:
      
      Initial setup in init_net:
       # cat /proc/sys/net/ipv4/conf/all/rp_filter
       2
       # cat /proc/sys/net/ipv6/conf/all/accept_dad
       1
      
      Default value 0 (current behavior):
       # ip netns del test
       # ip netns add test
       # ip netns exec test cat /proc/sys/net/ipv4/conf/all/rp_filter
       2
       # ip netns exec test cat /proc/sys/net/ipv6/conf/all/accept_dad
       0
      
      Set to 1 (inherit from init_net):
       # echo 1 > /proc/sys/net/core/devconf_inherit_init_net
       # ip netns del test
       # ip netns add test
       # ip netns exec test cat /proc/sys/net/ipv4/conf/all/rp_filter
       2
       # ip netns exec test cat /proc/sys/net/ipv6/conf/all/accept_dad
       1
      
      Set to 2 (reset to default):
       # echo 2 > /proc/sys/net/core/devconf_inherit_init_net
       # ip netns del test
       # ip netns add test
       # ip netns exec test cat /proc/sys/net/ipv4/conf/all/rp_filter
       0
       # ip netns exec test cat /proc/sys/net/ipv6/conf/all/accept_dad
       0
      
      Set to a value out of range (invalid):
       # echo 3 > /proc/sys/net/core/devconf_inherit_init_net
       -bash: echo: write error: Invalid argument
       # echo -1 > /proc/sys/net/core/devconf_inherit_init_net
       -bash: echo: write error: Invalid argument
      Reported-by: default avatarZhu Yanjun <Yanjun.Zhu@windriver.com>
      Reported-by: default avatarTonghao Zhang <xiangxia.m.yue@gmail.com>
      Cc: Nicolas Dichtel <nicolas.dichtel@6wind.com>
      Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
      Acked-by: default avatarNicolas Dichtel <nicolas.dichtel@6wind.com>
      Acked-by: default avatarTonghao Zhang <xiangxia.m.yue@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      856c395c