1. 13 Oct, 2015 9 commits
    • David S. Miller's avatar
      Merge branch 'be2net-fixes' · 1f225031
      David S. Miller authored
      Sathya Perla says:
      
      ====================
      be2net: patch set
      
      Patch 1 fixes a FW image compatibility check in the driver that
      prevents certain FW images from being flashed on BE3 (not BE3-R)
      adapters.
      
      Patch 2 fixes a spin_lock not being released in a failure case in
      be_cmd_notify_wait().
      
      Patch 3 includes a workaround to pad packets that are only 32b long or less
      to be applicabe to BE3 too. This workaround was currently applied only to
      Skyhawk and Lancer chips. Such packets are causing BE3's TX path to stall
      on a SR-IOV config.
      
      Patch 4 fixes the be_cmd_get_profile_config() routine to set the pf_num
      field in the cmd request. The FW requires this field to be set for it to
      return the specific function's descriptors. If not set, the FW returns
      the descriptors of all the functions on the device. If the first descriptor
      is not what is being queried for, the driver will read wrong data.
      This patch fixes this issue by using the GET_CNTL_ATTRIB cmd to query the
      real pci_func_num of a function and then uses it in the GET_PROFILE_CONFIG
      cmd.
      
      Patch 5 completes an earlier fix that removed the vlan promisc capability
      for VFs. The earlier fix did not update the removal of this capability from
      the profile descriptor of the VF. This causes the VF driver to request this
      capability when it tries to create it's interface at probe time. This could
      potentailly cause the VF probe to fail if the FW enforces strict checking of
      the flags based on what was provisoned by the PF.  This strict checking is
      not being done by FW currently but will be fixed in a future version. This
      patch fixes this issue by updating the VF's profile descriptor so that they
      match the interface capability flags provisioned by the PF.
      
      Pls consider adding these patches to the net tree. Thanks!
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1f225031
    • Kalesh AP's avatar
      be2net: remove vlan promisc capability from VF's profile descriptors · 196e3735
      Kalesh AP authored
      The commit 435452aa ("Prevent VFs from enabling VLAN promiscuous mode")
      fixed the PF driver to not include the VLAN promisc capability while
      provisioning the interface for a VF. But the fix did not remove this
      capability from the profile descriptor of the VF. This causes the VF
      driver to request this capability when it tries to create it's interface
      at probe time.  This could potentailly cause the VF probe to fail if the
      FW enforces strict checking of the flags based on what was provisoned
      by the PF.  This strict checking is not being done by FW currently but
      will be fixed in a future version. This patch fixes this issue by updating
      the VF's profile descriptor so that they match the interface capability
      flags provisioned by the PF.
      
      Fixes: 435452aa ("Prevent VFs from enabling VLAN promiscuous mode")
      Signed-off-by: default avatarKalesh AP <kalesh.purayil@avagotech.com>
      Signed-off-by: default avatarSathya Perla <sathya.perla@avagotech.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      196e3735
    • Somnath Kotur's avatar
      be2net: set pci_func_num while issuing GET_PROFILE_CONFIG cmd · 72ef3a88
      Somnath Kotur authored
      The FW requires the pf_num field in the cmd hdr to be set for it to return
      the specific function's descriptors in the GET_PROFILE_CONFIG cmd. If not
      set, the FW returns the descriptors of all the functions on the device.
      If the first descriptor is not what is being queried for, the driver will
      read wrong data. This patch fixes this issue by using the GET_CNTL_ATTRIB
      cmd to query the real pci_func_num of a function and then uses it in the
      GET_PROFILE_CONFIG cmd.
      Signed-off-by: default avatarSomnath Kotur <somnath.kotur@emulex.com>
      Signed-off-by: default avatarSathya Perla <sathya.perla@avagotech.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      72ef3a88
    • Suresh Reddy's avatar
      be2net: pad skb to meet minimum TX pkt size in BE3 · 8227e990
      Suresh Reddy authored
      On BE3 chips in SRIOV configs, the TX path stalls when a packet less
      than 32B is received from the host. A workaround to pad such packets
      already exists for the Skyhawk and Lancer chips. Use the same workaround
      for BE3 chips too.
      Signed-off-by: default avatarSuresh Reddy <suresh.reddy@avagotech.com>
      Signed-off-by: default avatarSathya Perla <sathya.perla@avagotech.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      8227e990
    • Suresh Reddy's avatar
      be2net: release mcc-lock in a failure case in be_cmd_notify_wait() · 0c884567
      Suresh Reddy authored
      The mcc/mbox lock is not being released when be_cmd_copy() returns
      an error.
      Signed-off-by: default avatarSuresh Reddy <suresh.reddy@avagotech.com>
      Signed-off-by: default avatarSathya Perla <sathya.perla@avagotech.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      0c884567
    • Kalesh AP's avatar
      be2net: fix BE3-R FW download compatibility check · ae4a9d6a
      Kalesh AP authored
      In the BE3 FW image, unlike Skyhawk's, the "asic_type_rev" field doesn't
      track the asic_rev of chip it is compatible with. When asic_type_rev
      is 0 the image is compatible only with pre-BE3-R chips (asic_rev < 0x10).
      Fix the current compatibility check to take care of this.
      We hit this issue when we try to flash old BE3 images (used prior to the
      release of BE3-R) on pre-BE3-R adapters.
      
      Fixes: a6e6ff6e ("be2net: simplify UFI compatibility checking")
      Signed-off-by: default avatarKalesh AP <kalesh.purayil@avagotech.com>
      Signed-off-by: default avatarSathya Perla <sathya.perla@avagotech.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ae4a9d6a
    • Gerlando Falauto's avatar
      net/fsl_pq_mdio: fix computed address for the TBI register · 3bb35ac4
      Gerlando Falauto authored
      commit afae5ad7
        "net/fsl_pq_mdio: streamline probing of MDIO nodes"
      
      added support for different types of MDIO devices:
      1) Gianfar MDIO nodes that only map the MII registers
      2) Gianfar MDIO nodes that map the full MDIO register set
      3) eTSEC2 MDIO nodes (which map the full MDIO register set)
      4) QE MDIO nodes (which map only the MII registers)
      
      However, the implementation for types 1 and 4 would mistakenly assume
      a mapping of the full MDIO register set, thereby computing the address
      for the TBI register starting from the containing structure.
      The TBI register would therefore be accessed at a wrong (much bigger)
      address, not giving the expected result at all.
      This patch restores the correct behavior we had prior to the above one.
      
      The consequences of this bug are apparent when trying to access a PHY
      with the same address as the value contained in the initial value of
      the TBI register (normally 0); in that case you'll get answers from the
      internal TBI device (even though MDIO/MDC pins are actually *also*
      toggling on the physical bus!).
      Beware that you also need to add a fake tbi node to your device tree
      with an unused address.
      
      Notice how this fix is related to commit
      22066949
        "powerpc: Add TBI PHY node to first MDIO bus"
      
      which fixed the behavior in kernel 3.3, which was later broken by the
      above commit on kernel 3.7.
      Signed-off-by: default avatarGerlando Falauto <gerlando.falauto@keymile.com>
      Cc: Timur Tabi <timur@tabi.org>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Kumar Gala <galak@kernel.crashing.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      3bb35ac4
    • Gerlando Falauto's avatar
      net/fsl_pq_mdio: check TBI address for consistency with mapped range · 3dd03e52
      Gerlando Falauto authored
      When configuring the MDIO subsystem it is also necessary to configure
      the TBI register. Make sure the TBI is contained within the mapped
      register range in order to:
      a) make sure the address is computed correctly
      b) make users aware that we're actually accessing that register
      
      In case of error, print a message but continue anyway.
      Signed-off-by: default avatarGerlando Falauto <gerlando.falauto@keymile.com>
      Cc: Timur Tabi <timur@tabi.org>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Kumar Gala <galak@kernel.crashing.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      3dd03e52
    • Arad, Ronen's avatar
      rtnetlink: fix gcc -Wconversion warning · e8444637
      Arad, Ronen authored
      RTA_ALIGNTO is currently define as 4. It has to be 4U to prevent warning
      for RTA_ALIGN and RTA_DATA expansions when -Wconversion gcc option is
      enabled.
      This follows NLMSG_ALIGNTO definition in <include/uapi/linux/netlink.h>.
      Signed-off-by: default avatarRonen Arad <ronen.arad@intel.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e8444637
  2. 11 Oct, 2015 7 commits
  3. 09 Oct, 2015 5 commits
  4. 08 Oct, 2015 6 commits
  5. 07 Oct, 2015 13 commits