Skip to content
  1. Nov 15, 2020
  2. Nov 14, 2020
  3. Nov 13, 2020
  4. Nov 12, 2020
    • Heiner Kallweit's avatar
      net: usb: switch to dev_get_tstats64 and remove usbnet_get_stats64 alias · 323955a0
      Heiner Kallweit authored
      
      
      Replace usbnet_get_stats64() with new identical core function
      dev_get_tstats64() in all users and remove usbnet_get_stats64().
      
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Acked-by: default avatarBjørn Mork <bjorn@mork.no>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      323955a0
    • Heiner Kallweit's avatar
      usbnet: switch to core handling of rx/tx byte/packet counters · af0c351c
      Heiner Kallweit authored
      
      
      Use netdev->tstats instead of a member of usbnet for storing a pointer
      to the per-cpu counters. This allows us to use core functionality for
      statistics handling.
      
      Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      af0c351c
    • Vincent Bernat's avatar
      net: evaluate net.ipv4.conf.all.proxy_arp_pvlan · 1af5318c
      Vincent Bernat authored
      
      
      Introduced in 65324144, the "proxy_arp_vlan" sysctl is a
      per-interface sysctl to tune proxy ARP support for private VLANs.
      While the "all" variant is exposed, it was a noop and never evaluated.
      We use the usual "or" logic for this kind of sysctls.
      
      Fixes: 65324144 ("net: RFC3069, private VLAN proxy arp support")
      Signed-off-by: default avatarVincent Bernat <vincent@bernat.ch>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      1af5318c
    • Vincent Bernat's avatar
      net: evaluate net.ipvX.conf.all.ignore_routes_with_linkdown · c0c5a60f
      Vincent Bernat authored
      
      
      Introduced in 0eeb075f, the "ignore_routes_with_linkdown" sysctl
      ignores a route whose interface is down. It is provided as a
      per-interface sysctl. However, while a "all" variant is exposed, it
      was a noop since it was never evaluated. We use the usual "or" logic
      for this kind of sysctls.
      
      Tested with:
      
          ip link add type veth # veth0 + veth1
          ip link add type veth # veth1 + veth2
          ip link set up dev veth0
          ip link set up dev veth1 # link-status paired with veth0
          ip link set up dev veth2
          ip link set up dev veth3 # link-status paired with veth2
      
          # First available path
          ip -4 addr add 203.0.113.${uts#H}/24 dev veth0
          ip -6 addr add 2001:db8:1::${uts#H}/64 dev veth0
      
          # Second available path
          ip -4 addr add 192.0.2.${uts#H}/24 dev veth2
          ip -6 addr add 2001:db8:2::${uts#H}/64 dev veth2
      
          # More specific route through first path
          ip -4 route add 198.51.100.0/25 via 203.0.113.254 # via veth0
          ip -6 route add 2001:db8:3::/56 via 2001:db8:1::ff # via veth0
      
          # Less specific route through second path
          ip -4 route add 198.51.100.0/24 via 192.0.2.254 # via veth2
          ip -6 route add 2001:db8:3::/48 via 2001:db8:2::ff # via veth2
      
          # H1: enable on "all"
          # H2: enable on "veth0"
          for v in ipv4 ipv6; do
            case $uts in
              H1)
                sysctl -qw net.${v}.conf.all.ignore_routes_with_linkdown=1
                ;;
              H2)
                sysctl -qw net.${v}.conf.veth0.ignore_routes_with_linkdown=1
                ;;
            esac
          done
      
          set -xe
          # When veth0 is up, best route is through veth0
          ip -o route get 198.51.100.1 | grep -Fw veth0
          ip -o route get 2001:db8:3::1 | grep -Fw veth0
      
          # When veth0 is down, best route should be through veth2 on H1/H2,
          # but on veth0 on H2
          ip link set down dev veth1 # down veth0
          ip route show
          [ $uts != H3 ] || ip -o route get 198.51.100.1 | grep -Fw veth0
          [ $uts != H3 ] || ip -o route get 2001:db8:3::1 | grep -Fw veth0
          [ $uts = H3 ] || ip -o route get 198.51.100.1 | grep -Fw veth2
          [ $uts = H3 ] || ip -o route get 2001:db8:3::1 | grep -Fw veth2
      
      Without this patch, the two last lines would fail on H1 (the one using
      the "all" sysctl). With the patch, everything succeeds as expected.
      
      Also document the sysctl in `ip-sysctl.rst`.
      
      Fixes: 0eeb075f ("net: ipv4 sysctl option to ignore routes when nexthop link is down")
      Signed-off-by: default avatarVincent Bernat <vincent@bernat.ch>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      c0c5a60f
  5. Nov 11, 2020
  6. Nov 10, 2020
  7. Nov 09, 2020
  8. Nov 07, 2020
  9. Nov 06, 2020
Loading