提交 6fdab8a3 编写于 作者: M Michael Chan 提交者: David S. Miller

bnxt_en: Fix asic.rev in devlink dev info command

The current asic.rev is incomplete and does not include the metal
revision.  Add the metal revision and decode the complete asic
revision into the more common and readable form (A0, B0, etc).

Fixes: 7154917a ("bnxt_en: Refactor bnxt_dl_info_get().")
Reviewed-by: NEdwin Peer <edwin.peer@broadcom.com>
Reviewed-by: NSomnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: NMichael Chan <michael.chan@broadcom.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 beb55fcf
...@@ -477,7 +477,7 @@ static int bnxt_dl_info_get(struct devlink *dl, struct devlink_info_req *req, ...@@ -477,7 +477,7 @@ static int bnxt_dl_info_get(struct devlink *dl, struct devlink_info_req *req,
return rc; return rc;
ver_resp = &bp->ver_resp; ver_resp = &bp->ver_resp;
sprintf(buf, "%X", ver_resp->chip_rev); sprintf(buf, "%c%d", 'A' + ver_resp->chip_rev, ver_resp->chip_metal);
rc = bnxt_dl_info_put(bp, req, BNXT_VERSION_FIXED, rc = bnxt_dl_info_put(bp, req, BNXT_VERSION_FIXED,
DEVLINK_INFO_VERSION_GENERIC_ASIC_REV, buf); DEVLINK_INFO_VERSION_GENERIC_ASIC_REV, buf);
if (rc) if (rc)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册