From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 244D1C48BC3 for ; Sat, 17 Feb 2024 16:03:50 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id D233A83F26; Sat, 17 Feb 2024 16:03:49 +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 I2UESXaJjbSM; Sat, 17 Feb 2024 16:03:48 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=140.211.166.34; helo=ash.osuosl.org; envelope-from=buildroot-bounces@buildroot.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp1.osuosl.org 5DBE583F07 Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp1.osuosl.org (Postfix) with ESMTP id 5DBE583F07; Sat, 17 Feb 2024 16:03:48 +0000 (UTC) Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 6F6D61BF5A3 for ; Sat, 17 Feb 2024 16:03:21 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 5A54260BF9 for ; Sat, 17 Feb 2024 16:03:21 +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 VIrtD2WIIWHg for ; Sat, 17 Feb 2024 16:03:20 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=2a00:1450:4864:20::234; helo=mail-lj1-x234.google.com; envelope-from=dario.binacchi@amarulasolutions.com; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp3.osuosl.org 3041360BB8 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 3041360BB8 Received: from mail-lj1-x234.google.com (mail-lj1-x234.google.com [IPv6:2a00:1450:4864:20::234]) by smtp3.osuosl.org (Postfix) with ESMTPS id 3041360BB8 for ; Sat, 17 Feb 2024 16:03:19 +0000 (UTC) Received: by mail-lj1-x234.google.com with SMTP id 38308e7fff4ca-2d1094b5568so39962631fa.1 for ; Sat, 17 Feb 2024 08:03:19 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708185797; x=1708790597; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ZTsESzberwCgCoaq4MXwBUKAb2YgRhfKAgp495dacVo=; b=I280mZLEobLSeaTBaZvUbTjD4KbR+1NMUlz9Np4HaOVLsJqv3lRuqpuCXjHYUfNH4q Qw7ZPGYbexXaH8bsDk9w9ZqEg/pbcKE233y7c0bWvgbgyuNsQg3rJdaOI5yFvFcROs6A w75AcMEDMDEdv23kdvhxpP7WGtzKVxcJ92y/Vtk/j1RheAHAouzA8ywUEtPm9eOTqJ2m E5WAkzjZe8zlMOkQJsotqNr18H8KQsJnK/CSz+9oABR6BmLiimu3joAr+N4uagqvltKh qj3BspZa/qohMPOP720lXKkQjYVFy19Y2HWdjRPitY0+QjhsO+MAHGGbN4qKf/dhyyn8 AOcQ== X-Gm-Message-State: AOJu0YzniHJTfbGq2TV7FMqeB8SdhHx2FuYed57YofSIM5uzfSSBwe7x R5sRkVI0kmed9xxOVbjNSlYWxBvUFkgsB3MpOQ0YTyrnk+qFfRxfSX6TF+u/ufytX6xIFInPDzk KT9M= X-Google-Smtp-Source: AGHT+IFKY2kW+NAAVRdU1ZqRGdP/Ik3Ryt2fL+P5Mu81MdIlRQAFDqvVgnKEi3ZuWlX6nRZdxr1pKQ== X-Received: by 2002:a05:6512:3d93:b0:511:4db5:99f1 with SMTP id k19-20020a0565123d9300b005114db599f1mr7735654lfv.47.1708185797463; Sat, 17 Feb 2024 08:03:17 -0800 (PST) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-87-5-96-195.retail.telecomitalia.it. [87.5.96.195]) by smtp.gmail.com with ESMTPSA id dj13-20020a05640231ad00b0055f0b3ec5d8sm973414edb.36.2024.02.17.08.03.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 17 Feb 2024 08:03:17 -0800 (PST) From: Dario Binacchi To: buildroot@buildroot.org Date: Sat, 17 Feb 2024 17:02:39 +0100 Message-ID: <20240217160244.1320482-16-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240217160244.1320482-1-dario.binacchi@amarulasolutions.com> References: <20240217160244.1320482-1-dario.binacchi@amarulasolutions.com> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1708185797; x=1708790597; darn=buildroot.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ZTsESzberwCgCoaq4MXwBUKAb2YgRhfKAgp495dacVo=; b=HroafRuk5y64buWKiRuRTLo5nOgmyEbpe05Gk8HbfkRuLf7Tg6La6LGX2wL7R5c+xY V3bpueSU3aSjqckJrrf7bY7+2DhEzrPwEUrK3bQ8Tg93TwPcS/i1rznfEv0L7takxwsE vgkL8Vsxg4ZYfJcmAzzbi8TMZJWqoMgrMUDFw= X-Mailman-Original-Authentication-Results: smtp3.osuosl.org; dmarc=pass (p=none dis=none) header.from=amarulasolutions.com X-Mailman-Original-Authentication-Results: smtp3.osuosl.org; dkim=pass (1024-bit key) header.d=amarulasolutions.com header.i=@amarulasolutions.com header.a=rsa-sha256 header.s=google header.b=HroafRuk Subject: [Buildroot] [PATCH v4 15/20] configs/ti_am62x_sk_defconfig: bump U-Boot version to 2024.01 X-BeenThere: buildroot@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: Dario Binacchi , michael@amarulasolutions.com, linux-amarula@amarulasolutions.com, Asaf Kahlon , Xuanhao Shi , James Hilliard , Thomas Petazzoni , Romain Naour , Andreas Dannenberg , Alexander Sverdlin , bryce@redpinelabs.com, Anand Gadiyar Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: buildroot-bounces@buildroot.org Sender: "buildroot" The 2024.01 version of U-Boot for the am62x-sk board has introduced two major changes: - The device tree k3-am625-sk.dtb is no longer searched in /boot, but in /boot/dtb/ti. Hence, the disabling of BR2_LINUX_KERNEL_INSTALL_TARGET and the use of extlinux.conf for the proper loading of the device tree. Furthermore, the parameter BR2_ROOTFS_POST_SCRIPT_ARGS was used to auto-generate the extlinux.conf file so that developers can change the kernel loading options by modifying the .config. - The use of binman for building images. Tested on SK-AM62B-P1. Signed-off-by: Dario Binacchi --- Changes in v4: - bump to 204.01 instead of 2023.10 - Update the commit message - Replace 'PARTUUID=00000000-02' with '/dev/mmcblk1p2' where to get rootfs in the BR2_ROOTFS_POST_SCRIPT_ARGS insided the ti_am62x_sk_defconfig. Changes in v2: - Update the commit message - Drop Python options required by binman. - Enable BR2_TARGET_TI_K3_R5_LOADER_USE_BINMAN. This option automatically selects the Python modules required by binman. Signed-off-by: Dario Binacchi --- board/ti/am62x-sk/genimage.cfg | 7 ++++- board/ti/am62x-sk/post-build.sh | 49 +++++++++++++++++++++++++++++++++ board/ti/am62x-sk/post-image.sh | 5 ++++ configs/ti_am62x_sk_defconfig | 11 ++++---- 4 files changed, 66 insertions(+), 6 deletions(-) create mode 100755 board/ti/am62x-sk/post-build.sh create mode 100755 board/ti/am62x-sk/post-image.sh diff --git a/board/ti/am62x-sk/genimage.cfg b/board/ti/am62x-sk/genimage.cfg index 26304fe98f99..398209f4d831 100644 --- a/board/ti/am62x-sk/genimage.cfg +++ b/board/ti/am62x-sk/genimage.cfg @@ -4,10 +4,15 @@ image boot.vfat { "tiboot3.bin", "tispl.bin", "u-boot.img", + "k3-am625-sk.dtb", + "Image" + } + file extlinux/extlinux.conf { + image = extlinux.conf } } - size = 16M + size = 64M } image sdcard.img { diff --git a/board/ti/am62x-sk/post-build.sh b/board/ti/am62x-sk/post-build.sh new file mode 100755 index 000000000000..0f1f98ef217a --- /dev/null +++ b/board/ti/am62x-sk/post-build.sh @@ -0,0 +1,49 @@ +#!/bin/sh -x + +# genimage will need to find the extlinux.conf +# in the binaries directory + +die() { + cat <&2 +Error: $@ + +Usage: ${0} -c -r [-x ] +EOF + exit 1 +} + +o='c:r:x:' +O='console:,root:,extra-args:' +opts="$(getopt -n "${0##*/}" -o "${o}" -l "${O}" -- "${@}")" +eval set -- "${opts}" +while [ ${#} -gt 0 ]; do + case "${1}" in + (-c|--console) + CONSOLE="${2}"; shift 2 + ;; + (-r|--root) + ROOT="${2}"; shift 2 + ;; + (-x|--extra-args) + EXTRA_ARGS="${2}"; shift 2 + ;; + (--) + shift 1; break + ;; + esac +done + +[ -n "${CONSOLE}" ] || die "Missing argument" +[ -n "${ROOT}" ] || die "Missing argument" +append="console=${CONSOLE} root=${ROOT} rw rootfstype=ext4 rootwait" +if [ -n "${EXTRA_ARGS}" ]; then + append="${append} ${EXTRA_ARGS}" +fi + +mkdir -p "${BINARIES_DIR}" +cat <<-__HEADER_EOF > "${BINARIES_DIR}/extlinux.conf" + label am62x-sk-buildroot + kernel /Image + fdtdir / + append ${append} + __HEADER_EOF diff --git a/board/ti/am62x-sk/post-image.sh b/board/ti/am62x-sk/post-image.sh new file mode 100755 index 000000000000..34f732c091ad --- /dev/null +++ b/board/ti/am62x-sk/post-image.sh @@ -0,0 +1,5 @@ +#!/bin/sh -x + +BOARD_DIR="$(dirname "$0")" + +support/scripts/genimage.sh -c "${BOARD_DIR}/genimage.cfg" diff --git a/configs/ti_am62x_sk_defconfig b/configs/ti_am62x_sk_defconfig index a4cffe09ce72..193301c8b941 100644 --- a/configs/ti_am62x_sk_defconfig +++ b/configs/ti_am62x_sk_defconfig @@ -1,14 +1,14 @@ BR2_aarch64=y BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_6_4=y -BR2_ROOTFS_POST_IMAGE_SCRIPT="support/scripts/genimage.sh" -BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/ti/am62x-sk/genimage.cfg" +BR2_ROOTFS_POST_BUILD_SCRIPT="board/ti/am62x-sk/post-build.sh" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/ti/am62x-sk/post-image.sh" +BR2_ROOTFS_POST_SCRIPT_ARGS="-c ttyS2,115200n8 -r /dev/mmcblk1p2 -x earlycon=ns16550a,mmio32,0x02800000" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="6.4.16" BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_INTREE_DTS_NAME="ti/k3-am625-sk" -BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_PACKAGE_LINUX_FIRMWARE=y BR2_PACKAGE_LINUX_FIRMWARE_TI_WL18XX=y BR2_TARGET_ROOTFS_EXT2=y @@ -27,14 +27,15 @@ BR2_TARGET_TI_K3_IMAGE_GEN=y BR2_TARGET_TI_K3_IMAGE_GEN_SOC_AM62X=y BR2_TARGET_TI_K3_R5_LOADER=y BR2_TARGET_TI_K3_R5_LOADER_CUSTOM_VERSION=y -BR2_TARGET_TI_K3_R5_LOADER_CUSTOM_VERSION_VALUE="2022.10" +BR2_TARGET_TI_K3_R5_LOADER_CUSTOM_VERSION_VALUE="2024.01" BR2_TARGET_TI_K3_R5_LOADER_BOARD_DEFCONFIG="am62x_evm_r5" BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y BR2_TARGET_UBOOT_CUSTOM_VERSION=y -BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2022.10" +BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2024.01" BR2_TARGET_UBOOT_BOARD_DEFCONFIG="am62x_evm_a53" BR2_TARGET_UBOOT_NEEDS_DTC=y +BR2_TARGET_UBOOT_NEEDS_PYLIBFDT=y BR2_TARGET_UBOOT_NEEDS_OPENSSL=y BR2_TARGET_UBOOT_NEEDS_ATF_BL31=y BR2_TARGET_UBOOT_NEEDS_TI_K3_DM=y -- 2.43.0 _______________________________________________ buildroot mailing list buildroot@buildroot.org https://lists.buildroot.org/mailman/listinfo/buildroot