Package: firmware-bnx2x
Version: 20210818-1
Severity: grave

On Linux 5.16, the bnx2x module requests firmware 7.13.21.0:

# modinfo bnx2x
filename:
/lib/modules/5.16.0-2-amd64/kernel/drivers/net/ethernet/broadcom/bnx2x/bnx2x.ko
firmware:       bnx2x/bnx2x-e2-7.13.21.0.fw
firmware:       bnx2x/bnx2x-e1h-7.13.21.0.fw
firmware:       bnx2x/bnx2x-e1-7.13.21.0.fw

This firmware is not present in the firmware-bnx2x package.

Now, my understanding is that the bnx2x module can fall back to an
earlier version (7.13.15.0) as needed, but in practice that might not
actually help, because update-initramfs only looks for the firmware
version from the module information and doesn't include any other
version:

# update-initramfs -u
W: Possible missing firmware /lib/firmware/bnx2x/bnx2x-e2-7.13.21.0.fw
for module bnx2x
W: Possible missing firmware
/lib/firmware/bnx2x/bnx2x-e1h-7.13.21.0.fw for module bnx2x
W: Possible missing firmware /lib/firmware/bnx2x/bnx2x-e1-7.13.21.0.fw
for module bnx2x

Since no firmware is included in the initramfs, the bnx2x module
unsurprisingly fails to initialize on boot:

kernel: bnx2x 0000:02:00.1: firmware: failed to load
bnx2x/bnx2x-e2-7.13.21.0.fw (-2)
kernel: bnx2x 0000:02:00.1: Direct firmware load for
bnx2x/bnx2x-e2-7.13.21.0.fw failed with error -2
kernel: bnx2x 0000:02:00.1: firmware: failed to load
bnx2x/bnx2x-e2-7.13.15.0.fw (-2)
kernel: bnx2x 0000:02:00.1: Direct firmware load for
bnx2x/bnx2x-e2-7.13.15.0.fw failed with error -2

Adding insult to injury, it doesn't look like it's possible to recover
from this state - as far as I could tell, once bnx2x fails to
initialize, it's game over until the next reboot, even if the module
is unloaded and reloaded, and even if the PCI device is removed and
rescanned.

This basically means that, when booting current Debian Unstable with
Linux 5.16, bnx2x NICs become *permanently unusable*, potentially
locking users and admins out of the system.

My suggested short-term fix would be to update the firmware-bnx2x
package to include the 7.13.21.0 firmware version. There's also a
discussion to be had with regard to update-initramfs, which should
perhaps try harder to find potentially compatible firmware versions -
indeed, if update-initramfs had included 7.13.15.0, I believe this
issue would have been avoided.

For those affected, here's the workaround I used:

1. Manually download the 7.13.21.0 firmware files from
https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/bnx2x
2. Put the files in /lib/firmware/bnx2x
3. Run update-initramfs -u
4. Reboot

Reply via email to