1. 20 8月, 2016 27 次提交
    • J
      i40e: fix broken i40e_config_rss_aq function · 776b2e15
      Jacob Keller 提交于
      X722 hardware requires using the admin queue to configure RSS. This
      function was previously re-written in commit e69ff813 ("i40e: rework
      the functions to configure RSS with similar parameters").
      However, the previous refactor did not work correctly for a few reasons
      
      (a) it does not check whether seed is NULL before using it, resulting in
      a NULL pointer dereference
      
      [  402.954721] BUG: unable to handle kernel NULL pointer dereference at           (null)
      [  402.955568] IP: [<ffffffffa0090ccf>] i40e_config_rss_aq.constprop.65+0x2f/0x1c0 [i40e]
      [  402.956402] PGD ad610067 PUD accc0067 PMD 0
      [  402.957235] Oops: 0000 [#1] SMP
      [  402.958064] Modules linked in: ip6t_rpfilter ip6t_REJECT nf_reject_ipv6 xt_conntrack ip_set nfnetlink ebtable_filter ebtable_
      broute bridge stp llc ebtable_nat ebtables ip6table_mangle ip6table_raw ip6table_nat nf_conntrack_ipv6 nf_defrag_ipv6 nf_nat_ipv
      6 ip6table_security ip6table_filter ip6_tables iptable_mangle iptable_raw iptable_nat nf_conntrack_ipv4_ nf_defrag_ipv4_ nf_nat_ip
      v4_ nf_nat nf_conntrack iptable_security intel_rapl i86_kg_temp_thermal coretemp kvm_intel kvm irqbypass crct10dif_clMl crc32_
      pclMl ghash_clMlni_intel iTCO_wdt iTCO_vendor_support shpchp sb_edac dcdbas pcspkr joydev ipmi_devintf wmi edac_core ipmi_ssif
       acpi_ad acpi_ower_meter ipmi_si ipmi_msghandler mei_me nfsd lpc_ich mei ioatdma tpm_tis auth_rpcgss tpm nfs_acl lockd grace s
      unrpc ifs nngag200 i2c_algo_bit drm_kms_helper ttm drm iigbe bnx2x i40e dca mdio ptp pps_core libcrc32c fjes crc32c_intel
      [  402.965563] CPU: 22 PID: 2461 Conm: ethtool Not tainted 4.6.0-rc7_1.2-ABNidQ+ #20
      [  402.966719] Hardware name: Dell Inc. PowerEdge R720/0C4Y3R, BIOS 2.5.2 01/28/2015
      [  402.967862] task: ffff880219b51dc0 ti: ffff8800b3408000 task.ti: ffff8800b3408000
      [  402.969046] RIP: 0010:[<ffffffffa0090ccf>]  [<ffffffffa0090ccf>] i40e_config_rss_aq.constprop.65+0x2f/0x1c0 [i40e]
      [  402.970339] RSP: 0018:ffff8800b340ba90  EFLAGS: 00010246
      [  402.971616] RAX: 0000000000000000 RBX: ffff88042ec14000 RCX: 0000000000000200
      [  402.972961] RDX: ffff880428eb9200 RSI: 0000000000000000 RDI: ffff88042ec14000
      [  402.974312] RBP: ffff8800b340baf8 R08: ffff880237ada8f0 R09: ffff880428eb9200
      [  402.975709] R10: ffff880428eb9200 R11: 0000000000000000 R12: ffff88042ec2e000
      [  402.977104] R13: ffff88042ec2e000 R14: ffff88042ec14000 R15: ffff88022ea00800
      [  402.978541] FS:  00007f84fd054700(0000) GS:ffff880237ac0000(0000) knlGS:0000000000000000
      [  402.980003] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [  402.981508] CR2: 0000000000000000 CR3: 000000003289e000 CR4: 00000000000406e0
      [  402.983028] Stack:
      [  402.984578]  0000000002000200 0000000000000000 ffff88023ffeda68 ffff88023ffef000
      [  402.986187]  0000000000000268 ffff8800b340bbf8 ffff88023ffedd80 0000000088ce4f1d
      [  402.987844]  ffff88042ec14000 ffff88022ea00800 ffff88042ec2e000 ffff88042ec14000
      [  402.989509] Call Trace:
      [  402.991200]  [<ffffffffa009636f>] i40e_config_rss+0x11f/0x1c0 [i40e]
      [  402.992924]  [<ffffffffa00a1ae0>] i40e_set_rifh+0ic0/0x130 [i40e]
      [  402.994684]  [<ffffffff816d54b7>] ethtool_set_rifh+0x1f7/0x300
      [  402.996446]  [<ffffffff8136d02b>] ? cred_has_capability+0io6b/0x100
      [  402.998203]  [<ffffffff8136d102>] ? selinux_capable+0x12/0x20
      [  402.999968]  [<ffffffff8136277b>] ? security_capable+0x4b/0x70
      [  403.001707]  [<ffffffff816d6da3>] dev_ethtool+0x1423/0x2290
      [  403.003461]  [<ffffffff816eab41>] dev_ioctl+0x191/0io630
      [  403.005186]  [<ffffffff811cf80a>] ? lru_cache_add+0x3a/0i80
      [  403.006942]  [<ffffffff817f2a8e>] ? _raw_spin_unlock+0ie/0x20
      [  403.008691]  [<ffffffff816adb95>] sock_do_ioctl+0x45/0i50
      [  403.010421]  [<ffffffff816ae229>] sock_ioctl+0x209/0x2d0
      [  403.012173]  [<ffffffff81262194>] do_vfs_ioctl+0u4/0io6c0
      [  403.013911]  [<ffffffff81262829>] SyS_ioctl+0x79/0x90
      [  403.015710]  [<ffffffff817f2e72>] entry_SYSCALL_64_fastpath+0x1a/0u4
      [  403.017500] Code: 90 55 48 89 e5 41 57 41 56 41 55 41 54 53 48 89 fb 48 83 ec 40 4c 8b a7 e0 05 00 00 65 48 8b 04 25 28 00 00 00 48 89 45 d0 31 c0 <48> 8b 06 41 0f b7 bc 24 f2 0f 00 00 48 89 45 9c 48 8b 46 08 48
      [  403.021454] RIP  [<ffffffffa0090ccf>] i40e_config_rss_aq.constprop.65+0x2f/0x1c0 [i40e]
      [  403.023395]  RSP <ffff8800b340ba90>
      [  403.025271] CR2: 0000000000000000
      [  403.027169] ---[ end trace 64561b528cf61cf0 ]---
      
      (b) it does not even bother to use the passed in *lut parameter which
      defines the requested lookup table. Instead it uses its own round robin
      table.
      
      Fix these issues by re-writing it to be similar to i40e_config_rss_reg
      and i40e_get_rss_aq.
      
      Fixes: e69ff813 ("i40e: rework the functions to configure RSS with similar parameters", 2015-10-21)
      Signed-off-by: NJacob Keller <jacob.e.keller@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      776b2e15
    • J
      i40e: move i40e_vsi_config_rss below i40e_get_rss_aq · 0582b964
      Jacob Keller 提交于
      Move this function below the two functions related to configuring RSS
      via the admin queue. This helps co-locate the two functions, and made it
      easier to spot a bug in the first i40e_config_rss_aq function as
      compared to the i40e_get_rss_aq function.
      Signed-off-by: NJacob Keller <jacob.e.keller@intel.com>
      Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
      Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      0582b964
    • V
      net/irda: remove pointless assignment/check · dc833def
      Vegard Nossum 提交于
      We've already set sk to sock->sk and dereferenced it, so if it's NULL
      we would have crashed already. Moreover, if it was NULL we would have
      crashed anyway when jumping to 'out' and trying to unlock the sock.
      Furthermore, if we had assigned a different value to 'sk' we would
      have been calling lock_sock() and release_sock() on different sockets.
      
      My conclusion is that these two lines are complete nonsense and only
      serve to confuse the reader.
      Signed-off-by: NVegard Nossum <vegard.nossum@oracle.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      dc833def
    • Y
      qed: utilize FW 8.10.10.0 · 05fafbfb
      Yuval Mintz 提交于
      This new firmware for the qed* adpaters fixes several issues:
       - Better blocking of malicious VFs.
       - After FLR, Tx-switching [internal routing] of packets might
         be incorrect.
       - Deletion of unicast MAC filters would sometime have side-effect
         of corrupting the MAC filters configred for a device.
      It also contains fixes for future qed* drivers that *hopefully* would be
      sent for review in the near future.
      
      In addition, it would allow driver some new functionality, including:
       - Allowing PF/VF driver compaitibility with old drivers [running
         pre-8.10.5.0 firmware].
       - Better debug facilities.
      
      This would also bump the qed* driver versions to 8.10.9.20.
      Signed-off-by: NYuval Mintz <Yuval.Mintz@qlogic.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      05fafbfb
    • D
      Merge branch '10GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue · 75d67207
      David S. Miller 提交于
      Jeff Kirsher says:
      
      ====================
      10GbE Intel Wired LAN Driver Updates 2016-08-18
      
      This series contains updates to ixgbe and ixgbevf.
      
      Emil cleans up confusing amongst the users by making an error message
      into a debug message, since the TXDCTL.ENABLE (and comparable
      VFTXDCTL.ENABLE for ixgbevf) bit is set only when the
      transmit queue is actually enabled, which may not happen during the
      configure phase eve if we waited for it.  Converts to using netdev_dbg()
      macro instead of our home brewed macro for ixgbevf.  Converted the
      service task to use atomic bitwise operations when setting and checking
      reset requests to reduce the possibility of race conditions.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      75d67207
    • D
      Merge branch 'bcm_sf2-platform-dev' · 484387c9
      David S. Miller 提交于
      Florian Fainelli says:
      
      ====================
      net: dsa: bcm_sf2: Platform conversion
      
      This patch series converts the bcm_sf2 driver from a traditional DSA driver
      into a platform_device driver and makes it use the new DSA binding that Andrew
      introduced in the latest merge window.
      
      Prior attempts used to coerce the code in net/dsa/dsa2.c to accept the old
      binding, while really there is only one broken single user out there: bcm_sf2,
      so instead, just assume the new DT binding is deployed and use it accordingly.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      484387c9
    • F
      net: dsa: bcm_sf2: Remove probing through old DSA binding · 731410b7
      Florian Fainelli 提交于
      Remove our dsa_switch_driver::drv_probe callback to prevent probing
      through the old DSA binding, not that this could happen anymore now that
      we have moved the matching compatible string from net/dsa/dsa.c to
      drivers/net/dsa/bcm_sf2.c, so this is essentially dead code.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      731410b7
    • F
      net: dsa: bcm_sf2: Use device managed helpers · 4bd11675
      Florian Fainelli 提交于
      Now that we have converted the drivers into a proper platform device
      driver, we can use the device managed helper functions to simplify the
      error paths a bit wrt. register resources and IRQs.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4bd11675
    • F
      net: dsa: bcm_sf2: Make it a real platform device driver · d9338023
      Florian Fainelli 提交于
      The Broadcom Starfighter 2 switch driver should be a proper platform
      driver, now that the DSA code has been updated to allow that, register a
      switch device, feed it with the proper configuration data coming from
      Device Tree and register our switch device with DSA.
      
      The bulk of the changes consist in moving what bcm_sf2_sw_setup() did
      into the platform driver probe function.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d9338023
    • F
      Documentation: dt: bindings: Update Broadcom 7445 switch document · a85fad14
      Florian Fainelli 提交于
      Document the updated binding which conforms to the new DSA binding in
      net/dsa/dsa.txt.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a85fad14
    • F
      net: dsa: Export suspend/resume functions · ea825e70
      Florian Fainelli 提交于
      In preparation for allowing switch drivers to implement system-wide
      suspend/resume functions, export dsa_switch_suspend and
      dsa_switch_resume() such that these are callable from the appropriate
      driver specific suspend/resume functions.
      Reviewed-by: NAndrew Lunn <andrew@lunn.ch>
      Tested-by: NVivien Didelot <vivien.didelot@savoirfairelinux.com>
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ea825e70
    • D
      Merge branch 'mv88e6xxx-fix-wait' · 0ae940c7
      David S. Miller 提交于
      Andrew Lunn says:
      
      ====================
      Fix mv88e6xxx wait function
      
      The mv88e6xxx wait function can be upset of the system has nots of
      other things to do and a sleep takes a lot longer than expected. Fix
      this be using a fixed number of iterations, rather than a fixed
      walkclock time.
      
      Witht that change made, it is possible to consoliate another
      wait function.
      
      A wait actually timing out should not happen and when it does, it
      means something serious is wrong. Make sure an error is logged,
      since not all callers will log an error.
      ====================
      Reviewed-by: NVivien Didelot <vivien.didelot@savoirfairelinux.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0ae940c7
    • A
      dsa: mv88e6xxx: Make mv88e6xxx_wait() timeout verbose · 30853553
      Andrew Lunn 提交于
      When mv88e6xxx_wait() returns a timeout, something bad has
      happened. Make sure it is noticed by logging an error.
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      30853553
    • A
      dsa: mv88e6xxx: Use mv88e6xx_wait in mv88e6xxx_update() · 0f02b4f7
      Andrew Lunn 提交于
      Now that mv88e6xx_wait() iterated on a counter than a fixed time
      interval, it implements the same mechanism as mv88e6xxx_update() uses.
      So use it in mv88e6xx_wait().
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0f02b4f7
    • A
      dsa: mv88e6xxx: Timeout based on iterations, not time · 6441e669
      Andrew Lunn 提交于
      The mv88e6xxx driver times out operations on the switch based on
      looping until an elapsed wall clock time is reached. However, if
      usleep_range() sleeps much longer than expected, it could timeout with
      an error without actually checking to see if the devices has completed
      the operation. So replace the elapsed time with a fixed upper bound on
      the number of loops.
      
      Testing on various switches has shown that switches takes either 0 or
      1 iteration, so a maximum of 16 iterations is a safe limit.
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6441e669
    • D
      Merge branch 'phy-next' · 7a7e780c
      David S. Miller 提交于
      Andrew Lunn says:
      
      ====================
      PHY Kconfig and Makefile cleanup
      
      The Ethernet PHY directory has slowly been getting more entries.
      Split the entries in the Makefile and Kconfig into MDIO bus drivers
      and PHYs. Within these two groups, sort them. This should reduce merge
      conflicts and aid finding what one searches for.
      
      The Kconfig text contains redundant "Driver for" and "Support for"
      which add little value, make the vendor less obvious, and defeat the
      shortcut key in the menu. Remove such text.
      ====================
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7a7e780c
    • A
      net: phy: Kconfig: Remove redundant "Support for" · 97c84389
      Andrew Lunn 提交于
      Remove the redundant "Support for" and "Drivers for" from the Kconfig
      short description. This makes the manufacture much more prominent in
      the list and makes the shortcut keys useful.
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Acked-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      97c84389
    • A
      net: phy: Sort Makefile and Kconfig · d75b4a22
      Andrew Lunn 提交于
      Sort the files to reduce merge conflicts and to make it easier to find
      drivers by name. Also separate the MDIO bus drivers from the PHY
      drivers, again to help find what you need.
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Acked-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d75b4a22
    • E
      net: ipv4: fix sparse error in fib_good_nh() · d985d151
      Eric Dumazet 提交于
      Fixes following sparse errors :
      
      net/ipv4/fib_semantics.c:1579:61: warning: incorrect type in argument 2
      (different base types)
      net/ipv4/fib_semantics.c:1579:61:    expected unsigned int [unsigned]
      [usertype] key
      net/ipv4/fib_semantics.c:1579:61:    got restricted __be32 const
      [usertype] nh_gw
      
      Fixes: a6db4494 ("net: ipv4: Consider failed nexthops in multipath routes")
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d985d151
    • E
      udp: include addrconf.h · 217375a0
      Eric Dumazet 提交于
      Include ipv4_rcv_saddr_equal() definition to avoid this sparse error :
      
      net/ipv4/udp.c:362:5: warning: symbol 'ipv4_rcv_saddr_equal' was not
      declared. Should it be static?
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      217375a0
    • E
      tcp: md5: remove tcp_md5_hash_header() · b6c6b645
      Eric Dumazet 提交于
      After commit 19689e38 ("tcp: md5: use kmalloc() backed scratch
      areas") this function is no longer used.
      Signed-off-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b6c6b645
    • T
      ibmvnic: Handle backing device failover and reinitialization · dfad09a6
      Thomas Falcon 提交于
      An upcoming feature of IBM VNIC protocol is the ability to configure
      redundant backing devices for a VNIC client. In case of a failure
      on the current backing device, the driver will receive a signal
      from the hypervisor indicating that a failover will occur. The driver
      will then wait for a message from the backing device before
      establishing a new connection.
      Signed-off-by: NThomas Falcon <tlfalcon@linux.vnet.ibm.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      dfad09a6
    • O
      net: hns: Add reset function support for RoCE driver · e0180688
      oulijun 提交于
      It added reset function for RoCE driver. RoCE is a feature of hns.
      In hip06 SoC, in RoCE reset process, it's needed to configure dsaf
      channel reset, port and sl map info. Reset function of RoCE is
      located in dsaf module, we only call it in RoCE driver when needed.
      
      This patch is used to fix the conflict, please refer to this link:
        https://www.spinics.net/lists/linux-rdma/msg39114.htmlSigned-off-by: NWei Hu <xavier.huwei@huawei.com>
      Signed-off-by: NNenglong Zhao <zhaonenglong@hisilicon.com>
      Signed-off-by: NLijun Ou <oulijun@huawei.com>
      Signed-off-by: NSheng Li <lisheng011@huawei.com>
      Reviewed-by: NYisen Zhuang <yisen.zhuang@huawei.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e0180688
    • D
      Merge branch 'rhash-raw-walkers-remove-part-1' · a68d5398
      David S. Miller 提交于
      Herbert Xu says:
      
      ====================
      rhashtable: Get rid of raw table walkers part 1
      
      This series starts the process of getting rid of all raw rhashtable
      walkers (e.g., using any of the rht_for_each helpers) from the
      kernel.
      
      We need to do this before I can fix the resize kmalloc failure issue
      by using multi-layered tables.
      
      We should do this anyway because almost all raw table walkers are
      already buggy in that they don't handle multiple rhashtables during
      a resize.
      ====================
      
      Dave/Tomas, please keep an eye out for any new patches that try
      to introduce raw table walkers and nack them.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a68d5398
    • H
      netlink: Use rhashtable walk interface in diag dump · ad202074
      Herbert Xu 提交于
      This patch converts the diag dumping code to use the rhashtable
      walk code instead of going through rhashtable by hand.  The lock
      nl_table_lock is now only taken while we process the multicast
      list as it's not needed for the rhashtable walk.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ad202074
    • H
      MAINTAINERS: Add extra rhashtable maintainer · 39ec406d
      Herbert Xu 提交于
      As I'm working actively on rhashtable it helps if people CCed me
      when they work on in.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Acked-by: NThomas Graf <tgraf@suug.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      39ec406d
    • H
      rhashtable: Remove GFP flag from rhashtable_walk_init · 246779dd
      Herbert Xu 提交于
      The commit 8f6fd83c ("rhashtable:
      accept GFP flags in rhashtable_walk_init") added a GFP flag argument
      to rhashtable_walk_init because some users wish to use the walker
      in an unsleepable context.
      
      In fact we don't need to allocate memory in rhashtable_walk_init
      at all.  The walker is always paired with an iterator so we could
      just stash ourselves there.
      
      This patch does that by introducing a new enter function to replace
      the existing init function.  This way we don't have to churn all
      the existing users again.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      246779dd
  2. 19 8月, 2016 13 次提交