From patchwork Sun Jun 9 14:57:48 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joris OFFOUGA X-Patchwork-Id: 1112654 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@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; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="Ldm4+Yqa"; dkim-atps=neutral Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45MKBr6ChGz9s6w for ; Mon, 10 Jun 2019 00:58:12 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 29D8C85B99; Sun, 9 Jun 2019 14:58:11 +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 I0QWY1ZlXv2Z; Sun, 9 Jun 2019 14:58:09 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 1AB5285533; Sun, 9 Jun 2019 14:58:09 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 755E31BF59C for ; Sun, 9 Jun 2019 14:58:08 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 72A1287476 for ; Sun, 9 Jun 2019 14:58:08 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ej-RfrrB9pcl for ; Sun, 9 Jun 2019 14:58:07 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wr1-f68.google.com (mail-wr1-f68.google.com [209.85.221.68]) by hemlock.osuosl.org (Postfix) with ESMTPS id 8F49787568 for ; Sun, 9 Jun 2019 14:58:07 +0000 (UTC) Received: by mail-wr1-f68.google.com with SMTP id b17so6609226wrq.11 for ; Sun, 09 Jun 2019 07:58:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=VpR7lDHQkjbVbbJHQTE7V74vUVoFRv2SRmJHAJ9d2iI=; b=Ldm4+YqaXnAX6N2qFin2i5bWqZ/sdOcyVGmWSM/fniV2YG44MaHytGBYBmdq3tCbp+ 1+FG5xC1ezRLIqEeteq+i5cUNKDnuTYYu2F2eq0oxAIdBgsgYfuf0auz6mDWO3kHZkbl qONEFdON8bKe2C97ub6Uq9tXO0gc+wlVz39c+BPM7tJkcuTH6WfPhizbPO4zpBh0fIp+ uCCLZlziT406Pzp43HkEmg2Xi+gBAWp/uu3xURKGkDAKE1ZzvKGJtxCtVtfHfSnm/iwQ 8g0/D7o1TqeoocDjwuk1kTkB/fTKczBXh9dKE82Q+FlSzw5e0m3VT/NvLnbHJ727jeV7 HnUw== 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; bh=VpR7lDHQkjbVbbJHQTE7V74vUVoFRv2SRmJHAJ9d2iI=; b=OOQTRGHaRWfqMxJmGoN++0UxeT3aSGAqtQp74Ur+nG8kXJdNEPltFHT60jzFMNEC8b PHQdYDHOqpagJyMHoGHCXrKlAqsxmIO2OqPFlQtcGIIBgZmMH0JhIkLEsU665ANIa8Kc avUbLowhoyd6YbB1OQJtymByW7iBanuIc9LEDxAOO0SfWRgGMYIZDeUv1RglveDJCVly B+jjRugPQrO4D2qZWaFx3375IFOLtkoxwWy5VpX6wiWQg+BUnEn/l+NfB2kY44SXWB9S ipV6vgfjIxT8mNISF99VMPLkTqb+rOsbHcatlC0uRefc7EQCn8YyVMcL52OnAmUvMwVw tIdg== X-Gm-Message-State: APjAAAVm6csAls0YI52Pn3Kwo0Ru9u301nOgdgjirErz8ygkVuya+Jk9 e/ufOKFrYoqnXk++Ec5k7krYzEgYbjI= X-Google-Smtp-Source: APXvYqyCzq1ajzbCzTtJphUEReUhdsKt3kxCTnHuqyZ9ocIvpqcyHw8Giac906MtrfLbPugrSTQJEw== X-Received: by 2002:a5d:4bc7:: with SMTP id l7mr12993112wrt.96.1560092285835; Sun, 09 Jun 2019 07:58:05 -0700 (PDT) Received: from furher.home ([2a01:cb19:16b:9900:38ad:5796:9d4b:19c2]) by smtp.gmail.com with ESMTPSA id 11sm7504448wmd.23.2019.06.09.07.58.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 09 Jun 2019 07:58:05 -0700 (PDT) From: Joris Offouga To: buildroot@buildroot.org Date: Sun, 9 Jun 2019 16:57:48 +0200 Message-Id: <20190609145749.28766-2-offougajoris@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190609145749.28766-1-offougajoris@gmail.com> References: <20190609145749.28766-1-offougajoris@gmail.com> Subject: [Buildroot] [PATCH 2/3] boards/freescale/common: Introduce template_no_boot_part X-BeenThere: buildroot@busybox.net 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: Pierre-Jean Texier , Joris Offouga MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" This includes the no_boot_part templates which use a /boot included in rootfs. Signed-off-by: Joris Offouga Signed-off-by: Pierre-Jean Texier --- .../imx/genimage.cfg.template_no_boot_part | 23 +++++++++++++++ .../genimage.cfg.template_no_boot_part_spl | 29 +++++++++++++++++++ board/freescale/common/imx/post-image.sh | 6 ++++ 3 files changed, 58 insertions(+) create mode 100644 board/freescale/common/imx/genimage.cfg.template_no_boot_part create mode 100644 board/freescale/common/imx/genimage.cfg.template_no_boot_part_spl diff --git a/board/freescale/common/imx/genimage.cfg.template_no_boot_part b/board/freescale/common/imx/genimage.cfg.template_no_boot_part new file mode 100644 index 0000000000..9e19b4ee3e --- /dev/null +++ b/board/freescale/common/imx/genimage.cfg.template_no_boot_part @@ -0,0 +1,23 @@ +# Minimal SD card image for the Freescale boards Template +# +# We mimic the .sdcard Freescale's image format: +# * the SD card must have 1 kB free space at the beginning, +# * U-Boot is dumped as is, +# * a single root filesystem partition is required (ext2, ext3 or ext4) +# + +image sdcard.img { + hdimage { + } + + partition u-boot { + in-partition-table = "no" + image = "%UBOOTBIN%" + offset = 1024 + } + + partition rootfs { + partition-type = 0x83 + image = "rootfs.ext2" + } +} diff --git a/board/freescale/common/imx/genimage.cfg.template_no_boot_part_spl b/board/freescale/common/imx/genimage.cfg.template_no_boot_part_spl new file mode 100644 index 0000000000..6d3ae183e3 --- /dev/null +++ b/board/freescale/common/imx/genimage.cfg.template_no_boot_part_spl @@ -0,0 +1,29 @@ +# Minimal SD card image for the Freescale boards Template for SPL Boot +# +# We mimic the .sdcard Freescale's image format: +# * the SD card must have 1 kB free space at the beginning, +# * U-Boot is dumped as is, +# * a single root filesystem partition is required (ext2, ext3 or ext4) +# + +image sdcard.img { + hdimage { + } + + partition spl { + in-partition-table = "no" + image = "SPL" + offset = 1024 + } + + partition u-boot-img { + in-partition-table = "no" + image = "u-boot.img" + offset = 69K + } + + partition rootfs { + partition-type = 0x83 + image = "rootfs.ext2" + } +} diff --git a/board/freescale/common/imx/post-image.sh b/board/freescale/common/imx/post-image.sh index 12a5bea73b..851ce97c57 100755 --- a/board/freescale/common/imx/post-image.sh +++ b/board/freescale/common/imx/post-image.sh @@ -36,6 +36,12 @@ genimage_type() echo "genimage.cfg.template_imx8" elif grep -Eq "^BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX8X=y$" ${BR2_CONFIG}; then echo "genimage.cfg.template_imx8" + elif grep -Eq "^BR2_LINUX_KERNEL_INSTALL_TARGET=y$" ${BR2_CONFIG}; then + if grep -Eq "^BR2_TARGET_UBOOT_SPL=y$" ${BR2_CONFIG}; then + echo "genimage.cfg.template_no_boot_part_spl" + else + echo "genimage.cfg.template_no_boot_part" + fi elif grep -Eq "^BR2_TARGET_UBOOT_SPL=y$" ${BR2_CONFIG}; then echo "genimage.cfg.template_spl" else