From patchwork Mon Sep 6 09:42:14 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiko Thiery X-Patchwork-Id: 1524872 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=VQuQ1BFz; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.buildroot.org (client-ip=140.211.166.136; helo=smtp3.osuosl.org; envelope-from=buildroot-bounces@lists.buildroot.org; receiver=) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4H33Nc3BNZz9sW4 for ; Mon, 6 Sep 2021 19:42:56 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 11213607D0; Mon, 6 Sep 2021 09:42:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 0aKRM4146dkQ; Mon, 6 Sep 2021 09:42:53 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp3.osuosl.org (Postfix) with ESMTP id 6F148607A7; Mon, 6 Sep 2021 09:42:52 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 9292A1BF3BA for ; Mon, 6 Sep 2021 09:42:42 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 80709402A0 for ; Mon, 6 Sep 2021 09:42:42 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp2.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id c2TxNakxRG2k for ; Mon, 6 Sep 2021 09:42:41 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by smtp2.osuosl.org (Postfix) with ESMTPS id 752C740142 for ; Mon, 6 Sep 2021 09:42:40 +0000 (UTC) Received: by mail-wm1-x32d.google.com with SMTP id 192-20020a1c04c9000000b002f7a4ab0a49so3504104wme.0 for ; Mon, 06 Sep 2021 02:42:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=JRKFcQKE2rOMXO3i7YDoQKVuck9to//4OADqa0/+BZc=; b=VQuQ1BFz+hC47xpJG6YH/qZoJid9K1Uy6eKkw9ch3z5k+ErNOn896Rzr02t8N2I9e0 UazO3kR6CLBF3789eCafXDAJ8IVx5nWDXdjTADgOJgusrtaiTSIE8KS3DWaQ0YsXYAlx vJqjRwlZAnXiguoKqtwutt0vuPnX06747TmKnjcQUqRlUjZ+r9Qz4oKO/5P8/mtTyXDD rTrk8yEZvGYjfRGk+wn8hVEh2asB6LFBsw2FvUu7vOXwCUn7k5N0f5zSaGOru8VtEWL2 dYXfvr/QAXX9T3Hj6BzkhfjnOmOtTLnejLpjMpGcnR6dMhvxH3CTss/7thSm9xvk3Yyf jS7g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=JRKFcQKE2rOMXO3i7YDoQKVuck9to//4OADqa0/+BZc=; b=iOtsCFYb9xCvIwz8OAo2K6KZZFAIxIaVIUoNx2GTS62qp019YMkfmGhQZRNR9gAikk hZMM0kQ2DjTQv3UGYfawN+rwmtnMXjHSj1e97GpM26yt41/XUZsVJORQa/FZDRrR8xnz EpNWjVG8T6c9AHCJBG2MHT/bSfzK2+V1NiMwCKgtekoyGt00hUBzlWWtYOfE0MWj08Yk lRERGJUjgoOcFqiOZyDXxhKPH/97nnkzE5gy/O2iiNirPJUq9RwvxuY53WbOrzdYfSY6 gKjcs2xI0Qzv+HFZ5b3WxdAEpDgJFWEhv9eX6DzoS63UTg6N+LkczEh3SnLhsJ4KvmgJ uPQg== X-Gm-Message-State: AOAM533Uhzz4oeYZF0nMshHvi8OCQTP5YiFaxsT86V8flsHcQpnDfQNg sQUOg+Ti2OQhOxKMsmfeZCPiFyAaLBo= X-Google-Smtp-Source: ABdhPJz7jMGirdfgeXlmvFl27cVFFBwIGOcJz9+KIUV4AS2JbJJtmnU5Su9ly5/avexAi9wneu/ICA== X-Received: by 2002:a1c:7503:: with SMTP id o3mr10251073wmc.129.1630921359077; Mon, 06 Sep 2021 02:42:39 -0700 (PDT) Received: from hthiery.kontron.local ([213.135.10.150]) by smtp.gmail.com with ESMTPSA id l26sm6727653wmi.13.2021.09.06.02.42.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Sep 2021 02:42:38 -0700 (PDT) From: Heiko Thiery To: buildroot@buildroot.org Date: Mon, 6 Sep 2021 11:42:14 +0200 Message-Id: <20210906094214.6142-2-heiko.thiery@gmail.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210906094214.6142-1-heiko.thiery@gmail.com> References: <20210906094214.6142-1-heiko.thiery@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/3] package/freescale-imx/firmware-imx: copy all (lp)ddr files unconditionaly X-BeenThere: buildroot@lists.buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gary Bisson , Stephane Viau , Refik Tuzakli , Thomas Petazzoni , Heiko Thiery , Fabio Estevam , Xavier Roumegue Errors-To: buildroot-bounces@lists.buildroot.org Sender: "buildroot" In mainline u-boot more and more imx8 boards are switched to binman to create the imx specific image (flash.bin). To support this the (lp)ddr firmware training files are needed. For this to work all files should be made available to the U-Boot build. Signed-off-by: Heiko Thiery Reviewed-by: Gary Bisson --- package/freescale-imx/firmware-imx/firmware-imx.mk | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/package/freescale-imx/firmware-imx/firmware-imx.mk b/package/freescale-imx/firmware-imx/firmware-imx.mk index 1076cf85f1..29241342be 100644 --- a/package/freescale-imx/firmware-imx/firmware-imx.mk +++ b/package/freescale-imx/firmware-imx/firmware-imx.mk @@ -51,6 +51,11 @@ define FIRMWARE_IMX_INSTALL_IMAGE_DDR_FW $(FIRMWARE_IMX_DDRFW_DIR)/lpddr4_pmu_train_2d_fw.bin > \ $(BINARIES_DIR)/lpddr4_pmu_train_fw.bin ln -sf $(BINARIES_DIR)/lpddr4_pmu_train_fw.bin $(BINARIES_DIR)/ddr_fw.bin + + # U-Boot supports creation of the combined flash.bin image. To make + # sure that U-Boot can access all available files copy them to + # the binary dir. + cp $(FIRMWARE_IMX_DDRFW_DIR)/lpddr4*.bin $(BINARIES_DIR)/ endef endif @@ -69,6 +74,11 @@ define FIRMWARE_IMX_INSTALL_IMAGE_DDR_FW $(FIRMWARE_IMX_DDRFW_DIR)/ddr4_2d_201810_fw.bin > \ $(BINARIES_DIR)/ddr4_201810_fw.bin ln -sf $(BINARIES_DIR)/ddr4_201810_fw.bin $(BINARIES_DIR)/ddr_fw.bin + + # U-Boot supports creation of the combined flash.bin image. To make + # sure that U-Boot can access all available files copy them to + # the binary dir. + cp $(FIRMWARE_IMX_DDRFW_DIR)/ddr4*.bin $(BINARIES_DIR)/ endef endif From patchwork Mon Sep 6 09:42:16 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiko Thiery X-Patchwork-Id: 1524873 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=ExWLUPkk; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.buildroot.org (client-ip=2605:bc80:3010::137; helo=smtp4.osuosl.org; envelope-from=buildroot-bounces@lists.buildroot.org; receiver=) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4H33Nt2zZPz9sX3 for ; Mon, 6 Sep 2021 19:43:09 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id D76A0403EC; Mon, 6 Sep 2021 09:43:05 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id G54K5g_IVH8P; Mon, 6 Sep 2021 09:43:05 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp4.osuosl.org (Postfix) with ESMTP id 3F8D8403DE; Mon, 6 Sep 2021 09:43:04 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 918311BF3BA for ; Mon, 6 Sep 2021 09:42:46 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 802F3607A7 for ; Mon, 6 Sep 2021 09:42:46 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp3.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id AowP1PqI5Rgk for ; Mon, 6 Sep 2021 09:42:46 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-wm1-x334.google.com (mail-wm1-x334.google.com [IPv6:2a00:1450:4864:20::334]) by smtp3.osuosl.org (Postfix) with ESMTPS id DD4166065D for ; Mon, 6 Sep 2021 09:42:45 +0000 (UTC) Received: by mail-wm1-x334.google.com with SMTP id k5-20020a05600c1c8500b002f76c42214bso4476654wms.3 for ; Mon, 06 Sep 2021 02:42:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=o7zSeJVOgDgFCKqbRO+Q+f/8o36HRfXdLNE6nyz9i/A=; b=ExWLUPkkX654tSF8l1MTxsPveGBUnfDUglJ5GRN5/GAW/mZhVwa9BKuxDTTvs6CJCd ogRqytMkZ0jSYBuWziOe5wQ4vJ389T4sw3TfsgxLvFVdaPyeH4VR+H3KOosMRUo8OFzq 5xtH6LvNfmrk6cRr/FEaOS5jpw/kJsMpeDIgVWh19ehUn3iJQJtTHZI9rfT4lCZMArq6 kV60uMokmepioV2Tgbtadd8nxenZe7sxg4cflnAzCNt7slQDSUc6Mvazh7bd0AGjq/Gz JOirl+Gc0xh+pKvbWpzOXocefsYeeBR18nks5Svl6q29FEq0pXFcIDKD+U/HiEJqrlND sd1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=o7zSeJVOgDgFCKqbRO+Q+f/8o36HRfXdLNE6nyz9i/A=; b=JadZMrljewppPqVdVKB+PzK9U5veu7Rcho7VaOA9Z0ZcUdT/Xo8an6Vri/quGIp05c yNoo9Xv6RxCHNMEmBgCG3sr7Rx1jpvPKkVabykPo5OyPaEKY5juJlmIiMyjt+qdWbnK2 muOJjV3H/bD2pfYjFbsddY7XvMfg4myHxaNeYr4pQmMB9hpsR6i1w4mHWdNHOZliBwZ7 CHFrhLqhK3hlQ2E14bcs7Th3r4pUEMkfCtWBqochaV7/DjyokCGVGJXpq3kgcCDX1rUj YdhbAm+vWa1mdZhvhFkr5USRZYHQ5IAB4154mIiAFdaJUxM4FWxfLgFwQkObG5TPiUsD wz/A== X-Gm-Message-State: AOAM531Lo6/xRkvVNLrzUIdTeMKuodUmGRvRNttc9mIvHAJzfhz++wpN KgPWvmFkZooKk1SLJKIljViQZePrvlw= X-Google-Smtp-Source: ABdhPJylOmVZPAwV8/zbFSffE5Ob2KkZTL15L7e5GhboisfW6wcKLkKozGGI2KRXSW//gGkXsx5iMg== X-Received: by 2002:a7b:c148:: with SMTP id z8mr10382717wmi.147.1630921363851; Mon, 06 Sep 2021 02:42:43 -0700 (PDT) Received: from hthiery.kontron.local ([213.135.10.150]) by smtp.gmail.com with ESMTPSA id l26sm6727653wmi.13.2021.09.06.02.42.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Sep 2021 02:42:43 -0700 (PDT) From: Heiko Thiery To: buildroot@buildroot.org Date: Mon, 6 Sep 2021 11:42:16 +0200 Message-Id: <20210906094214.6142-3-heiko.thiery@gmail.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210906094214.6142-1-heiko.thiery@gmail.com> References: <20210906094214.6142-1-heiko.thiery@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCH 2/3] boot/uboot: copy ATF bl31 binary to uboot package dir X-BeenThere: buildroot@lists.buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gary Bisson , Stephane Viau , Refik Tuzakli , Thomas Petazzoni , Heiko Thiery , Fabio Estevam , Xavier Roumegue Errors-To: buildroot-bounces@lists.buildroot.org Sender: "buildroot" If the U-Boot image is to be built with binman and the ATF binary is used, the file is expected in the toplevel directory. Signed-off-by: Heiko Thiery --- boot/uboot/uboot.mk | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk index 4f3c9b7c3a..1a840d9cc1 100644 --- a/boot/uboot/uboot.mk +++ b/boot/uboot/uboot.mk @@ -162,8 +162,16 @@ ifeq ($(BR2_TARGET_UBOOT_NEEDS_ATF_BL31),y) UBOOT_DEPENDENCIES += arm-trusted-firmware ifeq ($(BR2_TARGET_UBOOT_NEEDS_ATF_BL31_ELF),y) UBOOT_MAKE_OPTS += BL31=$(BINARIES_DIR)/bl31.elf +define UBOOT_COPY_ATF_FIRMWARE + cp $(BINARIES_DIR)/bl31.elf $(@D)/ +endef +UBOOT_PRE_BUILD_HOOKS += UBOOT_COPY_ATF_FIRMWARE else UBOOT_MAKE_OPTS += BL31=$(BINARIES_DIR)/bl31.bin +define UBOOT_COPY_ATF_FIRMWARE + cp $(BINARIES_DIR)/bl31.bin $(@D)/ +endef +UBOOT_PRE_BUILD_HOOKS += UBOOT_COPY_ATF_FIRMWARE endif endif From patchwork Mon Sep 6 09:42:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heiko Thiery X-Patchwork-Id: 1524874 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=J1qU12tF; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.buildroot.org (client-ip=2605:bc80:3010::138; helo=smtp1.osuosl.org; envelope-from=buildroot-bounces@lists.buildroot.org; receiver=) Received: from smtp1.osuosl.org (smtp1.osuosl.org [IPv6:2605:bc80:3010::138]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4H33P447VMz9sCD for ; Mon, 6 Sep 2021 19:43:20 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id DF00C80F43; Mon, 6 Sep 2021 09:43:17 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id F63SObt-HFW2; Mon, 6 Sep 2021 09:43:17 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 2F8A281947; Mon, 6 Sep 2021 09:43:16 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 3A60D1BF3BA for ; Mon, 6 Sep 2021 09:42:54 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id 28D534044D for ; Mon, 6 Sep 2021 09:42:54 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp2.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2bvS9jw9_c-a for ; Mon, 6 Sep 2021 09:42:53 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-wm1-x32c.google.com (mail-wm1-x32c.google.com [IPv6:2a00:1450:4864:20::32c]) by smtp2.osuosl.org (Postfix) with ESMTPS id 339BC400CF for ; Mon, 6 Sep 2021 09:42:53 +0000 (UTC) Received: by mail-wm1-x32c.google.com with SMTP id n14-20020a05600c3b8e00b002f8bd2f8ab6so1197179wms.5 for ; Mon, 06 Sep 2021 02:42:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=IawvKW90xOJme/VsAj2Lb4B1wYVX4H0mJ51CQpcrpaA=; b=J1qU12tFekqXM3LRcR5iMt/sb0/HHxjNiNJVRbqfTwzsmhe7GyL/3elqnGsjfhHZLB JUch0JuhpyLi5I00ss9gEyOuSTOXVSb4H5oWHyXaTgLnJkebI4ac2iDG2LcazALl+NIH xjFVDSrbBbX4VMlKFGTBI2crgu7JLv3SdfnDq/qr4QrE836wzR/bkJl7xo9PzlsZtA4H eXkFgoZX3z0fXVg3v33OVO7YkAHZ7HbWgLb/kxia0TBY+2CYJqNAlvTfrpQ5fcU23YmE oAvb8Cr+zbsmBOrysCUEnPhhmQQxY7QaXVC+WNtM62SIjuTUYk5TccbtbWfKqTcshib/ 3NpA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=IawvKW90xOJme/VsAj2Lb4B1wYVX4H0mJ51CQpcrpaA=; b=PqGYuOkB7feqgCb0uwbJdyDApUPEti1GWLNcpp+GxbVkmM7cVDcqv20bms1ty8EBaO h7Ajt6MlWPYxnZOHc16QDIY1FUUj4TOKaOx3gdm/7sePmxopUKi5jIXAUs/+PnHE2ZXm w+z5IzAk7s4VMcNDbSm19/3fNb1ciouLzE97n88zu5+8ZX1SKgI1JiTTCRHawYnub/l9 6AkDdinz+5JBalpzD649cHQ99+6hpv/KjGCTn4Hxpo6QS9/Q0Im/eWnRUfgTc/nkWZNJ oBDyn2hj6F9fdioQjswYyXD87csGZbOZs8Sbh0neKnrgYbeWqXvMiuIXrOKrcDLCmznx 1xoA== X-Gm-Message-State: AOAM53031qTBsZI1cCeiWIJ4gZXbwihlKmI3HeJ835YKyo3l79JDLkp+ AVgiD+m70LMf/56wklLpZRXJaMsz6lY= X-Google-Smtp-Source: ABdhPJzWeQ73wO9cPv+vcgWzFM07YSKC7ZDOt9+e+IVC2B8kn1lBLSa0A7Uo8m4XMzCsaxOBW5jfhw== X-Received: by 2002:a1c:acc8:: with SMTP id v191mr10533186wme.146.1630921371207; Mon, 06 Sep 2021 02:42:51 -0700 (PDT) Received: from hthiery.kontron.local ([213.135.10.150]) by smtp.gmail.com with ESMTPSA id l26sm6727653wmi.13.2021.09.06.02.42.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Sep 2021 02:42:50 -0700 (PDT) From: Heiko Thiery To: buildroot@buildroot.org Date: Mon, 6 Sep 2021 11:42:18 +0200 Message-Id: <20210906094214.6142-4-heiko.thiery@gmail.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20210906094214.6142-1-heiko.thiery@gmail.com> References: <20210906094214.6142-1-heiko.thiery@gmail.com> MIME-Version: 1.0 Subject: [Buildroot] [PATCH 3/3] boot/uboot: copy IMX firmware files to uboot package dir X-BeenThere: buildroot@lists.buildroot.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gary Bisson , Stephane Viau , Refik Tuzakli , Thomas Petazzoni , Heiko Thiery , Fabio Estevam , Xavier Roumegue Errors-To: buildroot-bounces@lists.buildroot.org Sender: "buildroot" If the U-Boot image is to be build with binman and one of the IMX firmware files (ddr, hdmi) is used, the files are expected in the toplevel directory. Signed-off-by: Heiko Thiery --- boot/uboot/Config.in | 12 ++++++++++++ boot/uboot/uboot.mk | 27 +++++++++++++++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/boot/uboot/Config.in b/boot/uboot/Config.in index 0854fb13cc..da518db118 100644 --- a/boot/uboot/Config.in +++ b/boot/uboot/Config.in @@ -239,6 +239,18 @@ config BR2_TARGET_UBOOT_NEEDS_OPENSBI and that the OpenSBI variable pointing to OpenSBI binary, is passed during the Buildroot build. +config BR2_TARGET_UBOOT_NEEDS_IMX_FIRMWARE + bool "U-Boot needs firmware-imx" + depends on BR2_PACKAGE_FIRMWARE_IMX + depends on BR2_PACKAGE_FIRMWARE_IMX_NEEDS_DDR_FW || \ + BR2_PACKAGE_FIRMWARE_IMX_NEEDS_HDMI_FW + help + Some IMX platforms (such as iMX8m, iMX8mq, iIMX8mm, iIMX8mn) + encapsulate NXP specific firmware (DDR, HDMI) inside U-Boot. + This option makes sure the imx firmware gets built prior to + U-Boot and copies the files from the buildroot binary dir + into the U-Boot source dir. + menu "U-Boot binary format" config BR2_TARGET_UBOOT_FORMAT_AIS diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk index 1a840d9cc1..cf8d6b1f39 100644 --- a/boot/uboot/uboot.mk +++ b/boot/uboot/uboot.mk @@ -180,6 +180,33 @@ UBOOT_DEPENDENCIES += opensbi UBOOT_MAKE_OPTS += OPENSBI=$(BINARIES_DIR)/fw_dynamic.bin endif +# New U-Boot versions can create the IMX specific boot images +# and needs the some NXP firmware blobs. +ifeq ($(BR2_TARGET_UBOOT_NEEDS_IMX_FIRMWARE),y) +UBOOT_DEPENDENCIES += firmware-imx + +ifeq ($(BR2_PACKAGE_FIRMWARE_IMX_NEEDS_HDMI_FW),y) +define UBOOT_COPY_IMX_DDR_FIRMWARE + cp $(BINARIES_DIR)/signed_hdmi_imx8m.bin $(@D)/ +endef +UBOOT_PRE_BUILD_HOOKS += UBOOT_COPY_IMX_DDR_FIRMWARE +endif + +ifeq ($(BR2_PACKAGE_FIRMWARE_IMX_LPDDR4),y) +define UBOOT_COPY_IMX_LPDDR4_FIRMWARE + cp $(BINARIES_DIR)/lpddr4*.bin $(@D)/ +endef +UBOOT_PRE_BUILD_HOOKS += UBOOT_COPY_IMX_LPDDR4_FIRMWARE +endif + +ifeq ($(BR2_PACKAGE_FIRMWARE_IMX_DDR4),y) +define UBOOT_COPY_IMX_DDR4_FIRMWARE + cp $(BINARIES_DIR)/ddr4*.bin $(@D)/ +endef +UBOOT_PRE_BUILD_HOOKS += UBOOT_COPY_IMX_DDR4_FIRMWARE +endif +endif + ifeq ($(BR2_TARGET_UBOOT_NEEDS_DTC),y) UBOOT_DEPENDENCIES += host-dtc endif