Sreekanth Reddy [Wed, 11 Nov 2015 12:00:18 +0000 (17:30 +0530)]
mpt3sas: Added mpt2sas driver definitions
1. Added mpt2sas driver related macros in mpt3sas header files
2. Made scsi host's, raid class', pci's, ioctl's callback functions
global so that both drivers can use them.
Signed-off-by: Sreekanth Reddy <Sreekanth.Reddy@avagotech.com> Acked-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Orabug: 22529571
(cherry picked from commit 8a7e4c24e08fceb94887eb6d8123d6059dc5ddcd) Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Christoph Hellwig [Wed, 11 Nov 2015 12:00:17 +0000 (17:30 +0530)]
mpt2sas: Use mpi headers from mpt3sas
Use a single set of the hardware description headers instead of having
them in the source tree twice.
Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Sreekanth Reddy <sreekanth.reddy@avagotech.com> Reviewed-by: Hannes Reinecke <hare@suse.de> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Orabug: 22529571
(cherry picked from commit 3c5866565f37d45e3b812e3045caf2358f2f2377) Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
qed: Protect the doorbell BAR with the write barriers.
SPQ doorbell is currently protected with the compilation barrier. Under the
stress scenarios, we may get into a state where (due to the weak ordering)
several ramrod doorbells were written to the BAR with an out-of-order
producer values. Need to change the barrier type to a write barrier to make
sure that the write buffer is flushed after each doorbell.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 19 Jun 2016 12:18:15 +0000 (15:18 +0300)]
qed: Add missing port-mode
The 'MODULE_FIBER' value replaced several other FIBER values
in newer management firmware images, so existing code would
fail to properly reflect its mode.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 19 Jun 2016 12:18:14 +0000 (15:18 +0300)]
qed: Fix returning unlimited SPQ entries
Driver has 2 sets of entries for handling ramrod configurations
toward firmware - a regular pre-allocated set of entires and a
possible 'unlimited' list of additional pending entries.
In most scenarios the 'unlimited' list would not be used, but
when it does the handling of the ramrod completion doesn't
properly handle the release of the entry.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 19 Jun 2016 12:18:13 +0000 (15:18 +0300)]
qed*: Don't reset statistics on inner reload
Several user APIs can cause driver to perform an inner-reload.
Currently, doing this would cause the HW/FW statistics of the
adapter to reset, which isn't the expected behavior [statistics
should only reset on explicit unloads].
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 19 Jun 2016 12:18:12 +0000 (15:18 +0300)]
qed: Prevent VF from Tx-switching 'promisc'
Internal loopback in driver is based on two things - first
is the willingness of transmitter to use it [in case of VFs,
this can be forced based on VEPA/VEB] and secondly on another
vport classification configuration which should match the
packet's destination.
Current code allows non-linux VFs to configure a 'promisc'
mode on Tx, meaning all traffic sent by VF would be loopbacked
internally by firmware; This isn't considered a valid mode and
as such should be prevented by PF.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 19 Jun 2016 12:18:11 +0000 (15:18 +0300)]
qed: Correct default vlan behavior
When no vlan filter is configured, firmware has a configurable
default on whether to pass only untagged packets or all packets
regardless of their tagging. Driver currently doesn't set this
field in the necessary ramrod, causing the default to always be
'receive all'.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Arnd Bergmann [Wed, 1 Jun 2016 13:29:13 +0000 (15:29 +0200)]
qed: fix qed_fill_link() error handling
gcc warns about qed_fill_link possibly accessing uninitialized data:
drivers/net/ethernet/qlogic/qed/qed_main.c: In function 'qed_fill_link':
drivers/net/ethernet/qlogic/qed/qed_main.c:1170:35: error: 'link_caps' may be used uninitialized in this function [-Werror=maybe-uninitialized]
While this warning is only about the specific case of CONFIG_QED_SRIOV
being disabled but the function getting called for a VF (which should
never happen), another possibility is that qed_mcp_get_*() fails without
returning data.
This rearranges the code so we bail out in either of the two cases
and print a warning instead of accessing the uninitialized data.
The qed_link_output structure remains untouched in this case, but
all callers first call memset() on it, so at least we are not leaking
stack data then.
As discussed, we also use a compile-time check to ensure we never
use any of the VF code if CONFIG_QED_SRIOV is disabled, and the
PCI device table is updated to no longer bind to virtual functions
in that configuration.
Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 26 May 2016 08:01:24 +0000 (11:01 +0300)]
qed: Don't config min BW on 100g on link flap
Currently 100g devices don't support minimum/maximum BW configurations,
yet link flaps might cause the driver to attempt to do such a
configuration. Prevent this just as we do for the maximum BW.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 26 May 2016 08:01:22 +0000 (11:01 +0300)]
qed: Add missing 100g init mode
Some of the HW configurations are currently missing for 100g devices.
This can cause various classification issues, as well as prevent device
from fully reaching line-rate.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 26 May 2016 08:01:21 +0000 (11:01 +0300)]
qed: Save min/max accross dcbx-change
When DCBx re-negotiation is occurring, the PF's configurations for
maximum and minimum bandwidth guarantees are currently lost.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Commit 39651abd2814 ("qed: add support for dcbx") is re-configuring
the QM hw-block as part of its sequence. This is done in attention
handling context which is non-sleepable, yet memory is allocated in
this flow using GFP_KERNEL.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 26 May 2016 08:01:19 +0000 (11:01 +0300)]
qede: Don't expose self-test for VFs
PFs and VFs differ in their registered ethtool operations,
but they're using a common function for get_sset_count().
As a result, `ethtool -i' for a VF would indicate it supports
selftest, although that's not the case.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 26 May 2016 08:01:18 +0000 (11:01 +0300)]
qede: Reload on GRO changes
Since driver is using a FW-based GRO implementation, this has some
effects on its ability to cope with GRO enablement/disablement.
As a result, driver must perform an inner-reload as a result of a state
change in the offload configuration of said feature.
[Failure to do so means network stack would continue to receive
aggregated packets even though user requested the feature to be disabled].
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 26 May 2016 08:01:17 +0000 (11:01 +0300)]
qede: Fix VF minimum BW setting
VF is currently ignoring the minimum provided by the API,
mistakenly using the maximum for minimum as well.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
This patch fixes the coding error in determining the enable flag for
the application/protocol. The enable flag should be set for all protocols
but the eth.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Dan Carpenter [Mon, 23 May 2016 10:19:35 +0000 (13:19 +0300)]
qed: signedness bug in qed_dcbx_process_tlv()
"priority" needs to be signed for the error handling to work.
Fixes: 39651abd2814 ('qed: add support for dcbx.') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Manish Chopra [Wed, 18 May 2016 11:43:57 +0000 (07:43 -0400)]
qede: Fix DMA address APIs usage
Driver incorrectly uses dma_unmap_addr_set() to set
a variable which is in truth a dma_addr_t
[i.e not defined using DEFINE_DMA_UNMAP_ADDR()] and is
being used by the driver flows other than unmapping
physical addresses. This patch fixes driver fastpath
where CONFIG_NEED_DMA_MAP_STATE is not set.
Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
This patch adds the necessary driver support for Management Firmware to
configure the device/firmware with the dcbx results. Management Firmware
is responsible for communicating the DCBX and driving the negotiation,
but the driver has responsibility of receiving async notification and
configuring the results in hw/fw. This patch also adds the dcbx support for
future protocols (e.g., FCoE) as preparation to their imminent submission.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Dan Carpenter [Tue, 17 May 2016 08:09:20 +0000 (11:09 +0300)]
qed: Remove a stray tab
This line was indented more than it should be.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 15 May 2016 11:48:09 +0000 (14:48 +0300)]
qed: VFs gracefully accept lack of PM
VF's probe might log that it has no PM capability in its PCI configuration
space. As this is a valid configuration, silence such prints.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 15 May 2016 11:48:08 +0000 (14:48 +0300)]
qed: Allow more than 16 VFs
In multi-function modes, PFs are currently limited to using 16 VFs -
But that limitation would also currently apply in case there's a single
PCI function exposed, where no such restriction should have existed.
This lifts the restriction for the default mode; User should be able
to start the maximum number of VFs as appear in the PCI config space.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Manish Chopra [Sun, 15 May 2016 11:48:07 +0000 (14:48 +0300)]
qed: Reset link on IOV disable
PF updates its VFs' bulletin boards with link configurations whenever
the physical carrier changes or whenever hyper-user explicitly requires
some setting of the VFs link via the hypervisor's PF.
Since the bulletin board is getting cleaned as part of the IOV disable
flow on the PF side, re-enabling sriov would lead to a VF that sees the
carrier as 'down', until an event causing the PF to re-fill the bulletin
with the link configuration would occur.
To fix this we simply refelect the link state during the flows, giving
the later VFs a default reflecting the PFs link state.
Signed-off-by: Manish Chopra <Manish.Chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 15 May 2016 11:48:06 +0000 (14:48 +0300)]
qed: Improve VF interrupt reset
During FLR flow, need to make sure HW is no longer capable of writing to
host memory as part of its interrupt mechanisms.
While we're at it, unify the logic cleaning the driver's status-blocks
into using a single API function for both PFs and VFs.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 15 May 2016 11:48:05 +0000 (14:48 +0300)]
qed: Correct PF-sanity check
Seems like something broke in commit 1408cc1fa48c ("qed: Introduce VFs")
and the function no longer verifies that the vf is indeed a valid one.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:25 +0000 (16:36 +0300)]
qed*: Tx-switching configuration
Device should be configured by default to VEB once VFs are active.
This changes the configuration of both PFs' and VFs' vports into enabling
tx-switching once sriov is enabled.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:24 +0000 (16:36 +0300)]
qed*: support ndo_get_vf_config
Allows the user to view the VF configuration by observing the PF's
device.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:23 +0000 (16:36 +0300)]
qed*: IOV support spoof-checking
Add support in `ndo_set_vf_spoofchk' for allowing PF control over
its VF spoof-checking configuration.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:22 +0000 (16:36 +0300)]
qed*: IOV link control
This adds support in 2 ndo that allow PF to tweak the VF's view of the
link - `ndo_set_vf_link_state' to allow it a view independent of the PF's,
and `ndo_set_vf_rate' which would allow the PF to limit the VF speed.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:21 +0000 (16:36 +0300)]
qed*: Support forced MAC
Allows the PF to enforce the VF's mac.
i.e., by using `ip link ... vf <x> mac <value>'.
While a MAC is forced, PF would prevent the VF from configuring any other
MAC.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:20 +0000 (16:36 +0300)]
qed*: Support PVID configuration
This adds support for PF control over the VF vlan configuration.
I.e., `ip link ... vf <x> vlan <vid>' should now be supported.
1. <vid> != 0 => VF receives [unknowingly] only traffic tagged by
<vid> and tags all outgoing traffic sent by VF with <vid>.
2. <vid> == 0 ==> Remove the pvid configuration, reverting to previous.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:19 +0000 (16:36 +0300)]
qede: Add VF support
Adding a PCI callback for `sriov_configure' and a new PCI device id for
the VF [+ Some minor changes to accomodate differences between PF and VF
at the qede].
Following this, VF creation should be possible and the entire subset of
existing PF functionality that's allow to VFs should be supported.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:18 +0000 (16:36 +0300)]
qed: Align TLVs
As the VF infrastructure is supposed to offer backward/forward
compatibility, the various types associated with VF<->PF communication
should be aligned across all various platforms that support IOV
on our family of adapters.
This adds a couple of currently missing values, specifically aligning
the enum for the various TLVs possible in the communication between them.
It then adds the PF implementation for some of those missing VF requests.
This support isn't really necessary for the Linux VF as those VFs aren't
requiring it [at least today], but are required by VFs running on other
OSes. LRO is an example of one such configuration.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:17 +0000 (16:36 +0300)]
qed: Bulletin and Link
Up to this point, VF and PF communication always originates from VF.
As a result, VF cannot be notified of any async changes, and specifically
cannot be informed of the current link state.
This introduces the bulletin board, the mechanism through which the PF
is going to communicate async notifications back to the VF. basically,
it's a well-defined structure agreed by both PF and VF which the VF would
continuously poll and into which the PF would DMA messages when needed.
[Bulletin board is actually allocated and communicated in previous patches
but never before used]
Based on the bulletin infrastructure, the VF can query its link status
and receive said async carrier changes.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:16 +0000 (16:36 +0300)]
qed: IOV l2 functionality
This adds sufficient changes to allow VFs l2-configuration flows to work.
While the fastpath of the VF and the PF are meant to be exactly the same,
the configuration of the VF is done by the PF.
This diverges all VF-related configuration flows that originate from a VF,
making them pass through the VF->PF channel and adding sufficient logic
on the PF side to support them.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:15 +0000 (16:36 +0300)]
qed: IOV configure and FLR
While previous patches have already added the necessary logic to probe
VFs as well as enabling them in the HW, this patch adds the ability to
support VF FLR & SRIOV disable.
It then wraps both flows together into the first IOV callback to be
provided to the protocol driver - `configure'. This would later to be used
to enable and disable SRIOV in the adapter.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:14 +0000 (16:36 +0300)]
qed: Introduce VFs
This adds the qed VFs for the first time -
The vfs are limited functions, with a very different PCI bar structure
[when compared with PFs] to better impose the related security demands
associated with them.
This patch includes the logic neccesary to allow VFs to successfully probe
[without actually adding the ability to enable iov].
This includes diverging all the flows that would occur as part of the pci
probe of the driver, preventing VF from accessing registers/memories it
can't and instead utilize the VF->PF channel to query the PF for needed
information.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:13 +0000 (16:36 +0300)]
qed: Add VF->PF channel infrastructure
Communication between VF and PF is based on a dedicated HW channel;
VF will prepare a messge, and by signaling the HW the PF would get a
notification of that message existance. The PF would then copy the
message, process it and DMA an answer back to the VF as a response.
The messages themselves are TLV-based - allowing easier backward/forward
compatibility.
This patch adds the infrastructure of the channel on the PF side -
starting with the arrival of the notification and ending with DMAing
the response back to the VF.
It also adds a dummy-response as reference, as it only lays the
groundwork of the communication; it doesn't really add support of any
actual messages.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 11 May 2016 13:36:12 +0000 (16:36 +0300)]
qed: Add CONFIG_QED_SRIOV
Add support for a new Kconfig option for qed* driver which would allow
[eventually] the support in VFs.
This patch adds the necessary logic in the PF to learn about the possible
VFs it will have to support [Based on PCI configuration space and HW],
and prepare a database with an entry per-VF as infrastructure for future
interaction with said VFs.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
qede requires qed to provide enough resources to accommodate 16 combined
channels, but that upper-bound isn't actually being enforced by it.
Instead, qed inform back to qede how many channels can be opened based on
available resources - but that calculation doesn't really take into account
the resources requested by qede; Instead it considers other FW/HW available
resources.
As a result, if a user would increase the number of channels to more than
16 [e.g., using ethtool] the chip would hang.
This change increments the resources requested by qede to 64 combined
channels instead of 16; This value is an upper bound on the possible
available channels [due to other FW/HW resources].
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
This patch adds the functionality and APIs needed for selftests.
It adds the ability to configure the link-mode which is required for the
implementation of loopback tests. It adds the APIs for clock test,
register test, interrupt test and memory test.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
This patch adds relevant APIs needed to configure WFQ
(Weighted fair queueing) values for the vports. WFQ configuration
is used per vport basis when minimum bandwidth update/configuration
is notified to the PF by the management firmware.
Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
The APIs for making this sort of configuration [e.g., via ethtool] are
already present in qede, but the current configuration flow in qed doesn't
respect it.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
There's some inconsistency in current logic determining whether the
link settings of a given interface can be changed; I.e., in all modes
other than the so-called `deault' mode the interfaces are forbidden from
changing the configuration - but even this rule is not applied to all
user APIs that may change the configuration.
Instead, let the core-module [qed] decide whether an interface can change
the configuration by supporting a new API function. We also revise the
current rule, allowing all interfaces to change their configurations while
laying the infrastructure for future modes where an interface would be
blocked from making such a configuration.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Adds a getter for the interfaces private flags.
The only parameter currently supported is whether the interface is a
coupled function [required for supporting 100g].
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
There's a difference in statsitics' names starting at qed and
propagating to qede, where egress counters indicate ranges while ingress
counters indiciate high-end.
Align all statistcs to follow the same conventions - name indicates range.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
qede: Fix single MTU sized packet from firmware GRO flow
In firmware assisted GRO flow there could be a single MTU sized
segment arriving due to firmware aggregation timeout/last segment
in an aggregation flow, which is not expected to be an actual gro
packet. So If a skb has zero frags from the GRO flow then simply
push it in the stack as non gso skb.
Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <yuval.mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
qed/qede: Add VXLAN tunnel slowpath configuration support
This patch enables VXLAN tunnel on the adapter and
add support for driver hooks to configure UDP ports
for VXLAN tunnel offload to be performed by the adapter.
Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Colin Ian King [Tue, 29 Mar 2016 17:00:50 +0000 (18:00 +0100)]
qed: initialize return rc to avoid returning garbage
in the case where qed_slowpath_irq_req is not called, rc is not
assigned and so qed_int_igu_enable will return a garbage value.
Fix this by initializing rc to 0.
Signed-off-by: Colin Ian King <colin.king@canonical.com> Acked-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 9 Mar 2016 07:16:26 +0000 (09:16 +0200)]
qed: Enlrage the drain timeout
In the scenario where slowpath configuration isn't passing due to
various pause configurations affecting the chip, the theoretical time
required in worst-case-scenario to empty hw fifos sufficiently to
guarantee that slowpath configuration would flow is currently
insufficient.
This increases such a drain request to the theoretical maximum.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Tomer Tayar [Wed, 9 Mar 2016 07:16:24 +0000 (09:16 +0200)]
qed: Major changes to MB locking
Driver interaction with the managemnt firmware is done via mailbox
commands which the management firmware periodically sample, as well
as placing of additional data in set places in the shared memory.
Each PF has a single designated mailbox address, and all flows that
require messaging to the management should use it.
This patch does 2 things:
1. It re-defines the critical section surrounding the mailbox sending -
that section should include the setting of the shared memory as well as
the sending of the command [otherwise a race might send a command with
the data of a different command].
2. It moves the locking scheme from using mutices into using spinlocks.
This lays the groundwork for sending MFW commands from non-sleepable
contexts.
Signed-off-by: Tomer Tayar <Tomer.Tayar@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
When device is configured for Multi-function mode, some older management
firmware might incorrectly notify interfaces of link changes while they
haven't requested the physical link configuration to be set.
This can create bizzare race conditions where unloading interfaces are
getting notified that the link is up.
Let the driver compensate - store the logical requested state of the link
and don't propagate notifications after protocol driver explicitly
requires the link to be unset.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Manish Chopra [Tue, 8 Mar 2016 09:09:44 +0000 (04:09 -0500)]
qede: Fix net-next "make ARCH=x86_64"
'commit 55482edc25f0606851de42e73618f813f310d009
("qede: Add slowpath/fastpath support and enable hardware GRO")'
introduces below error when compiling net-next with "make ARCH=x86_64"
drivers/built-in.o: In function `qede_rx_int':
qede_main.c:(.text+0x6101a0): undefined reference to `tcp_gro_complete'
Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 2 Mar 2016 18:26:04 +0000 (20:26 +0200)]
qed: Remove unused NVM vendor ID
Remove 2 unused fields from driver code.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 2 Mar 2016 18:26:03 +0000 (20:26 +0200)]
qed: Fix error flow on slowpath start
In case of problems when initializing the chip, the error flows aren't
being properly done. Specifically, it's possible that the chip would be
left in a configuration allowing it [internally] to access the host
memory, causing fatal problems in the device that would require power
cycle to overcome.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 2 Mar 2016 18:26:02 +0000 (20:26 +0200)]
qed: Move statistics to L2 code
Current statistics logic is meant for L2, not for all future protocols.
Move this content to the proper designated file.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 2 Mar 2016 18:26:01 +0000 (20:26 +0200)]
qed: Support B0 instead of A0
BB_A0 is a development model that is will not reach actual clients.
In fact, future firmware would simply fail to initialize such chip.
This changes the configuration into B0 instead of A0, and adds a safeguard
against the slim chance someone would actually try this with an A0 adapter
in which case probe would gracefully fail.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Ram Amrani [Wed, 2 Mar 2016 18:26:00 +0000 (20:26 +0200)]
qed: Correct BAR sizes for older MFW
Driver learns the inner bar sized from a register configured by management
firmware, but older versions are not setting this register.
But since we know which values were configured back then, use them instead.
Signed-off-by: Ram Amrani <Ram.Amrani@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 28 Feb 2016 10:26:55 +0000 (12:26 +0200)]
qed: Print additional HW attention info
This patch utilizes the attention infrastructure to log additional
information that relates only to specific HW blocks.
For some of those HW blocks, it also stops automatically disabling the
attention generation as the attention is considered benign and thus
should only be logged; No fear of it flooding the system.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 28 Feb 2016 10:26:54 +0000 (12:26 +0200)]
qed: Print HW attention reasons
Each HW block contains common information about attention reasons,
raising a bit for each one of the different sub-reasons that caused it
to raise an attention.
This patch extends the infrastructure by allowing logging of the various
reasons causing the HW blocks to generate an attention.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 28 Feb 2016 10:26:53 +0000 (12:26 +0200)]
qed: Add support for HW attentions
HW is capable of generating attentnions for a multitude of reasons,
but current driver is enabling attention generation only for management
firmware [required for link notifications].
This patch enables almost all of the possible reasons for HW attentions,
logging the HW block generating the attention and preventing further
attentions from that source [to prevent possible attention flood].
It also lays the infrastructure for additional exploration of the various
attentions.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 28 Feb 2016 10:26:52 +0000 (12:26 +0200)]
qed: Semantic refactoring of interrupt code
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 24 Feb 2016 14:52:50 +0000 (16:52 +0200)]
qed, qede: rebrand module description
Drop the `QL4xxx 40G/100G' and use `FastLinQ 4xxxx' instead.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 24 Feb 2016 14:52:49 +0000 (16:52 +0200)]
qed: Prevent probe on previous error
Don't allow driver to probe on an adapter at a failed state;
Gracefully block the probe instead.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 24 Feb 2016 14:52:48 +0000 (16:52 +0200)]
qed: add MODULE_FIRMWARE()
Module is using a binary firmware file and so should be marked as such.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 24 Feb 2016 14:52:47 +0000 (16:52 +0200)]
qede: Don't report link change needlessly
There are several corner cases where driver might get a 2nd notification
about the same link change. Don't log any additional changes if the
physical carrier is already reported as it should.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 24 Feb 2016 14:52:46 +0000 (16:52 +0200)]
qede: Linearize SKBs when needed
There's a corner-case in HW where an SKB queued for transmission that
contains too many frags will cause FW to assert.
This patch solves this by linearizing the SKB if necessary.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Wed, 24 Feb 2016 14:52:45 +0000 (16:52 +0200)]
qede: Change pci DID for 10g device
The device ID for the 10g module has changed. Populate the pci_ids table
accordingly.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 21 Feb 2016 09:40:11 +0000 (11:40 +0200)]
qed,qede: Bump driver versions to 8.7.0.0
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 21 Feb 2016 09:40:10 +0000 (11:40 +0200)]
qed: Introduce DMA_REGPAIR_LE
FW hsi contains regpairs, mostly for 64-bit address representations.
Since same paradigm is applied each time a regpair is filled, this
introduces a new utility macro for setting such regpairs.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 21 Feb 2016 09:40:09 +0000 (11:40 +0200)]
qed: Change metadata needed for SPQ entries
Each configuration element send via ramrod requires a Slow Path Queue
entry. This slightly changes the way such an entry is configured, but
contains mostly semantic changes [where more parameters are gathered
in a sub-struct instead of being directly passed].
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 21 Feb 2016 09:40:08 +0000 (11:40 +0200)]
qed: Handle possible race in SB config
Due to HW design, some of the memories are wide-bus and access to those
needs to be sequentialized on a per-HW-block level; Read/write to a
given HW-block might break other read/write to wide-bus memory done at
~same time.
Status blocks initialization in CAU is done into such a wide-bus memory.
This moves the initialization into using DMAE which is guaranteed to be
safe to use on such memories.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Sun, 21 Feb 2016 09:40:07 +0000 (11:40 +0200)]
qed: Turn most GFP_ATOMIC into GFP_KERNEL
Initial driver submission used GFP_ATOMIC almost inclusively when
allocating memory. We now remedy this point, using GFP_KERNEL where
it's possible.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Device would start receiving only vlan-tagged traffic with tags matching
that of one of the configured vlan IDs, unless:
- Device is expliicly placed in PROMISC mode.
- Device exhausts its vlan filter credits.
Signed-off-by: Sudarsana Reddy Kalluru <sudarsana.kalluru@qlogic.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Thu, 18 Feb 2016 15:00:39 +0000 (17:00 +0200)]
qed: Lay infrastructure for vlan filtering offload
Today, interfaces are working in vlan-promisc mode; But once
vlan filtering offloaded would be supported, we'll need a method to
control it directly [e.g., when setting device to PROMISC, or when
running out of vlan credits].
This adds the necessary API for L2 client to manually choose whether to
accept all vlans or only those for which filters were configured.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Yuval Mintz [Mon, 15 Feb 2016 18:22:35 +0000 (13:22 -0500)]
qed/qede: use 8.7.3.0 FW.
This patch moves the qed* driver into utilizing the 8.7.3.0 FW.
This new FW is required for a lot of new SW features, including:
- Vlan filtering offload
- Encapsulation offload support
- HW ingress aggregations
As well as paving the way for the possibility of adding storage protocols
in the future.
V2:
- Fix kbuild test robot error/warnings.
Signed-off-by: Yuval Mintz <Yuval.Mintz@qlogic.com> Signed-off-by: Sudarsana Reddy Kalluru <Sudarsana.Kalluru@qlogic.com> Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Sudarsana Kalluru [Mon, 7 Dec 2015 11:25:59 +0000 (06:25 -0500)]
qed: Correct slowpath interrupt scheme
When using INTa, ISR might be called before device is configured
for INTa [E.g., due to other device asserting the shared interrupt line],
in which case the ISR would read the SISR registers that shouldn't be
read unless HW is already configured for INTa. This might break interrupts
later on. There's also an MSI-X issue due to this difference, although
it's mostly theoretical.
This patch changes the initialization order, calling request_irq() for the
slowpath interrupt only after the chip is configured for working
in the preferred interrupt mode.
Signed-off-by: Sudarsana Kalluru <Sudarsana.Kalluru@qlogic.com> Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Ariel Elior [Mon, 7 Dec 2015 11:25:58 +0000 (06:25 -0500)]
qed: Fix BAR size split for some servers
Can't rely on pci config space to discover bar size,
as in some environments this returns a wrong, too large value.
Instead, rely on device register, which contains the value
provided by MFW at preboot.
Signed-off-by: Ariel Elior <Ariel.Elior@qlogic.com> Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>
Tomer Tayar [Mon, 7 Dec 2015 11:25:57 +0000 (06:25 -0500)]
qed: fix handling of concurrent ramrods.
Concurrent non-blocking slowpath ramrods can be completed
out-of-order on the completion chain. Recycling completed elements,
while previously sent elements are still completion pending,
can lead to overriding of active elements on the chain. Furthermore,
sending pending slowpath ramrods currently lacks the update of the
chain element physical pointer.
This patch:
* Ensures that ramrods are sent to the FW with
consecutive echo values.
* Handles out-of-order completions by freeing only first
successive completed entries.
* Updates the chain element physical pointer when copying
a pending element into a free element for sending.
Signed-off-by: Tomer Tayar <Tomer.Tayar@qlogic.com> Signed-off-by: Manish Chopra <manish.chopra@qlogic.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Orabug: 23732603 Signed-off-by: Manjunath Govindashetty <manjunath.govindashetty@oracle.com>