mbox series

[net-next,0/9] bnxt_en: Updates for net-next.

Message ID 1602411781-6012-1-git-send-email-michael.chan@broadcom.com
Headers show
Series bnxt_en: Updates for net-next. | expand

Message

Michael Chan Oct. 11, 2020, 10:22 a.m. UTC
This series contains these main changes:

1. Change of default message level to enable more logging.
2. Some cleanups related to processing async events from firmware.
3. Allow online ethtool selftest on multi-function PFs.
4. Return stored firmware version information to devlink.

Michael Chan (4):
  bnxt_en: Set driver default message level.
  bnxt_en: Simplify bnxt_async_event_process().
  bnxt_en: Log event_data1 and event_data2 when handling RESET_NOTIFY
    event.
  bnxt_en: Log unknown link speed appropriately.

Vasundhara Volam (5):
  bnxt_en: Return -EROFS to user space, if NVM writes are not permitted.
  bnxt_en: Enable online self tests for multi-host/NPAR mode.
  bnxt_en: Add bnxt_hwrm_nvm_get_dev_info() to query NVM info.
  bnxt_en: Refactor bnxt_dl_info_get().
  bnxt_en: Add stored FW version info to devlink info_get cb.

 drivers/net/ethernet/broadcom/bnxt/bnxt.c     |  37 +++--
 drivers/net/ethernet/broadcom/bnxt/bnxt.h     |   1 +
 .../net/ethernet/broadcom/bnxt/bnxt_devlink.c | 153 ++++++++++++------
 .../net/ethernet/broadcom/bnxt/bnxt_devlink.h |   6 +
 .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c |  24 ++-
 .../net/ethernet/broadcom/bnxt/bnxt_ethtool.h |   2 +
 6 files changed, 162 insertions(+), 61 deletions(-)

Comments

Jakub Kicinski Oct. 11, 2020, 10:02 p.m. UTC | #1
On Sun, 11 Oct 2020 06:23:01 -0400 Michael Chan wrote:
> +	rc = bnxt_hwrm_nvm_get_dev_info(bp, &nvm_dev_info);
> +	if (rc)
> +		return rc;

This will not cause an error to be returned for the entire operation on
older FW or HW, right?

> +	if (!(nvm_dev_info.flags & NVM_GET_DEV_INFO_RESP_FLAGS_FW_VER_VALID))
> +		return 0;


> +	rc = bnxt_dl_info_put(bp, req, BNXT_VERSION_STORED,
> +			      DEVLINK_INFO_VERSION_GENERIC_FW_ROCE, roce_ver);
>  	return rc;

return bnxt_dl_info_put(bp, req, BNXT_VERSION_STORED,
			DEVLINK_INFO_VERSION_GENERIC_FW_ROCE, roce_ver);
Michael Chan Oct. 11, 2020, 10:31 p.m. UTC | #2
On Sun, Oct 11, 2020 at 3:02 PM Jakub Kicinski <kuba@kernel.org> wrote:
>
> On Sun, 11 Oct 2020 06:23:01 -0400 Michael Chan wrote:
> > +     rc = bnxt_hwrm_nvm_get_dev_info(bp, &nvm_dev_info);
> > +     if (rc)
> > +             return rc;
>
> This will not cause an error to be returned for the entire operation on
> older FW or HW, right?
>

I don't think so.  This firmware call has been around for many years.
The call was recently extended to return the stored version
information but older firmware will still return successfully without
the stored versions.  I'll ask Vasundhara to double check on this.
Vasundhara Volam Oct. 12, 2020, 3:06 a.m. UTC | #3
On Mon, Oct 12, 2020 at 4:01 AM Michael Chan <michael.chan@broadcom.com> wrote:
>
> On Sun, Oct 11, 2020 at 3:02 PM Jakub Kicinski <kuba@kernel.org> wrote:
> >
> > On Sun, 11 Oct 2020 06:23:01 -0400 Michael Chan wrote:
> > > +     rc = bnxt_hwrm_nvm_get_dev_info(bp, &nvm_dev_info);
> > > +     if (rc)
> > > +             return rc;
> >
> > This will not cause an error to be returned for the entire operation on
> > older FW or HW, right?
> >
>
> I don't think so.  This firmware call has been around for many years.
> The call was recently extended to return the stored version
> information but older firmware will still return successfully without
> the stored versions.  I'll ask Vasundhara to double check on this.
Yes, older firmware will return success and does not set the new flag
support for stored firmware versions. Only in error cases, older or
newer FW will return error. Thanks.