From: Fabio Estevam Date: Wed, 13 Jan 2021 22:30:39 +0000 (-0300) Subject: package/freescale-imx/firmware-imx: fix the VPU firmware location X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ec18cac9f9e92d6a03d9d1936553abe1dcd2d327;p=buildroot.git package/freescale-imx/firmware-imx: fix the VPU firmware location The mainline kernel searches the coda VPU firmware inside the following locations [1]: /lib/firmware/ /lib/firmware/vpu/ Currently Buildroot installs the coda firmware into /lib/firmware/imx/vpu, which is not a valid location. Fix it by installing the coda firmwares into /lib/firmware/vpu/ which is a valid path for both mainline and NXP vendor kernels. Also create a symlink to /lib/firmware/ so that mainline kernels do not need to wait more than 60 seconds to search again inside /lib/firmware/vpu/. [1] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=8af7779f3cbc1f6720d15f00abc797493710d1ab Reported-by: Romain Naour Suggested-by: Romain Naour Signed-off-by: Fabio Estevam Acked-by: Romain Naour Signed-off-by: Thomas Petazzoni --- diff --git a/package/freescale-imx/firmware-imx/firmware-imx.mk b/package/freescale-imx/firmware-imx/firmware-imx.mk index 7d1f42f1d8..6fba4e8a0c 100644 --- a/package/freescale-imx/firmware-imx/firmware-imx.mk +++ b/package/freescale-imx/firmware-imx/firmware-imx.mk @@ -116,9 +116,11 @@ endif FIRMWARE_IMX_VPU_FW_NAME = $(call qstrip,$(BR2_PACKAGE_FIRMWARE_IMX_VPU_FW_NAME)) ifneq ($(FIRMWARE_IMX_VPU_FW_NAME),) define FIRMWARE_IMX_INSTALL_TARGET_VPU_FW - mkdir -p $(TARGET_DIR)/lib/firmware/imx/vpu - cp $(@D)/firmware/vpu/vpu_fw_$(FIRMWARE_IMX_VPU_FW_NAME)*.bin \ - $(TARGET_DIR)/lib/firmware/imx/vpu/ + mkdir -p $(TARGET_DIR)/lib/firmware/vpu + for i in $$(find $(@D)/firmware/vpu/vpu_fw_$(FIRMWARE_IMX_VPU_FW_NAME)*.bin); do \ + cp $$i $(TARGET_DIR)/lib/firmware/vpu/ ; \ + ln -sf vpu/$$(basename $$i) $(TARGET_DIR)/lib/firmware/$$(basename $$i) ; \ + done endef endif