]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
bnxt_en: Defrag the NVRAM region when resizing UPDATE region fails
authorPavan Chebbi <pavan.chebbi@broadcom.com>
Thu, 8 Jan 2026 18:35:19 +0000 (10:35 -0800)
committerJakub Kicinski <kuba@kernel.org>
Sat, 10 Jan 2026 23:19:50 +0000 (15:19 -0800)
commit743e683596fa3c1f8d7dfb3f84fadfbdd396ef1a
tree000cf184e1e756e3eabd563b89ffe18cfe5bccab
parente1c9c8928b5b447dfd9e70cb2007567b0b72d487
bnxt_en: Defrag the NVRAM region when resizing UPDATE region fails

When updating to a new firmware pkg, the driver checks if the UPDATE
region is big enough for the pkg and if it's not big enough, it
issues an NVM_WRITE cmd to update with the requested size.

This NVM_WRITE cmd can fail indicating fragmented region. Currently
the driver fails the fw update when this happens. We can improve the
situation by defragmenting the region and try the NVM_WRITE cmd
again. This will make firmware update more reliable.

Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Signed-off-by: Pavan Chebbi <pavan.chebbi@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Link: https://patch.msgid.link/20260108183521.215610-5-michael.chan@broadcom.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c