From patchwork Tue Nov 14 12:57:05 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 837847 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.137; helo=fraxinus.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="MbHotypz"; dkim-atps=neutral Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3ybpB20nRqz9sDB for ; Wed, 15 Nov 2017 00:23:54 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 698E986DD3; Tue, 14 Nov 2017 13:23:49 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RD-BM8b5bvvQ; Tue, 14 Nov 2017 13:23:48 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 5DF6786DEE; Tue, 14 Nov 2017 13:23:48 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id ADF111C056F for ; Tue, 14 Nov 2017 12:58:55 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id A6AC082F4D for ; Tue, 14 Nov 2017 12:58:55 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 4elbzS3IfkZM for ; Tue, 14 Nov 2017 12:58:54 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wm0-f67.google.com (mail-wm0-f67.google.com [74.125.82.67]) by whitealder.osuosl.org (Postfix) with ESMTPS id 73A1782B68 for ; Tue, 14 Nov 2017 12:58:54 +0000 (UTC) Received: by mail-wm0-f67.google.com with SMTP id l8so15680747wmg.4 for ; Tue, 14 Nov 2017 04:58:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=w7n6bbKJ3+V1G3jem7cmM7e/AWW4QOSNhWZafp35FJM=; b=MbHotypzd1fzcgigtp0dblLb1mJvO5Fa9gOw9o1/deIpiwBCqt2yEqFbw+lIuFmjER SnwPeEkq1+J7I6l1SEt8h5ZFiLWs/AoEL+WYTwbqMLx1yMmOmzRDpXdvFHeLGHmnxJS1 KvjCJfyKcsaJWaAPkQN0w0T03OYZ4/zN9I/Qc+XtDeVfbmSt7ZaI/jg1v7zDnn0cj0Cu wtn56LccCaDaPq6IC7f54uUqKhI7yAD3extdfcS8UyqqyhItrjZCASWwCPVGiwYxjdAh az0i58ywEE3pDjAQctwfJlnRjZnrYh9ZGneXWqO289EAnnGrHdherJI7+W77s9p/QBxu PffA== 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; bh=w7n6bbKJ3+V1G3jem7cmM7e/AWW4QOSNhWZafp35FJM=; b=iSuECexeV/XTbM9FSO7OJrya0zEVqrcovkIZmgoaeJanqGbq+p96i9H69gCm4PHmGy 3O2iUN76JnRIixVl7UT7+BU2rYXvAUwqSypbojyoUZlvQwSqZ8bJBFAotUbZxgQg22Z0 ld87w+3bqae0iCCleAInkt/VgVXP/xcELpGlGjT89fj6kc1obp9jRljH22CgpDp3xKKi crOniwRn3IM75PbuITVME+qzFS89CNpweSmHoVa/8XRDSqWXD1s3ETgg/mT4XTDziTM+ BxntbSbV1YInM5F7vBSdNLT0a9V4ceCKJzQV7GMe+CjU9PQno/gKzBurOG6Qxjyue/xI dGrw== X-Gm-Message-State: AJaThX6ZMqmXJ5krezrLbYfyTqlY8FJn8ZuL4H20reoWBhwLJYx259Ch DH0/bQzTRFaqNR0ZXFO7ZbUdvZig X-Google-Smtp-Source: AGs4zMYpBYXhD8GkYFjz8kkzmcjDWoECY7StFqiRQa8HyPUvp4nROjUZWf9dAedIDce4GiYhBEeEeQ== X-Received: by 10.28.237.14 with SMTP id l14mr10104055wmh.88.1510664332619; Tue, 14 Nov 2017 04:58:52 -0800 (PST) Received: from localhost.localdomain (micene.amarulasolutions.com. [138.201.192.134]) by smtp.gmail.com with ESMTPSA id 7sm17515679wmq.46.2017.11.14.04.58.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 14 Nov 2017 04:58:51 -0800 (PST) From: Jagan Teki X-Google-Original-From: Jagan Teki To: Thomas Petazzoni Date: Tue, 14 Nov 2017 13:57:05 +0100 Message-Id: <1510664226-32208-1-git-send-email-jagan@amarulasolutions.com> X-Mailer: git-send-email 1.9.1 Subject: [Buildroot] [PATCH v3 1/2] uboot: Add support for U-Boot TPL X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.24 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: buildroot@busybox.net, Michael Trimarchi , Jagan Teki MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" TPL is first stage bootloader, On rk3288 vyasa board due to size limitation on SPL. Since the size of SPL can't be exceeded 0x8000 bytes in RK3288, it is not possible add new SPL features like Falcon mode or etc. So add TPL stage so-that adding new features to SPL is possible. - TPL: DRAM init, clocks - SPL: MMC, falcon, etc u-boot-tpl.bin is the file name. Signed-off-by: Jagan Teki --- Changes for v3, v2: - None boot/uboot/Config.in | 25 +++++++++++++++++++++++++ boot/uboot/uboot.mk | 5 +++++ 2 files changed, 30 insertions(+) diff --git a/boot/uboot/Config.in b/boot/uboot/Config.in index 8215912..43e4947 100644 --- a/boot/uboot/Config.in +++ b/boot/uboot/Config.in @@ -342,6 +342,31 @@ config BR2_TARGET_UBOOT_SPL_NAME u-boot build. For most platform it is spl/u-boot-spl.bin but not always. It is MLO on OMAP and SPL on i.MX6 for example. +config BR2_TARGET_UBOOT_TPL + bool "Install U-Boot TPL binary image" + depends on BR2_TARGET_UBOOT_SPL + help + Install the U-Boot TPL binary image to the images + directory. + TPL is first stage bootloader, On rk3288 vyasa board due to size + limitation on SPL. + + Since the size of SPL can't be exceeded 0x8000 bytes in RK3288, + it is not possible add new SPL features like Falcon mode or etc. + + So add TPL stage so-that adding new features to SPL is possible. + - TPL: DRAM init, clocks + - SPL: MMC, falcon, etc + +config BR2_TARGET_UBOOT_TPL_NAME + string "U-Boot TPL binary image name" + default "tpl/u-boot-tpl.bin" + depends on BR2_TARGET_UBOOT_TPL + help + A space-separated list of TPL binaries, generated during + u-boot build. For most platform it is spl/u-boot-tpl.bin but + not always. + config BR2_TARGET_UBOOT_ZYNQ_IMAGE bool "Generate image for Xilinx Zynq" depends on BR2_arm diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk index fdacf16..5702ca6 100644 --- a/boot/uboot/uboot.mk +++ b/boot/uboot/uboot.mk @@ -242,6 +242,11 @@ define UBOOT_INSTALL_IMAGES_CMDS cp -dpf $(@D)/$(f) $(BINARIES_DIR)/ ) ) + $(if $(BR2_TARGET_UBOOT_TPL), + $(foreach f,$(call qstrip,$(BR2_TARGET_UBOOT_TPL_NAME)), \ + cp -dpf $(@D)/$(f) $(BINARIES_DIR)/ + ) + ) $(if $(BR2_TARGET_UBOOT_ENVIMAGE), cat $(call qstrip,$(BR2_TARGET_UBOOT_ENVIMAGE_SOURCE)) | \ $(HOST_DIR)/bin/mkenvimage -s $(BR2_TARGET_UBOOT_ENVIMAGE_SIZE) \