[PATCH net 3/4] bnxt_en: Reduce memory usage when running in kdump kernel.

2019-05-22 Thread Michael Chan
ns on 57500 chips for RDMA.") Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 4 ++-- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/ne

[PATCH net 0/4] bnxt_en: Bug fixes.

2019-05-22 Thread Michael Chan
s not supported. Please queue #1, #2, #3 for -stable as well. Thanks. Michael Chan (3): bnxt_en: Fix aggregation buffer leak under OOM condition. bnxt_en: Fix possible BUG() condition when calling pci_disable_msix(). bnxt_en: Reduce memory usage when running in kdump kernel. Vasundhara Vol

[PATCH net 1/4] bnxt_en: Fix aggregation buffer leak under OOM condition.

2019-05-22 Thread Michael Chan
allocate a new SKB buffer. This leads to the aggregation ring slowly running out of buffers over time. Fix it by properly recycling the aggregation buffers. Fixes: c0c050c58d84 ("bnxt_en: New Broadcom ethernet driver.") Reported-by: Rakesh Hemnani Signed-off-by: Michael Chan --- d

[PATCH net 2/4] bnxt_en: Fix possible BUG() condition when calling pci_disable_msix().

2019-05-22 Thread Michael Chan
bnxt_reserve_rings() call. bnxt_reserve_rings() can only call pci_disable_msix() if the irq_re_init parameter is true, otherwise it may hit BUG() because some IRQs may not have been freed yet. Fixes: 41e8d7983752 ("bnxt_en: Modify the ring reservation functions for 57500 series chips.") Signed-off-b

[PATCH net 4/4] bnxt_en: Device serial number is supported only for PFs.

2019-05-22 Thread Michael Chan
From: Vasundhara Volam Don't read DSN on VFs that do not have the PCI capability. Fixes: 03213a996531 ("bnxt: move bp->switch_id initialization to PF probe") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 11 +

[PATCH net] bnxt_en: Fix VNIC accounting when enabling aRFS on 57500 chips.

2019-07-17 Thread Michael Chan
Cs. Fixes: ac33906c67e2 ("bnxt_en: Add support for aRFS on 57500 chips.") Signed-off-by: Michael Chan --- Please queue this for 5.2 -stable also. Thanks. drivers/net/ethernet/broadcom/bnxt/bnxt.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/bro

[PATCH net-next 01/16] bnxt_en: Update firmware interface spec. to 1.10.0.89.

2019-07-29 Thread Michael Chan
Among the changes are new CoS discard counters and new ctx_hw_stats_ext struct for the latest 5750X B0 chips. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 15 +++ drivers/net/ethernet/broadcom/bnxt/bnxt_hsi.h | 109 ++ 2 files

[PATCH net-next 12/16] bnxt_en: Allocate the larger per-ring statistics block for 57500 chips.

2019-07-29 Thread Michael Chan
The new TPA implemantation has additional TPA counters that extend the per-ring statistics block. Allocate the proper size accordingly. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 10 -- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 1 + 2 files changed

[PATCH net-next 06/16] bnxt_en: Refactor tunneled hardware GRO logic.

2019-07-29 Thread Michael Chan
The 2 GRO functions to set up the hardware GRO SKB fields for 2 different hardware chips have practically identical logic for tunneled packets. Refactor the logic into a separate bnxt_gro_tunnel() function that can be used by both functions. Signed-off-by: Michael Chan --- drivers/net/ethernet

[PATCH net-next 02/16] bnxt_en: Add TPA structure definitions for BCM57500 chips.

2019-07-29 Thread Michael Chan
The new chips have a slightly modified TPA interface for LRO/GRO_HW. Modify the TPA structures so that the same structures can also be used on the new chips. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 67 +++ 1 file changed, 67

[PATCH net-next 13/16] bnxt_en: Support TPA counters on 57500 chips.

2019-07-29 Thread Michael Chan
Support the new expanded TPA v2 counters on 57500 B0 chips for ethtool -S. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 41 +-- 1 file changed, 31 insertions(+), 10 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt

[PATCH net-next 08/16] bnxt_en: Add fast path logic for TPA on 57500 chips.

2019-07-29 Thread Michael Chan
With all the previous refactoring, the TPA fast path can now be modified slightly to support TPA on the new chips. The main difference is that the agg completions are retrieved differently using the bnxt_get_tpa_agg_p5() function on the new chips. Signed-off-by: Michael Chan --- drivers/net

