Commit 56d69c78 authored by Vasundhara Volam's avatar Vasundhara Volam Committed by David S. Miller

bnxt_en: Add partno to devlink info_get cb

Add part number info from the vital product data to info_get command
via devlink tool. Update bnxt.rst documentation as well.

Cc: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: default avatarVasundhara Volam <vasundhara-v.volam@broadcom.com>
Signed-off-by: default avatarMichael Chan <michael.chan@broadcom.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent a0d0fd70
...@@ -51,6 +51,9 @@ The ``bnxt_en`` driver reports the following versions ...@@ -51,6 +51,9 @@ The ``bnxt_en`` driver reports the following versions
* - Name * - Name
- Type - Type
- Description - Description
* - ``board.id``
- fixed
- Part number identifying the board design
* - ``asic.id`` * - ``asic.id``
- fixed - fixed
- ASIC design identifier - ASIC design identifier
......
...@@ -403,6 +403,14 @@ static int bnxt_dl_info_get(struct devlink *dl, struct devlink_info_req *req, ...@@ -403,6 +403,14 @@ static int bnxt_dl_info_get(struct devlink *dl, struct devlink_info_req *req,
if (rc) if (rc)
return rc; return rc;
if (strlen(bp->board_partno)) {
rc = devlink_info_version_fixed_put(req,
DEVLINK_INFO_VERSION_GENERIC_BOARD_ID,
bp->board_partno);
if (rc)
return rc;
}
sprintf(buf, "%X", bp->chip_num); sprintf(buf, "%X", bp->chip_num);
rc = devlink_info_version_fixed_put(req, rc = devlink_info_version_fixed_put(req,
DEVLINK_INFO_VERSION_GENERIC_ASIC_ID, buf); DEVLINK_INFO_VERSION_GENERIC_ASIC_ID, buf);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment