1. 14 3月, 2018 2 次提交
    • A
      pktgen: use dynamic allocation for debug print buffer · a870a02c
      Arnd Bergmann 提交于
      After the removal of the VLA, we get a harmless warning about a large
      stack frame:
      
      net/core/pktgen.c: In function 'pktgen_if_write':
      net/core/pktgen.c:1710:1: error: the frame size of 1076 bytes is larger than 1024 bytes [-Werror=frame-larger-than=]
      
      The function was previously shown to be safe despite hitting
      the 1024 bye warning level. To get rid of the annoyging warning,
      while keeping it readable, this changes it to use strndup_user().
      
      Obviously this is not a fast path, so the kmalloc() overhead
      can be disregarded.
      
      Fixes: 35951393 ("pktgen: Remove VLA usage")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a870a02c
    • A
      net: fix sysctl_fb_tunnels_only_for_init_net link error · be9fc097
      Arnd Bergmann 提交于
      The new variable is only available when CONFIG_SYSCTL is enabled,
      otherwise we get a link error:
      
      net/ipv4/ip_tunnel.o: In function `ip_tunnel_init_net':
      ip_tunnel.c:(.text+0x278b): undefined reference to `sysctl_fb_tunnels_only_for_init_net'
      net/ipv6/sit.o: In function `sit_init_net':
      sit.c:(.init.text+0x4c): undefined reference to `sysctl_fb_tunnels_only_for_init_net'
      net/ipv6/ip6_tunnel.o: In function `ip6_tnl_init_net':
      ip6_tunnel.c:(.init.text+0x39): undefined reference to `sysctl_fb_tunnels_only_for_init_net'
      
      This adds an extra condition, keeping the traditional behavior when
      CONFIG_SYSCTL is disabled.
      
      Fixes: 79134e6c ("net: do not create fallback tunnels for non-default namespaces")
      Signed-off-by: NArnd Bergmann <arnd@arndb.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      be9fc097
  2. 13 3月, 2018 26 次提交
  3. 12 3月, 2018 12 次提交