[PATCH net-next 00/16] bnxt_en: Add TPA (GRO_HW and LRO) on 57500 chips.

2019-07-29 Thread Michael Chan
packet is completed. The larger aggregation ID space also requires a new ID mapping logic to make it more memory efficient. Michael Chan (16): bnxt_en: Update firmware interface spec. to 1.10.0.89. bnxt_en: Add TPA structure definitions for BCM57500 chips. bnxt_en: Refactor TPA logic

[PATCH net-next 09/16] bnxt_en: Add TPA ID mapping logic for 57500 chips.

2019-07-29 Thread Michael Chan
we would have to allocate 1024 TPA structures for each RX ring on each PCI function. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 46 +-- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 9 ++ 2 files changed, 53 insertions(+), 2

[PATCH net-next 10/16] bnxt_en: Add hardware GRO setup function for 57500 chips.

2019-07-29 Thread Michael Chan
Add a more optimized hardware GRO function to setup the SKB on 57500 chips. Some workaround code is no longer needed on 57500 chips and the pseudo checksum is also calculated in hardware, so no need to do the software pseudo checksum in the driver. Signed-off-by: Michael Chan --- drivers/net

[PATCH net-next 14/16] bnxt_en: Refactor bnxt_init_one() and turn on TPA support on 57500 chips.

2019-07-29 Thread Michael Chan
With the new TPA feature in the 57500 chips, we need to discover the feature first before setting up the netdev features. Refactor the the firmware probe and init logic more cleanly into 2 functions and and make these calls before setting up the netdev features. Signed-off-by: Michael Chan

[PATCH net-next 03/16] bnxt_en: Refactor TPA logic.

2019-07-29 Thread Michael Chan
will be different on the new chip in TPA mode. The logic to recycle the aggregation buffers has a new start index parameter added for the same purpose. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 117 ++ 1 file changed, 69 insertions

[PATCH net-next 16/16] bnxt_en: Add PCI IDs for 57500 series NPAR devices.

2019-07-29 Thread Michael Chan
Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 9fe81fa..7a9b92e 100644 --- a/drivers/net/ethernet/broadcom

[PATCH net-next 11/16] bnxt_en: Refactor ethtool ring statistics logic.

2019-07-29 Thread Michael Chan
by the newer chips. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 120 +- 1 file changed, 70 insertions(+), 50 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c

[PATCH net-next 15/16] bnxt_en: Support all variants of the 5750X chip family.

2019-07-29 Thread Michael Chan
Define the 57508, 57504, and 57502 chip IDs that are all part of the BNXT_CHIP_P5 family of chips. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.h b

[PATCH net-next 04/16] bnxt_en: Expand bnxt_tpa_info struct to support 57500 chips.

2019-07-29 Thread Michael Chan
is also added to keep track of the number of these completions. The maximum concurrent TPA is now discovered from firmware instead of the hardcoded 64. Add a new bp->max_tpa to keep track of maximum configured TPA. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c |

[PATCH net-next 07/16] bnxt_en: Set TPA GRO mode flags on 57500 chips properly.

2019-07-29 Thread Michael Chan
st path can safely rely on bp->flags to determine the TPA mode. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnx

[PATCH net-next 05/16] bnxt_en: Handle standalone RX_AGG completions.

2019-07-29 Thread Michael Chan
On the new 57500 chips, these new RX_AGG completions are not coalesced at the TPA_END completion. Handle these by storing them in the array in the bnxt_tpa_info struct, as they are seen when processing the CMPL ring. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c

Re: [PATCH net-next 00/16] bnxt_en: Add TPA (GRO_HW and LRO) on 57500 chips.

2019-07-29 Thread Michael Chan
On Mon, Jul 29, 2019 at 2:24 PM David Miller wrote: > > From: Michael Chan > Date: Mon, 29 Jul 2019 06:10:17 -0400 > > > This patchset adds TPA v2 support on the 57500 chips. TPA v2 is > > different from the legacy TPA scheme on older chips and requires major > >

[PATCH net-next] cnic: Explicitly initialize all reference counts to 0.

2019-08-01 Thread Michael Chan
igned-off-by: Michael Chan --- drivers/net/ethernet/broadcom/cnic.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/net/ethernet/broadcom/cnic.c b/drivers/net/ethernet/broadcom/cnic.c index 57dc3cb..155599d 100644 --- a/drivers/net/ethernet/broadcom/cnic.c +++ b/drivers/net/eth

[PATCH net-next 5/5] bnxt_en: Enable batch mode when using HWRM_NVM_MODIFY to flash packages.

2020-12-13 Thread Michael Chan
-by: Edwin Peer Signed-off-by: Michael Chan --- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 49 +++ 1 file changed, 40 insertions(+), 9 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c index

[PATCH net-next 4/5] bnxt_en: Retry installing FW package under NO_SPACE error condition.

2020-12-13 Thread Michael Chan
-by: Vasundhara Volam Reviewed-by: Edwin Peer Signed-off-by: Pavan Chebbi Signed-off-by: Michael Chan --- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 37 --- 1 file changed, 32 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b

[PATCH net-next 2/5] bnxt_en: Rearrange the logic in bnxt_flash_package_from_fw_obj().

2020-12-13 Thread Michael Chan
This function will be modified in the next patch to retry flashing the firmware in a loop. To facilate that, we rearrange the code so that the steps that only need to be done once before the loop will be moved to the top of the function. Signed-off-by: Michael Chan --- .../net/ethernet

[PATCH net-next 1/5] bnxt_en: Refactor bnxt_flash_nvram.

2020-12-13 Thread Michael Chan
-off-by: Michael Chan --- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 51 --- 1 file changed, 32 insertions(+), 19 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c index 7b444fcb6289..11edf4998de7

[PATCH net-next 0/5] bnxt_en: Improve firmware flashing.

2020-12-13 Thread Michael Chan
smaller buffer to DMA the contents in multiple DMA operations. Michael Chan (2): bnxt_en: Rearrange the logic in bnxt_flash_package_from_fw_obj(). bnxt_en: Enable batch mode when using HWRM_NVM_MODIFY to flash packages. Pavan Chebbi (3): bnxt_en: Refactor bnxt_flash_nvram. bnxt_en

[PATCH net-next 3/5] bnxt_en: Restructure bnxt_flash_package_from_fw_obj() to execute in a loop.

2020-12-13 Thread Michael Chan
be added in the next patch. Signed-off-by: Pavan Chebbi Signed-off-by: Michael Chan --- .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 60 +-- 1 file changed, 28 insertions(+), 32 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net

Re: NETDEV WATCHDOG: s1p1 (bnxt_en): transmit queue 2 timed out

2020-11-30 Thread Michael Chan
On Mon, Nov 30, 2020 at 9:37 AM Marc Smith wrote: > > On Sun, Nov 29, 2020 at 2:04 AM Michael Chan > wrote: > > > > On Wed, Nov 25, 2020 at 11:39 AM Marc Smith wrote: > > > > > [17879.279213] bnxt_en :01:09.0 s1p1: TX timeout detected, > >

Re: [PATCH net] bnxt_en: fix error return code in bnxt_init_board()

