linux-firmware: add firmware for all Mellanox Spectrum Switches
authorTil Kaiser <mail@tk154.de>
Sun, 28 Apr 2024 12:24:11 +0000 (14:24 +0200)
committerHauke Mehrtens <hauke@hauke-m.de>
Thu, 29 Aug 2024 18:39:48 +0000 (20:39 +0200)
This commit adds the currently missing Mellanox
Spectrum-2, Spectrum-3, and Spectrum-4 firmware files.

Signed-off-by: Til Kaiser <mail@tk154.de>
Link: https://github.com/openwrt/openwrt/pull/15362
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
package/firmware/linux-firmware/mellanox.mk

index 039c7deb105651e38bc47163d18c91aab40125d4..949085f2a80b0a5d9f78dc07f6e7e182f2c2c080 100644 (file)
@@ -7,3 +7,33 @@ define Package/mlxsw_spectrum-firmware/install
 endef
 
 $(eval $(call BuildPackage,mlxsw_spectrum-firmware))
+
+Package/mlxsw_spectrum2-firmware = $(call Package/firmware-default,Mellanox Spectrum-2 firmware)
+define Package/mlxsw_spectrum2-firmware/install
+       $(INSTALL_DIR) $(1)/lib/firmware/mellanox
+       $(CP) \
+               $(PKG_BUILD_DIR)/mellanox/mlxsw_spectrum2-*.mfa2 \
+               $(1)/lib/firmware/mellanox
+endef
+
+$(eval $(call BuildPackage,mlxsw_spectrum2-firmware))
+
+Package/mlxsw_spectrum3-firmware = $(call Package/firmware-default,Mellanox Spectrum-3 firmware)
+define Package/mlxsw_spectrum3-firmware/install
+       $(INSTALL_DIR) $(1)/lib/firmware/mellanox
+       $(CP) \
+               $(PKG_BUILD_DIR)/mellanox/mlxsw_spectrum3-*.mfa2 \
+               $(1)/lib/firmware/mellanox
+endef
+
+$(eval $(call BuildPackage,mlxsw_spectrum3-firmware))
+
+Package/mlxsw_spectrum4-firmware = $(call Package/firmware-default,Mellanox Spectrum-4 firmware)
+define Package/mlxsw_spectrum4-firmware/install
+       $(INSTALL_DIR) $(1)/lib/firmware/mellanox
+       $(CP) \
+               $(PKG_BUILD_DIR)/mellanox/mlxsw_spectrum4-*.mfa2 \
+               $(1)/lib/firmware/mellanox
+endef
+
+$(eval $(call BuildPackage,mlxsw_spectrum4-firmware))