]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
bnxt_en: Refactor bnxt_get_regs()
authorShruti Parab <shruti.parab@broadcom.com>
Tue, 19 Aug 2025 16:39:16 +0000 (09:39 -0700)
committerJakub Kicinski <kuba@kernel.org>
Thu, 21 Aug 2025 02:34:07 +0000 (19:34 -0700)
commit1cc174d33a1f9acfd840014b6ded874aa12edc6c
treed4d6d91a230b9b900d8ab988d48a6a058907a29a
parent5f8a4f34f6dcf4b64c3cbcfd4aa5a8d7dbcd268d
bnxt_en: Refactor bnxt_get_regs()

Separate the code that sends the FW message to retrieve pcie stats into
a new helper function.  The caller of the helper will call hwrm_req_hold()
beforehand and so the caller will call hwrm_req_drop() in all cases
afterwards.  This helper will be useful when adding the support for the
larger struct pcie_ctx_hw_stats_v2.

Signed-off-by: Shruti Parab <shruti.parab@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Reviewed-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Link: https://patch.msgid.link/20250819163919.104075-3-michael.chan@broadcom.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c