1. 11 Jan, 2013 7 commits
  2. 10 Jan, 2013 20 commits
  3. 09 Jan, 2013 9 commits
  4. 08 Jan, 2013 4 commits
    • Jiri Pirko's avatar
      ethtool: consolidate work with ethtool_ops · c03a14e8
      Jiri Pirko authored
      No need to check if ethtool_ops == NULL since it can't be.
      Use local variable "ops" in functions where it is present
      instead of dev->ethtool_ops
      Introduce local variable "ops" in functions where dev->ethtool_ops is used
      many times.
      Signed-off-by: default avatarJiri Pirko <jiri@resnulli.us>
      Reviewed-by: default avatarBen Hutchings <bhutchings@solarflare.com>
      Reviewed-by: default avatarFlavio Leitner <fbl@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c03a14e8
    • Ariel Elior's avatar
      bnx2x: Segregate SR-IOV code · 6411280a
      Ariel Elior authored
      In this patch the SR-IOV code is segregated from the main bulk of
      the bnx2x code. The CONFIG_BNX2X_SRIOV define is added to Broadcom's
      Kconfig, and allows the elision of the building of all the SR-IOV
      support code in the driver.
      The define is dependant on the kernel CONFIG_PCI_IOV configuration
      define.
      Signed-off-by: default avatarAriel Elior <ariele@broadcom.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6411280a
    • Frank Li's avatar
      net: fec: report correct hardware stamping info to ethtool · 5ebae489
      Frank Li authored
      Report correct hardware stamping capability by ethtool interface.
      The v1.0 ptp4l check it.
      Signed-off-by: default avatarFrank Li <Frank.Li@freescale.com>
      Acked-by: default avatarSascha Hauer <s.hauer@pengutronix.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5ebae489
    • Eric Dumazet's avatar
      veth: avoid a NULL deref in veth_stats_one · d0e2c55e
      Eric Dumazet authored
      commit 2681128f (veth: extend device features) added a NULL deref
      in veth_stats_one(), as veth_get_stats64() was not testing if the peer
      device was setup or not.
      
      At init time, we call dev_get_stats() before veth pair is fully setup.
      
      [  178.854758]  [<ffffffffa00f5677>] veth_get_stats64+0x47/0x70 [veth]
      [  178.861013]  [<ffffffff814f0a2d>] dev_get_stats+0x6d/0x130
      [  178.866486]  [<ffffffff81504efc>] rtnl_fill_ifinfo+0x47c/0x930
      [  178.872299]  [<ffffffff81505b93>] rtmsg_ifinfo+0x83/0x100
      [  178.877678]  [<ffffffff81505cc6>] rtnl_configure_link+0x76/0xa0
      [  178.883580]  [<ffffffffa00f52fa>] veth_newlink+0x16a/0x350 [veth]
      [  178.889654]  [<ffffffff815061cc>] rtnl_newlink+0x4dc/0x5e0
      [  178.895128]  [<ffffffff81505e1e>] ? rtnl_newlink+0x12e/0x5e0
      [  178.900769]  [<ffffffff8150587d>] rtnetlink_rcv_msg+0x11d/0x310
      [  178.906669]  [<ffffffff81505760>] ? __rtnl_unlock+0x20/0x20
      [  178.912225]  [<ffffffff81521f89>] netlink_rcv_skb+0xa9/0xd0
      [  178.917779]  [<ffffffff81502d55>] rtnetlink_rcv+0x25/0x40
      [  178.923159]  [<ffffffff815218d1>] netlink_unicast+0x1b1/0x230
      [  178.928887]  [<ffffffff81521c4e>] netlink_sendmsg+0x2fe/0x3b0
      [  178.934615]  [<ffffffff814dbe22>] sock_sendmsg+0xd2/0xf0
      
      So we must check if peer was setup in veth_get_stats64()
      
      As pointed out by Ben Hutchings, priv->peer is missing proper
      synchronization. Adding RCU protection is a safe and well documented
      way to make sure we don't access about to be freed or already
      freed data.
      Reported-by: default avatarTom Parkin <tparkin@katalix.com>
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      CC: Ben Hutchings <bhutchings@solarflare.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      d0e2c55e