From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
To: Heiko Thiery <heiko.thiery@gmail.com>
Cc: Frieder Schrempf <frieder.schrempf@kontron.de>, buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH] configs/kontron_bl_imx8mm_defconfig: new defconfig
Date: Thu, 13 Jan 2022 22:00:57 +0100 [thread overview]
Message-ID: <20220113220057.1db30808@windsurf> (raw)
In-Reply-To: <20220112184821.916646-1-heiko.thiery@gmail.com>
Hello,
On Wed, 12 Jan 2022 19:48:22 +0100
Heiko Thiery <heiko.thiery@gmail.com> wrote:
> diff --git a/board/kontron/bl-imx8mm/boot.cmd b/board/kontron/bl-imx8mm/boot.cmd
> new file mode 100644
> index 0000000000..7ce3198dbc
> --- /dev/null
> +++ b/board/kontron/bl-imx8mm/boot.cmd
> @@ -0,0 +1,8 @@
> +echo "Root File Sytem on MMC${devnum}"
> +setenv rootfs /dev/mmcblk${devnum}p1
> +setenv bootargs root=${rootfs} rootwait rw ${extrabootargs}
> +
> +load ${devtype} ${devnum} ${kernel_addr_r} boot/Image
> +load ${devtype} ${devnum} ${fdt_addr_r} boot/imx8mm-kontron-n801x-s.dtb
> +
> +booti ${kernel_addr_r} - ${fdt_addr_r}
Have you considered using extlinux.conf ? This is generally much easier
than a boot script, and removes the need to generate the boot script.
> diff --git a/board/kontron/bl-imx8mm/patches/uboot/0001-imx-imx8mm-imx8mm-kontron-n801x-s-convert-options-to.patch b/board/kontron/bl-imx8mm/patches/uboot/0001-imx-imx8mm-imx8mm-kontron-n801x-s-convert-options-to.patch
> new file mode 100644
> index 0000000000..ed088dd0f8
> --- /dev/null
> +++ b/board/kontron/bl-imx8mm/patches/uboot/0001-imx-imx8mm-imx8mm-kontron-n801x-s-convert-options-to.patch
> @@ -0,0 +1,28 @@
> +From 95a311af81cd47c44d3d6e3f717f06a06d8f3dfd Mon Sep 17 00:00:00 2001
> +From: Heiko Thiery <heiko.thiery@gmail.com>
> +Date: Mon, 10 Jan 2022 14:13:02 +0100
> +Subject: [PATCH 1/2] imx: imx8mm: imx8mm-kontron-n801x-s: convert options to Kconfig
I suppose the U-Boot patches are on their way upstream?
> diff --git a/board/kontron/bl-imx8mm/post-image.sh b/board/kontron/bl-imx8mm/post-image.sh
> new file mode 100755
> index 0000000000..564211c829
> --- /dev/null
> +++ b/board/kontron/bl-imx8mm/post-image.sh
> @@ -0,0 +1,3 @@
> +#!/bin/sh
> +
> +support/scripts/genimage.sh -c $(dirname $0)/genimage.cfg
Could you call support/scripts/genimage.sh directly as the post-image
script, using the BR2_ROOTFS_POST_SCRIPT_ARGS to pass the -c ...
argument? We already do that in many defconfigs.
> +# Kernel
> +BR2_LINUX_KERNEL=y
> +BR2_LINUX_KERNEL_CUSTOM_VERSION=y
> +BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="5.16"
> +BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y
> +BR2_LINUX_KERNEL_DTS_SUPPORT=y
> +BR2_LINUX_KERNEL_INTREE_DTS_NAME="freescale/imx8mm-kontron-n801x-s"
> +BR2_LINUX_KERNEL_INSTALL_TARGET=y
> +BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y
> +
> +BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_5_16=y
> +
> +BR2_PACKAGE_FREESCALE_IMX=y
> +BR2_PACKAGE_FREESCALE_IMX_PLATFORM_IMX8MM=y
> +BR2_PACKAGE_FIRMWARE_IMX=y
> +
> +# Filesystem / image
> +BR2_TARGET_ROOTFS_EXT2=y
> +BR2_TARGET_ROOTFS_EXT2_4=y
> +BR2_TARGET_ROOTFS_EXT2_SIZE="120M"
> +
> +# Bootloader
> +BR2_TARGET_ARM_TRUSTED_FIRMWARE=y
> +BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION=y
> +BR2_TARGET_ARM_TRUSTED_FIRMWARE_CUSTOM_VERSION_VALUE="v2.6"
> +BR2_TARGET_ARM_TRUSTED_FIRMWARE_PLATFORM="imx8mm"
> +BR2_TARGET_ARM_TRUSTED_FIRMWARE_BL31=y
> +BR2_TARGET_ARM_TRUSTED_FIRMWARE_ADDITIONAL_VARIABLES="IMX_BOOT_UART_BASE=0x30880000"
> +BR2_TARGET_UBOOT=y
> +BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
> +BR2_TARGET_UBOOT_CUSTOM_VERSION=y
> +BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2022.01"
> +BR2_TARGET_UBOOT_BOARD_DEFCONFIG="kontron-sl-mx8mm"
> +BR2_TARGET_UBOOT_NEEDS_DTC=y
> +BR2_TARGET_UBOOT_NEEDS_PYTHON3=y
> +BR2_TARGET_UBOOT_NEEDS_PYLIBFDT=y
> +BR2_TARGET_UBOOT_NEEDS_ATF_BL31=y
> +BR2_TARGET_UBOOT_NEEDS_ATF_BL31_BIN=y
> +BR2_TARGET_UBOOT_NEEDS_IMX_FIRMWARE=y
> +BR2_TARGET_UBOOT_FORMAT_CUSTOM=y
> +BR2_TARGET_UBOOT_FORMAT_CUSTOM_NAME="flash.bin"
> +BR2_TARGET_UBOOT_SPL=y
> +
> +# Required host tools to create the SD/eMMC image
> +BR2_PACKAGE_HOST_GENIMAGE=y
> +BR2_PACKAGE_HOST_UBOOT_TOOLS=y
> +BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT=y
You need FIT support ?
> +BR2_PACKAGE_HOST_UBOOT_TOOLS_BOOT_SCRIPT=y
> +BR2_PACKAGE_HOST_UBOOT_TOOLS_BOOT_SCRIPT_SOURCE="board/kontron/bl-imx8mm/boot.cmd"
These would no longer be needed if switching to extlinux.conf.
Thanks a lot!
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2022-01-13 21:01 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-12 18:48 [Buildroot] [PATCH] configs/kontron_bl_imx8mm_defconfig: new defconfig Heiko Thiery
2022-01-13 21:00 ` Thomas Petazzoni [this message]
2022-01-13 23:14 ` Fabio Estevam
2022-01-14 2:47 ` Fabio Estevam
2022-01-14 9:39 ` Heiko Thiery
2022-01-14 10:55 ` Fabio Estevam
2022-01-14 9:42 ` Heiko Thiery
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220113220057.1db30808@windsurf \
--to=thomas.petazzoni@bootlin.com \
--cc=buildroot@buildroot.org \
--cc=frieder.schrempf@kontron.de \
--cc=heiko.thiery@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox