Skip to content
  1. Mar 10, 2017
  2. Mar 09, 2017
    • Jiri Pirko's avatar
      mlxsw: spectrum_flower: Remove bogus warns in mlxsw_sp_flower_destroy · 713c43b3
      Jiri Pirko authored
      
      
      This warnings may be hit even in case they should not - in case user
      puts a TC-flower rule which failed to be offloaded. So just remove them.
      
      Reported-by: default avatarPetr Machata <petrm@mellanox.com>
      Reported-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Fixes: commit 7aa0f5aa
      
       ("mlxsw: spectrum: Implement TC flower offload")
      Signed-off-by: default avatarJiri Pirko <jiri@mellanox.com>
      Acked-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      713c43b3
    • David Ahern's avatar
      vrf: Fix use-after-free in vrf_xmit · f7887d40
      David Ahern authored
      KASAN detected a use-after-free:
      
      [  269.467067] BUG: KASAN: use-after-free in vrf_xmit+0x7f1/0x827 [vrf] at addr ffff8800350a21c0
      [  269.467067] Read of size 4 by task ssh/1879
      [  269.467067] CPU: 1 PID: 1879 Comm: ssh Not tainted 4.10.0+ #249
      [  269.467067] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.7.5-20140531_083030-gandalf 04/01/2014
      [  269.467067] Call Trace:
      [  269.467067]  dump_stack+0x81/0xb6
      [  269.467067]  kasan_object_err+0x21/0x78
      [  269.467067]  kasan_report+0x2f7/0x450
      [  269.467067]  ? vrf_xmit+0x7f1/0x827 [vrf]
      [  269.467067]  ? ip_output+0xa4/0xdb
      [  269.467067]  __asan_load4+0x6b/0x6d
      [  269.467067]  vrf_xmit+0x7f1/0x827 [vrf]
      ...
      
      Which corresponds to the skb access after xmit handling. Fix by saving
      skb->len and using the saved value to update stats.
      
      Fixes: 193125db
      
       ("net: Introduce VRF device driver")
      Signed-off-by: default avatarDavid Ahern <dsa@cumulusnetworks.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      f7887d40
    • Jarod Wilson's avatar
      team: use ETH_MAX_MTU as max mtu · 3331aa37
      Jarod Wilson authored
      This restores the ability to set a team device's mtu to anything higher
      than 1500. Similar to the reported issue with bonding, the team driver
      calls ether_setup(), which sets an initial max_mtu of 1500, while the
      underlying hardware can handle something much larger. Just set it to
      ETH_MAX_MTU to support all possible values, and the limitations of the
      underlying devices will prevent setting anything too large.
      
      Fixes: 91572088
      
       ("net: use core MTU range checking in core net infra")
      CC: Cong Wang <xiyou.wangcong@gmail.com>
      CC: Jiri Pirko <jiri@resnulli.us>
      CC: netdev@vger.kernel.org
      Signed-off-by: default avatarJarod Wilson <jarod@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      3331aa37
    • David S. Miller's avatar
      net: Revert ksettings conversions. · aac1561a
      David S. Miller authored
      
      
      Those were supposed to go into the net-next tree not
      the net tree.  Oops...
      
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      aac1561a
    • Christian Lamparter's avatar
      net: ibm: emac: fix regression caused by emac_dt_phy_probe() · b793f081
      Christian Lamparter authored
      Julian Margetson reported a panic on his SAM460EX with Kernel 4.11-rc1:
      | Unable to handle kernel paging request for data at address 0x00000014
      | Oops: Kernel access of bad area, sig: 11 [#1]
      | PREEMPT
      | Canyonlands
      | Modules linked in:
      | CPU: 0 PID: 1 Comm: swapper Not tainted [...]
      | task: ea838000 task.stack: ea836000
      | NIP: c0599f5c LR: c0599dd8 CTR: 00000000
      | REGS: ea837c80 TRAP: 0300   Not tainted [...]
      | MSR: 00029000 <CE,EE,ME>
      |  CR: 24371242  XER: 20000000
      | DEAR: 00000014 ESR: 00000000
      | GPR00: c0599ce8 ea837d30 ea838000 c0e52dcc c0d56ffb [...]
      | NIP [c0599f5c] emac_probe+0xfb4/0x1304
      | LR [c0599dd8] emac_probe+0xe30/0x1304
      | Call Trace:
      | [ea837d30] [c0599ce8] emac_probe+0xd40/0x1304 (unreliable)
      | [ea837d80] [c0533504] platform_drv_probe+0x48/0x90
      | [ea837da0] [c0531c14] driver_probe_device+0x15c/0x2c4
      | [ea837dd0] [c0531e04] __driver_attach+0x88/0xb0
      | ---[ end trace ... ]---
      
      The problem is caused by emac_dt_phy_probe() returing success (0)
      for existing device-trees configurations that do not specify a
      "phy-handle" property. This caused the code to skip the existing
      phy probe and setup. Which led to essential phy related
      data-structures being uninitialized.
      
      This patch also removes the unused variable in emac_dt_phy_connect().
      
      Fixes: a577ca6b
      
       ("net: emac: add support for device-tree based PHY discovery and setup")
      Reported-by: default avatarJulian Margetson <runaway@candw.ms>
      Signed-off-by: default avatarChristian Lamparter <chunkeey@googlemail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b793f081
    • Philippe Reynes's avatar
      net: toshiba: spider_net: use new api ethtool_{get|set}_link_ksettings · 50ad480e
      Philippe Reynes authored
      
      
      The ethtool api {get|set}_settings is deprecated.
      We move this driver to new api {get|set}_link_ksettings.
      
      As I don't have the hardware, I'd be very pleased if
      someone may test this patch.
      
      Signed-off-by: default avatarPhilippe Reynes <tremyfr@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      50ad480e