Kumar Sanghvi [Wed, 19 Feb 2014 07:11:12 +0000 (12:41 +0530)]
linux-next-cherry-picks: Bring upstream fixes on cxgb4
Bring below upstream fixes on cxgb4: f0a8e6d cxgb4: Add more PCI device ids. 0034b29 cxgb4: Don't assume LSO only uses SGL path in t4_eth_xmit() c1f49e3 cxgb4: Remove unused registers and add missing ones 1ac0f09 cxgb4: Query firmware for T5 ULPTX MEMWRITE DSGL capabilities 4fe44dd cxgb4: LE-Workaround is not atomic in firmware 57d8b76 cxgb4: Allow >10G ports to have multiple queues a94cd70 cxgb4: Print adapter VPD Part Number instead of Engineering Change field 72aca4b cxgb4: Add support to recognize 40G links
This adds support for Chelsio 40G adapters.
And also, brings in misc. fixes on cxgb4 for T4 and T5 adapters.
Kumar Sanghvi [Tue, 18 Feb 2014 10:47:57 +0000 (16:17 +0530)]
linux-next-cherry-picks: Bring upstream fix on RDMA/cxgb4 LE-Workaround path
This brings upstream fix 0f01320 (RDMA/cxgb4: Add missing neigh_release in LE-Workaround path),
and makes corresponding backport adjustment.
This resolves OFED Bugzilla Bug#2459
Commit c1be5232d21d "Fix micro UAR allocator" broke binary compatibility
between libmlx5 and mlx5_ib since it defines a different value to the number of
micro UARs per page, leading to wrong calculation in libmlx5. This patch
defines struct mlx5_ib_alloc_ucontext_req_v2 as an extension to struct
mlx5_ib_alloc_ucontext_req. The extended size is determined in
mlx5_ib_alloc_ucontext() and in case of old library we use uuarn 0 which works
fine -- this is acheived due to create_user_qp() falling back from high to
medium then to low class where low class will return 0. For new libraries we
use the more sophisticated allocation algorithm.
Issue: 371069
Change-Id: I43b67013e11f4c8dc395b4920118fe2831ffe19d Fixes: c1be5232d21d ('Fix micro UAR allocator') Signed-off-by: Eli Cohen <eli@mellanox.com> Signed-off-by: Vladimir Sokolovsky <vlad@mellanox.com>
Mike Marciniszyn [Tue, 14 Jan 2014 14:51:50 +0000 (09:51 -0500)]
truescale.cmds: fix many issues with irqbalance banning
The following issues are addressed:
- Detect --banirq vs. IRQ_BALANCE_BANNED_INTERRUPTS
- Configure --banirq vs. IRQ_BALANCE_BANNED_INTERRUPTS
- Detect unconfigurable banning (SLES11SP2/3)
- Determine service name correctly
- Use grep to cut out qib interrupts from banned configuration
This patch also adds the shell comment line to better
support invokation from udev.
Signed-off-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Mitko Haralanov [Fri, 10 Jan 2014 16:41:30 +0000 (11:41 -0500)]
truescale.cmds: Adjust QME724x TX tunings based on BP version
The Dell blade chassis got an updated backplane which
requires new transmitter tuning settings. With this
change the tuning script will query the driver for the
backplane version and set the TX settings according to
BP version and slot in the chassis.
Mitko Haralanov [Fri, 10 Jan 2014 16:41:29 +0000 (11:41 -0500)]
truescale.cmds: Ban irqbalance from re-arranging our IRQs
We've already assigned our IRQs to the proper cores and
we don't want irqbalance messing with them. Use the
IRQBALANCE_BANNED_INTERRUPTS environment variable to
stop irqbalance from re-arranging our IRQs.
Mitko Haralanov [Fri, 10 Jan 2014 16:41:28 +0000 (11:41 -0500)]
truescale.cmds: Wait for /dev/ipath* devices before changing permissions
Wait for up to 30 seconds for the /dev/ipath* devices to appear
before attempting to change their permissions. This helps with
system which boot a bit slower on which the device permissions
could be left in the wrong state.
Kumar Sanghvi [Tue, 24 Dec 2013 18:42:01 +0000 (00:12 +0530)]
linux-next-cherry-picks: Misc fixes for Chelsio T4/T5
This patch brings-in the following linux-next commits:
d14807d cxgb4: Much cleaner implementation of is_t4()/is_t5() 16e4762 cxgb4: Add new scheme to update T4/T5 firmware b6f8eae cxgb4: Reserve stid 0 for T4/T5 adapters 7c89e55 cxgb4: Include TCP as protocol when creating server filters 470c60c cxgb4: Assign filter server TIDs properly 15f63b7 cxgb4: Account for stid entries properly in case of IPv6 dcf7b6f cxgb4: Add API to correctly calculate tuple fields a4ea025 RDMA/cxgb4: Calculate the filter server TID properly 8c04469 RDMA/cxgb4: Server filters are supported only for IPv4 41b4f86 RDMA/cxgb4: Use cxgb4_select_ntuple to correctly calculate ntuple fields
mlx4_core: Roll back round robin bitmap allocation commit for CQs, SRQs, and MPTs
Commit f4ec9e9 "mlx4_core: Change bitmap allocator to work in round-robin fashion"
introduced round-robin allocation (via bitmap) for all resources which allocate
via a bitmap.
Round robin allocation is desirable for mcgs, counters, pd's, UARs, and xrcds.
These are simply numbers, with no involvement of ICM memory mapping.
Round robin is required for QPs, since we had a problem with immediate
reuse of a 24-bit QP number (commit f4ec9e9).
However, for other resources which use the bitmap allocator and involve
mapping ICM memory -- MPTs, CQs, SRQs -- round-robin is not desirable.
What happens in these cases is the following:
ICM memory is allocated and mapped in chunks of 256K.
Since the resource allocation index goes up monotonically, the allocator
will eventually require mapping a new chunk. Now, chunks are also unmapped
when their reference count goes back to zero. Thus, if a single app is
running and starts/exits frequently we will have the following situation:
When the app starts, a new chunk must be allocated and mapped.
When the app exits, the chunk reference count goes back to zero, and the
chunk is unmapped and freed. Therefore, the app must pay the cost of allocation
and mapping of ICM memory each time it runs (although the price is paid only when
allocating the initial entry in the new chunk).
For apps which allocate MPTs/SRQs/CQs and which operate as described above,
this presented a performance problem.
We therefore roll back the round-robin allocator modification for MPTs, CQs, SRQs.
Reported-by: Matthew Finlay <matt@mellanox.com> Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il> Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com> Signed-off-by: Vladimir Sokolovsky <vlad@mellanox.com>
Tatyana Nikolova [Thu, 13 Dec 2012 17:49:44 +0000 (11:49 -0600)]
RDMA/nes: Fixes for OFED-3.5 RC3
1. Backports for ethtool ops (which allow turning on/off tx, rx, sg, tso)
are added for RHEL 6.2 and 6.3
2. Fix for crash caused by improper skb ip_summed field setting
when tx checksum is disabled
3. Fix for crash when registering MR with zero length
Vipul Pandya [Wed, 7 Nov 2012 14:13:26 +0000 (06:13 -0800)]
cxgb4: Fix initialization of SGE_CONTROL register
INGPADBOUNDARY_MASK is already shifted. No need to shift it again. On reloading
a driver it was resulting in a bad SGE FL MTU sizes [1536, 9088] error. This
only causes an issue on systems that have L1 cache size of 32B, 128B, 512B,
2048B or 4096B.
Signed-off-by: Jay Hernandez <jay@chelsio.com> Signed-off-by: Vipul Pandya <vipul@chelsio.com>
Vipul Pandya [Tue, 6 Nov 2012 12:31:47 +0000 (04:31 -0800)]
cxgb4: Add embedded firmware and its configuration file support
In case if firmware is not preset at /lib/firmware/cxgb4/t4fw.bin location and
its configuration file is not present at /lib/firmware/cxgb4/t4-config.txt
location then these embedded firmware and configuration file present in the
driver will be loaded and adapter will get initialised with it.
Vipul Pandya [Wed, 31 Oct 2012 16:39:01 +0000 (09:39 -0700)]
cxgb4/iw_cxgb4: Add LE hash collision bug fix for active and passive offloaded connections
If the hash functionality is enabled in T4 than tuple information of active and
passive offloaded connections are stored in DDR3 memory. LE (Lookup Engine)
implements the interface to search this tuple entries using hash algorithm. If
the number of offloaded connections exceeds the number of maximum hash entries
in DDR3 memory then LE hash collision can occur. To avoid this, driver will
take different path for offloading active and passive connections.
In case of active connection, firmware detects LE hash collision situation and
notifies driver. Driver uses fw_ofld_connection work request to offload that
connection and stores its tuple information in TCAM memory array.
Incase of passive connection, server filter region is created in TCAM. This
region stores the filter which will redirect the incoming SYN packet to offload
queues. After this driver tries to establish the connection using firmware work
request.
This patch series also adds framework for managing filters and to use T4's filter
capabilities.
RDMA/nes: Replace 0009-RDMA-nes-Fix-for-unlinking-NULL-skb.patch with 0009-RDMA-nes-Forward-fpdus-inorder.patch
Locking fix to prevent race conditions.
It forces all fpdus per QP to be forwarded to hardware in order of their tcp sequence numbers.
Vipul Pandya [Wed, 31 Oct 2012 16:36:55 +0000 (09:36 -0700)]
cxgb4: Fix unable to get UP event from the LLD
If T4 configuration file gets loaded from the /lib/firmware/cxgb4/ directory
then offload capabilities of the cards were getting disabled during
initialization. Hence ULDs do not get an UP event from the LLD.
Bart Van Assche [Thu, 18 Oct 2012 12:47:21 +0000 (14:47 +0200)]
ib_srp: Add post-3.5 upstream patches
The following three patches have been accepted upstream after kernel
3.5 was released:
- IB-srp-Fix-a-race-condition: avoid that late replies can trigger
a crash.
- IB-srp-Fix-use-after-free-in-srp_reset_req
- IB-srp-Avoid-having-aborted-requests-hang
Add these patches to OFED 3.5.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Vipul Pandya [Wed, 17 Oct 2012 07:48:48 +0000 (13:18 +0530)]
linux-next-cherry-picks: Fix build failure for kernel < 3.2
0004-cxgb4-cxgb4vf-Code-cleanup-to-enable-T4-Configuratio.patch was removing
some defines and enums unconditionally which were being used for kernel < 3.2
This patch adjusts above patch and checks the kernel version before removing
defines and enums.
Bart Van Assche [Fri, 12 Oct 2012 12:03:26 +0000 (14:03 +0200)]
ib_srp: Avoid that module removal can trigger a deadlock
Avoid that scsi_remove_host() is invoked from the context of a work
queue thread on which work has been queued that scsi_remove_host()
might be waiting for. That avoids that module removal of ib_srp
triggers a deadlock on a pre-2.6.36 kernel. This patch has been
tested on RHEL 6.1, RHEL 6.2, RHEL 6.3 and SLES 11 SP2.
Reported-by: Rupert Dance <rsdance@soft-forge.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Bart Van Assche [Thu, 4 Oct 2012 08:52:18 +0000 (10:52 +0200)]
ib_srp: Unbreak build on SLES 11 SP2
Use the <scsi/srp.h> header from compat-rdma instead of the
<scsi/srp.h> header from the kernel-devel package provided by
the OS for the srp_cred_req and related structure definitions.
Also, undefine pr_fmt() before redefining it since the
compat-rdma build process includes <linux/printk.h> from the
command line.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Vipul Pandya [Fri, 5 Oct 2012 10:32:32 +0000 (03:32 -0700)]
cxgb4: Add support for T4 configuration file
This patch adds patch series from linux-next tree to add support for T4
configuration file.
Starting with T4 firmware version 1.3.11.0 the firmware now supports device
configuration via a Firmware Configuration File. The Firmware Configuration
File was primarily developed in order to centralize all of the configuration,
resource allocation, etc. for Unified Wire operation where multiple
Physical / Virtual Function Drivers would be using a T4 adapter simultaneously.
The Firmware Configuration file can live in three locations as shown below
in order of precedence.
1) User defined configuration file: /lib/firmware/cxgb4/t4-config.txt
2) Factory Default configuration file written to FLASH within
the manufacturing process.
3) Hardwired driver configuration.
The meaning of the "Required-Stop" tag is which services must be
available during shutdown of a service. Avoid specifying the same
runlevel for the "Default-Start" and "Default-Stop" tag. Also,
the default start runlevels on Debian are 2, 3, 4 and 5.
See also http://refspecs.linuxfoundation.org/LSB_3.2.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html.
Signed-off-by: Bart Van Assche <bvanassche@acm.org>