2020-11-19 Thread Michael Chan
On Thu, Nov 19, 2020 at 9:53 PM Jakub Kicinski wrote: > > On Thu, 19 Nov 2020 10:53:23 -0800 Edwin Peer wrote: > > > Fix to return a negative error code from the error handling > > > case instead of 0, as done elsewhere in this function. > > > > > > Fixes: c0c050c58d84 ("bnxt_en: New Broadcom ethe

[PATCH net] bnxt_en: Release PCI regions when DMA mask setup fails during probe.

2020-11-19 Thread Michael Chan
Jump to init_err_release to cleanup. bnxt_unmap_bars() will also be called but it will do nothing if the BARs are not mapped yet. Fixes: c0c050c58d84 ("bnxt_en: New Broadcom ethernet driver.") Reported-by: Jakub Kicinski Signed-off-by: Michael Chan --- drivers/net/ethernet/bro

Re: NETDEV WATCHDOG: s1p1 (bnxt_en): transmit queue 2 timed out

2020-11-28 Thread Michael Chan
On Wed, Nov 25, 2020 at 11:39 AM Marc Smith wrote: > [17879.279213] bnxt_en :01:09.0 s1p1: TX timeout detected, > starting reset task! > [17883.075299] bnxt_en :01:09.0 s1p1: Resp cmpl intr err msg: 0x51 > [17883.075302] bnxt_en :01:09.0 s1p1: hwrm_ring_free type 1 > failed. rc:ff

[PATCH net 3/4] bnxt_en: Fix counter overflow logic.

2020-11-15 Thread Michael Chan
passed into bnxt_add_one_ctr(). Fixes: fea6b3335527 ("bnxt_en: Accumulate all counters.") Reviewed-by: Vasundhara Volam Reviewed-by: Pavan Chebbi Reviewed-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 1 + 1 file changed, 1 insertion(+)

[PATCH net 4/4] bnxt_en: Avoid unnecessary NVM_GET_DEV_INFO cmd error log on VFs.

2020-11-15 Thread Michael Chan
From: Vasundhara Volam VFs do not have access permissions to issue NVM_GET_DEV_INFO firmware command. Fixes: 4933f6753b50 ("bnxt_en: Add bnxt_hwrm_nvm_get_dev_info() to query NVM info.") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/bro

[PATCH net 0/4] bnxt_en: Bug fixes.

2020-11-15 Thread Michael Chan
using page 0 Michael Chan (2): bnxt_en: Free port stats during firmware reset. bnxt_en: Fix counter overflow logic. Vasundhara Volam (1): bnxt_en: Avoid unnecessary NVM_GET_DEV_INFO cmd error log on VFs. drivers/net/ethernet/broadcom/bnxt/bnxt.c | 4 +++- drivers/net/ethernet

[PATCH net 2/4] bnxt_en: Free port stats during firmware reset.

2020-11-15 Thread Michael Chan
hara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 7975f59735d6..448e1ba762ee 100644 --- a/drivers/ne

[PATCH net 1/4] bnxt_en: read EEPROM A2h address using page 0

2020-11-15 Thread Michael Chan
address space. Fixes: 42ee18fe4ca2 ("bnxt_en: Add Support for ETHTOOL_GMODULEINFO and ETHTOOL_GMODULEEEPRO") Signed-off-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/d

Re: [PATCH net] net: b44: fix error return code in b44_init_one()

2020-11-16 Thread Michael Chan
ted-by: Hulk Robot > Signed-off-by: Zhang Changzhong Reviewed-by: Michael Chan Thanks. smime.p7s Description: S/MIME Cryptographic Signature

[PATCH net 0/2] bnxt_en: Bug fixes.

2020-12-27 Thread Michael Chan
The first patch fixes recovery of fatal AER errors. The second one fixes a potential array out of bounds issue. Please queue for -stable. Thanks. Michael Chan (1): bnxt_en: Check TQM rings for maximum supported value. Vasundhara Volam (1): bnxt_en: Fix AER recovery. drivers/net/ethernet

[PATCH net 1/2] bnxt_en: Fix AER recovery.

2020-12-27 Thread Michael Chan
er Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 31 ++- 1 file changed, 14 insertions(+), 17 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bn

[PATCH net 2/2] bnxt_en: Check TQM rings for maximum supported value.

2020-12-27 Thread Michael Chan
may request more than 9 TQM rings. Define macros to remove the magic number 9 from the C code. Fixes: ac3158cb0108 ("bnxt_en: Allocate TQM ring context memory according to fw specification.") Reviewed-by: Pavan Chebbi Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- d

[PATCH net 0/2] bnxt_en: Bug fixes.

2021-01-11 Thread Michael Chan
This series has 2 fixes. The first one fixes a resource accounting error with the RDMA driver loaded and the second one fixes the firmware flashing sequence after defragmentation. Please queue the 1st one for -stable. Thanks. Michael Chan (1): bnxt_en: Improve stats context resource

[PATCH net 2/2] bnxt_en: Clear DEFRAG flag in firmware message when retry flashing.

2021-01-11 Thread Michael Chan
: 1432c3f6a6ca ("bnxt_en: Retry installing FW package under NO_SPACE error condition.") Signed-off-by: Pavan Chebbi Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/etherne

[PATCH net 1/2] bnxt_en: Improve stats context resource accounting with RDMA driver loaded.

2021-01-11 Thread Michael Chan
for extra stats contexts only if the RDMA driver is registered and MSIX vectors have been successfully requested. Fixes: c027c6b4e91f ("bnxt_en: get rid of num_stat_ctxs variable") Reviewed-by: Yongping Zhang Reviewed-by: Pavan Chebbi Signed-off-by: Michael Chan --- drivers/ne

[PATCH net 1/5] bnxt_en: Fix regression in workqueue cleanup logic in bnxt_remove_one().

2020-10-25 Thread Michael Chan
sh in bnxt_fw_reset_task()") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/b

[PATCH net 4/5] bnxt_en: Check abort error state in bnxt_open_nic().

2020-10-25 Thread Michael Chan
00 00 c7 [ 1648.681986] RIP [] bnxt_alloc_mem+0x50a/0x1140 [bnxt_en] [ 1648.682724] RSP [ 1648.683451] CR2: Fixes: ec5d31e3c15d ("bnxt_en: Handle firmware reset status during IF_UP.") Reviewed-by: Vasundhara Volam Reviewed-by: Pavan Chebbi Signed-off-by: Michael Ch

[PATCH net 2/5] bnxt_en: Invoke cancel_delayed_work_sync() for PFs also.

2020-10-25 Thread Michael Chan
hara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 13 ++--- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index e4e5ea080391..7be232018015 100644 -

[PATCH net 3/5] bnxt_en: Re-write PCI BARs after PCI fatal error.

2020-10-25 Thread Michael Chan
Enable AER support.") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 19 ++- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 1 + 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/broadcom

[PATCH net 5/5] bnxt_en: Send HWRM_FUNC_RESET fw command unconditionally.

2020-10-25 Thread Michael Chan
: Avoid sending firmware messages when AER error is detected.") Reviewed-by: Edwin Peer Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/bro

[PATCH net 0/5] bnxt_en: Bug fixes.

2020-10-25 Thread Michael Chan
check for firmware reset abort error. The last one sends the fw reset command unconditionally to fix the AER reset logic. Please queue these for -stable as well. Thanks. Michael Chan (1): bnxt_en: Check abort error state in bnxt_open_nic(). Vasundhara Volam (4): bnxt_en: Fix regression in

Re: [PATCH net-next v2 8/9] bnxt: implement ethtool standard stats

2021-04-18 Thread Michael Chan
On Fri, Apr 16, 2021 at 12:27 PM Jakub Kicinski wrote: > > Most of the names seem to strongly correlate with names from > the standard and RFC. Whether ..+good_frames are indeed Frames..OK > I'm the least sure of. The mapping looks correct to me. These counters can also be mapped: rx_fcs_err_fr

[PATCH net-next 0/7] bnxt_en: Error recovery optimizations.

2021-02-14 Thread Michael Chan
. Edwin Peer (1): bnxt_en: selectively allocate context memories Michael Chan (6): bnxt_en: Update firmware interface spec to 1.10.2.16. bnxt_en: Implement faster recovery for firmware fatal error. bnxt_en: Add context memory initialization infrastructure. bnxt_en: Initialize "context

[PATCH net-next 4/7] bnxt_en: Add context memory initialization infrastructure.

2021-02-14 Thread Michael Chan
emset() to initialize all relevant context memory. Reviewed-by: Pavan Chebbi Reviewed-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 52 --- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 19 - 2 files changed, 53 insertions(

[PATCH net-next 2/7] bnxt_en: selectively allocate context memories

2021-02-14 Thread Michael Chan
memory based on device capabilities and only enable backing store for the appropriate contexts. Signed-off-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 84 ++- 1 file changed, 52 insertions(+), 32 deletions(-) diff --git a/drivers

[PATCH net-next 1/7] bnxt_en: Update firmware interface spec to 1.10.2.16.

2021-02-14 Thread Michael Chan
The main changes are the echo request/response from firmware for error detection and the NO_FCS feature to transmit frames without FCS. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 2 +- drivers/net/ethernet/broadcom/bnxt/bnxt_hsi.h | 105

[PATCH net-next 5/7] bnxt_en: Initialize "context kind" field for context memory blocks.

2021-02-14 Thread Michael Chan
If it is older firmware and the information is not available, we set the offset to an invalid value and fall back to the old behavior of initializing every byte. Otherwise, we initialize only the "context kind" byte at the offset. Reviewed-by: Edwin Peer Signed-off-by: Michael Chan

[PATCH net-next 6/7] bnxt_en: Reply to firmware's echo request async message.

2021-02-14 Thread Michael Chan
the async message. If the firmware is not getting the reply with the proper data after some retries, error recovery will kick in. Reviewed-by: Andy Gospodarek Reviewed-by: Edwin Peer Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 29

[PATCH net-next 3/7] bnxt_en: Implement faster recovery for firmware fatal error.

2021-02-14 Thread Michael Chan
ee if the firmware has come out of reset. As soon as this register changes value we can proceed to re-initialize the device. Reviewed-by: Edwin Peer Reviewed-by: Vasundhara Volam Reviewed-by: Andy Gospodarek Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c

[PATCH net-next 7/7] bnxt_en: Improve logging of error recovery settings information.

2021-02-14 Thread Michael Chan
count value from hexadecimal to decimal. Reviewed-by: Edwin Peer Reviewed-by: Pavan Chebbi Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b

[PATCH net 0/2] bnxt_en: Error recovery bug fixes.

2021-02-26 Thread Michael Chan
Two error recovery related bug fixes for 2 corner cases. Please queue patch #2 for -stable. Thanks. Edwin Peer (1): bnxt_en: reliably allocate IRQ table on reset to avoid crash Vasundhara Volam (1): bnxt_en: Fix race between firmware reset and driver remove. drivers/net/ethernet/broadcom/

[PATCH net 2/2] bnxt_en: reliably allocate IRQ table on reset to avoid crash

2021-02-26 Thread Michael Chan
cause more drastic recovery at the next attempt to re-open the device, including a call to bnxt_init_int_mode(). Fixes: 3bc7d4a352ef ("bnxt_en: Add BNXT_STATE_IN_FW_RESET state.") Reviewed-by: Scott Branden Signed-off-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ether

[PATCH net 1/2] bnxt_en: Fix race between firmware reset and driver remove.

2021-02-26 Thread Michael Chan
lize after aborted reset") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index a680fd9c68e

Re: [PATCH rdma-next v1 5/5] net/bnxt: Use direct API instead of useless indirection

2021-03-29 Thread Michael Chan
On Mon, Mar 29, 2021 at 1:52 AM Leon Romanovsky wrote: > > From: Leon Romanovsky > > There is no need in any indirection complexity for one ULP user, > remove all this complexity in favour of direct calls to the exported > symbols. This allows us to greatly simplify the code. The goal is not to

[PATCH net-next 1/5] bnxt_en: Treat health register value 0 as valid in bnxt_try_reover_fw().

2021-04-11 Thread Michael Chan
The retry loop in bnxt_try_recover_fw() should not abort when the health register value is 0. It is a valid value that indicates the firmware is booting up. Fixes: 861aae786f2f ("bnxt_en: Enhance retry of the first message to the firmware.") Reviewed-by: Edwin Peer Signed-off-by: Mi

[PATCH net-next 2/5] bnxt_en: Invalidate health register mapping at the end of probe.

2021-04-11 Thread Michael Chan
("bnxt_en: Improve the status_reliable flag in bp->fw_health.") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/

[PATCH net-next 0/5] bnxt_en: Error recovery fixes.

2021-04-11 Thread Michael Chan
This series adds some fixes and enhancements to the error recovery logic. The health register logic is improved and we also add missing code to free and re-create VF representors in the firmware after error recovery. Michael Chan (2): bnxt_en: Treat health register value 0 as valid in

[PATCH net-next 5/5] bnxt_en: Free and allocate VF-Reps during error recovery.

2021-04-11 Thread Michael Chan
From: Sriharsha Basavapatna During firmware recovery, VF-Rep configuration in the firmware is lost. Fix it by freeing and (re)allocating VF-Reps in FW at relevant points during the error recovery process. Signed-off-by: Sriharsha Basavapatna Signed-off-by: Michael Chan --- drivers/net

[PATCH net-next 4/5] bnxt_en: Refactor __bnxt_vf_reps_destroy().

2021-04-11 Thread Michael Chan
recovery. Reviewed-by: Edwin Peer Reviewed-by: Sriharsha Basavapatna Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c | 21 ++- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_vfr.c b/drivers/net

[PATCH net-next 3/5] bnxt_en: Refactor bnxt_vf_reps_create().

2021-04-11 Thread Michael Chan
From: Sriharsha Basavapatna Add a new function bnxt_alloc_vf_rep() to allocate a VF representor. This function will be needed in subsequent patches to recreate the VF reps after error recovery. Signed-off-by: Sriharsha Basavapatna Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom

Re: [PATCH net-next 4/5] bnxt_en: Refactor __bnxt_vf_reps_destroy().

2021-04-12 Thread Michael Chan
On Mon, Apr 12, 2021 at 12:37 AM Leon Romanovsky wrote: > > On Sun, Apr 11, 2021 at 08:18:14PM -0400, Michael Chan wrote: > > Add a new helper function __bnxt_free_one_vf_rep() to free one VF rep. > > We also reintialize the VF rep fields to proper initial values so that >

Re: [PATCH net-next 4/5] bnxt_en: Refactor __bnxt_vf_reps_destroy().

2021-04-12 Thread Michael Chan
On Mon, Apr 12, 2021 at 10:33 AM Leon Romanovsky wrote: > > On Mon, Apr 12, 2021 at 09:31:33AM -0700, Michael Chan wrote: > > On Mon, Apr 12, 2021 at 12:37 AM Leon Romanovsky wrote: > > > > > > On Sun, Apr 11, 2021 at 08:18:14PM -0400, Michael Chan wrote: >

Re: [PATCH net-next 4/6] bnxt: implement ethtool::get_fec_stats

2021-04-15 Thread Michael Chan
On Tue, Apr 13, 2021 at 8:45 PM Jakub Kicinski wrote: > > Report corrected bits. > > Signed-off-by: Jakub Kicinski Reviewed-by: Michael Chan Thanks. smime.p7s Description: S/MIME Cryptographic Signature

[PATCH net-next 06/15] bnxt_en: Add an upper bound for all firmware command timeouts.

2021-01-24 Thread Michael Chan
really long and it can cause hung task warnings if firmware has crashed or is not responding. To avoid such long delays, cap all firmware commands to a max timeout value of 40 seconds. Reviewed-by: Edwin Peer Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet

[PATCH net-next 07/15] bnxt_en: log firmware debug notifications

2021-01-24 Thread Michael Chan
-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index c06c5f81f087..c8c25f7644ae 100644 --- a/drivers/net

[PATCH net-next 08/15] bnxt_en: attempt to reinitialize after aborted reset

2021-01-24 Thread Michael Chan
Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 29 +-- 1 file changed, 27 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index c8c25f7644ae..7f30a9fee0c8 100644

[PATCH net-next 11/15] bnxt_en: Add a new BNXT_STATE_NAPI_DISABLED flag to keep track of NAPI state.

2021-01-24 Thread Michael Chan
will disable NAPI again and the flag will prevent disabling NAPI twice. Reviewed-by: Pavan Chebbi Reviewed-by: Andy Gospodarek Reviewed-by: Edwin Peer Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 4 +++- drivers/net/ethernet/broadcom

[PATCH net-next 12/15] bnxt_en: Modify bnxt_disable_int_sync() to be called more than once.

2021-01-24 Thread Michael Chan
In the event of a fatal firmware error, we want to disable IRQ early in the recovery sequence. This change will allow it to be called safely again as part of the normal shutdown sequence. Reviewed-by: Edwin Peer Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net

[PATCH net-next 04/15] bnxt_en: Retry sending the first message to firmware if it is under reset.

2021-01-24 Thread Michael Chan
is not ready and not in error state. Reviewed-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 42 +++ drivers/net/ethernet/broadcom/bnxt/bnxt.h | 7 2 files changed, 42 insertions(+), 7 deletions(-) diff --git a/drivers/net

[PATCH net-next 02/15] bnxt_en: Define macros for the various health register states.

2021-01-24 Thread Michael Chan
Define macros to check for the various states in the lower 16 bits of the health register. Replace the C code that checks for these values with the newly defined macros. Reviewed-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 10

[PATCH net-next 15/15] bnxt_en: Do not process completion entries after fatal condition detected.

2021-01-24 Thread Michael Chan
proceed in the NAPI poll function if fatal condition is detected. Call napi_complete() and return without arming interrupts. Cleanup of all rings and reset are imminent. Reviewed-by: Pavan Chebbi Reviewed-by: Vasundhara Volam Reviewed-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net

[PATCH net-next 14/15] bnxt_en: Consolidate firmware reset event logging.

2021-01-24 Thread Michael Chan
Combine the three netdev_warn() calls into a single call, printed at the NETIF_MSG_HW log level. Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 17 ++--- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a

[PATCH net-next 03/15] bnxt_en: handle CRASH_NO_MASTER during bnxt_open()

2021-01-24 Thread Michael Chan
. Signed-off-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 67 +-- 1 file changed, 39 insertions(+), 28 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index 5daef6801512

[PATCH net-next 10/15] bnxt_en: Add bnxt_fw_reset_timeout() helper.

2021-01-24 Thread Michael Chan
This code to check if we have reached the maximum wait time after firmware reset is used multiple times. Add a helper function to do this. Reviewed-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 15 +-- 1 file changed, 9 insertions(+), 6

[PATCH net-next 09/15] bnxt_en: Retry open if firmware is in reset.

2021-01-24 Thread Michael Chan
From: Vasundhara Volam Firmware may be in the middle of reset when the driver tries to do ifup. In that case, firmware will return a special error code and the driver will retry 10 times with 50 msecs delay after each retry. Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan

[PATCH net-next 13/15] bnxt_en: Improve firmware fatal error shutdown sequence.

2021-01-24 Thread Michael Chan
the chip goes into core reset. Reviewed-by: Edwin Peer Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers

[PATCH net-next 05/15] bnxt_en: Move reading VPD info after successful handshake with fw.

2021-01-24 Thread Michael Chan
d-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/net/ethernet/broadcom/bnxt/bnxt.c index c460dd796c1c..2fb9873e0162 1

[PATCH net-next 01/15] bnxt_en: Update firmware interface to 1.10.2.11.

2021-01-25 Thread Michael Chan
added to the structure are not used yet. Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 5 +- drivers/net/ethernet/broadcom/bnxt/bnxt.h | 2 + drivers/net/ethernet/broadcom/bnxt/bnxt_hsi.h | 249 ++ 3 files changed, 203 insertions(+), 53

[PATCH net-next 00/15] bnxt_en: Error recovery improvements.

2021-01-25 Thread Michael Chan
reinitialize after aborted reset Michael Chan (9): bnxt_en: Update firmware interface to 1.10.2.11. bnxt_en: Define macros for the various health register states. bnxt_en: Retry sending the first message to firmware if it is under reset. bnxt_en: Add bnxt_fw_reset_timeout() helper. bnxt_en

Re: [pull request][net-next V10 00/14] Add mlx5 subfunction support

2021-01-25 Thread Michael Chan
On Mon, Jan 25, 2021 at 12:09 PM Edwin Peer wrote: > > On Mon, Jan 25, 2021 at 11:49 AM Jason Gunthorpe wrote: > > > I've never seen someone implement a NumVF > 256 by co-opting the bus > > number. > > Usually the VF offset already places the VF routing IDs into a > different bus number range fro

Re: [PATCH net-next] tg3: improve PCI VPD access

2021-01-25 Thread Michael Chan
ng over pci_read_vpd(). If we miss the > 125ms timeout per VPD dword read then definitely something is wrong, > and if the tg3 module loading is killed then there's also not much > benefit in retrying the VPD read. > > Signed-off-by: Heiner Kallweit Reviewed-by: Michael Ch

[PATCH net-next] bnxt_en: Convert to use netif_level() helpers.

2021-01-25 Thread Michael Chan
Use the various netif_level() helpers to simplify the C code. This was suggested by Joe Perches. Cc: Joe Perches Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 34 ++- 1 file changed, 14 insertions(+), 20 deletions(-) diff --git a/drivers/net

[PATCH net 1/2] bnxt_en: reverse order of TX disable and carrier off

2021-02-10 Thread Michael Chan
: c0c050c58d84 ("bnxt_en: New Broadcom ethernet driver.") Signed-off-by: Edwin Peer Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt.c b/drivers/ne

[PATCH net 0/2] bnxt_en: 2 bug fixes.

2021-02-10 Thread Michael Chan
Two unrelated fixes. The first one fixes intermittent false TX timeouts during ring reconfigurations. The second one fixes a formatting discrepancy between the stored and the running FW versions. Please also queue these for -stable. Thanks. Edwin Peer (1): bnxt_en: reverse order of TX disabl

[PATCH net 2/2] bnxt_en: Fix devlink info's stored fw.psid version format.

2021-02-10 Thread Michael Chan
("bnxt_en: Add stored FW version info to devlink info_get cb.") Signed-off-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt_devlink.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/ethernet/bro

[PATCH net-next 0/7] bnxt_en: Error recovery improvements.

2021-03-22 Thread Michael Chan
essage. 4. Set the proper flag early to let the RDMA driver know that firmware reset has been detected. Edwin Peer (1): bnxt_en: don't fake firmware response success when PCI is disabled Michael Chan (3): bnxt_en: Improve the status_reliable flag in bp->fw_health. bnxt_en: Set BNXT_

[PATCH net-next 2/7] bnxt_en: Improve wait for firmware commands completion

2021-03-22 Thread Michael Chan
come out of reset during error recovery. Signed-off-by: Pavan Chebbi Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/bnxt.c | 28 +++ drivers/net/ethernet/broadcom/bnxt/bnxt.h | 5 2 files changed, 29 insertions(+), 4 deletions(-) diff --git a

[PATCH net-next 1/7] bnxt_en: Improve the status_reliable flag in bp->fw_health.

2021-03-22 Thread Michael Chan
ause a potential fw reset will reset the mapping. Similarly, we need to do the same after firmware reset during recovery. We'll remap it during ifup. Reviewed-by: Edwin Peer Reviewed-by: Vasundhara Volam Signed-off-by: Michael Chan --- drivers/net/ethernet/broadcom/bnxt/

  1   2   3   4   5   6   7   8   9   10   >