From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id YMNiEAFRW2eiewEAqHPOHw:P1 (envelope-from ) for ; Thu, 12 Dec 2024 21:09:21 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id YMNiEAFRW2eiewEAqHPOHw (envelope-from ) for ; Thu, 12 Dec 2024 22:09:21 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=APK3naKo; dkim=fail ("headers rsa verify failed") header.d=rimm.ee header.s=herman header.b=GtGoWXxF; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1734037760; a=rsa-sha256; cv=none; b=dzjBugt/wcsFA2YVGlgUeXgVkTZtMyrUdDLvkH4GFrKSrbulmShygiVF3QrkGW8+lAeKM0 rZoM6r4txZ8ilS6tONWUcicAJ3SiCUwRsivzT1dlaJelgjRgXpQv4w17YtRcN9qBDOuZUp jV+QejrMB1DqqkRYXwdMgk9UwzO7b6EYvCGmefdevlsBpvKHmJf0wB+jGPLzZ4WI2/RrCA 8WqnbsIJf/1fUoEUGjK2JOpRkuJ4aiydFF4RE6qQjBLahHXpdD1hmfZQEFFoJGth3WboKG LLzzxLT7IHYG8zGTZKUb52rriEDQ9tLMVPuC5qQcx2yNdj2I+TRH/BeTgPzj3w== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=APK3naKo; dkim=fail ("headers rsa verify failed") header.d=rimm.ee header.s=herman header.b=GtGoWXxF; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1734037760; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=VAGnmjtmHT+VC9H7+39P3Sv17eQJW7d3xhqqDWcE9ic=; b=LoLEyG+FXeyaDFaFciQ5Ep9hpoT9qJzTPBzfQQdqiy09/1iWgDj9ZnBRv0WpfZYAZrCYeC B1vJBfAKN6buFBPSLTyR1N9YlTqIsajDmQECG3W6hRIu3+/eieUoukxk5L/E+pJpSiGVBg gyUtnVkNUp5jJ72KuENmxJzPsCJvhZv0ptqKGH4anNglSB+HPViSanJx15DhXtgXCp5Jzm K+ZdkAHxRboFQqglXpLpQldzRX3mKkSsU+fbxL69gO9hXgBUT52Bv4cG0pFh5BkSUuIY8J S14NUJZTlFr6i/iWhJhEeBumwma0sHokCcfsrgHNSidJ9XSOKqj7b8P03GUmcA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id A2CD44EFB for ; Thu, 12 Dec 2024 22:09:20 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tLqQo-0005tC-Gi; Thu, 12 Dec 2024 16:09:10 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tLqQi-0005sa-QK for guix-patches@gnu.org; Thu, 12 Dec 2024 16:09:05 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1tLqQi-0007fh-IH for guix-patches@gnu.org; Thu, 12 Dec 2024 16:09:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:References:In-Reply-To:Date:From:To:Subject; bh=VAGnmjtmHT+VC9H7+39P3Sv17eQJW7d3xhqqDWcE9ic=; b=APK3naKoYCnnC1nX+DF0Jyi8RRtYebFCweerUK6TBOeNGR93gNvdA2jUR78lGmy8Z5vd0KM958MctN8PBi7gzx9fXTRa7QxZptjjOtEktE38itz5IUuHhURVz5ZOSLVQVSLzFL/teFAfwUZeuk+9zgI4RjNvY21TgHuV0tRfjOFYcjxd9kyQNqioj4V/HEIp+0YfzmacPAQ+jpa+hV/oOQxn2gJA+EkbmDEbJuFSvlfj/VMuil7hhVdRl7UxGf01rrkP3O9jW7YzvsCKpekqB7TAPn32gA7zKDF/6Ie10xISGamH5HGNCMfOH7DqYfNYPZ/YbC9rM7GIyBYu8rAjDg==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1tLqQh-0000xD-Ch; Thu, 12 Dec 2024 16:09:03 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#74842] [PATCH 4/4] gnu: Add make-u-boot-rockchip-package procedure. Resent-From: Herman Rimm Original-Sender: "Debbugs-submit" Resent-CC: efraim@flashner.co.il, vagrant@debian.org, guix-patches@gnu.org Resent-Date: Thu, 12 Dec 2024 21:09:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 74842 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 74842@debbugs.gnu.org Cc: Efraim Flashner , Vagrant Cascadian X-Debbugs-Original-Xcc: Efraim Flashner , Vagrant Cascadian Received: via spool by 74842-submit@debbugs.gnu.org id=B74842.17340377033585 (code B ref 74842); Thu, 12 Dec 2024 21:09:03 +0000 Received: (at 74842) by debbugs.gnu.org; 12 Dec 2024 21:08:23 +0000 Received: from localhost ([127.0.0.1]:40608 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tLqPx-0000vd-Of for submit@debbugs.gnu.org; Thu, 12 Dec 2024 16:08:23 -0500 Received: from 81-205-150-117.fixed.kpn.net ([81.205.150.117]:37851 helo=email.rimm.ee) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1tLqPq-0000uH-TA for 74842@debbugs.gnu.org; Thu, 12 Dec 2024 16:08:13 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rimm.ee; s=herman; t=1734037672; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=VAGnmjtmHT+VC9H7+39P3Sv17eQJW7d3xhqqDWcE9ic=; b=GtGoWXxFD/XUpc/7zk13bbo4lUrUwAXzYBTF3Crluul+rZonIVlEqEytuYkOgbyedxmViG 5eEC3stTxd6Ze0pL2YegYGQZw8wc2B4hLAxSjc5Uc91Ca8RzEz3guWxTiJOmZ4QN55Rhcq RZqSW7KDHvsJr2zKmcm7EkbmyCG/NvbBMCejDSr6b3WIzCPG/8jUueOsFuN/U11mfG01K2 LMlozJD/qgRtGBRb2tc6k7ivNnAZf5K1prl4jtYErILd+i/bUhouHDa8BH0kKwA+rbeiCT SftMZ3awA0tg8/dQ3rqfcoylat+TDTCtqLNcQ4gxSHs1ul5ku7VxM73RVmufwA== Received: by 81-205-150-117.fixed.kpn.net (OpenSMTPD) with ESMTPSA id 381b737c (TLSv1.3:TLS_CHACHA20_POLY1305_SHA256:256:NO) for <74842@debbugs.gnu.org>; Thu, 12 Dec 2024 21:07:52 +0000 (UTC) Date: Thu, 12 Dec 2024 22:07:11 +0100 Message-ID: X-Mailer: git-send-email 2.45.2 In-Reply-To: <6a1609d369654f967bdcb42bec27357b5f522ebf.1734037218.git.herman@rimm.ee> References: <6a1609d369654f967bdcb42bec27357b5f522ebf.1734037218.git.herman@rimm.ee> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Herman Rimm X-ACL-Warn: , Herman Rimm via Guix-patches From: Herman Rimm via Guix-patches via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: 0.33 X-Spam-Score: 0.33 X-Migadu-Queue-Id: A2CD44EFB X-Migadu-Scanner: mx12.migadu.com X-TUID: BexNEXsh1PPq * gnu/packages/bootloaders.scm (make-u-boot-rockchip-package): Add. (u-boot-orangepi-r1-plus-lts-rk3328, u-boot-puma-rk3399, u-boot-rock64-rk3328, u-boot-firefly-rk3399, u-boot-rockpro64-rk3399, u-boot-pinebook-pro-rk3399): Use procedure. Change-Id: I0d7632e46cfed312f8b2843c6fafc912077bc241 --- gnu/packages/bootloaders.scm | 136 +++++++++++------------------------ 1 file changed, 41 insertions(+), 95 deletions(-) diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm index 15cdaddd7e..8d3cda760a 100644 --- a/gnu/packages/bootloaders.scm +++ b/gnu/packages/bootloaders.scm @@ -18,7 +18,7 @@ ;;; Copyright © 2022, 2023 Denis 'GNUtoo' Carikli ;;; Copyright © 2021 Stefan ;;; Copyright © 2022, 2023, 2024 Maxim Cournoyer -;;; Copyright © 2023 Herman Rimm +;;; Copyright © 2023-2024 Herman Rimm ;;; Copyright © 2023 Simon Tournier ;;; Copyright © 2024 Zheng Junjie <873216071@qq.com> ;;; @@ -1145,6 +1145,27 @@ (define*-public (make-u-boot-package board triplet (copy-file file target-file))) uboot-files))))))))))) +(define* (make-u-boot-rockchip-package board soc #:optional configs) + "Return the U-Boot package for BOARD with AAarch64 Rockchip SOC +(System on Chip)." + (let* ((board (string-append board "-" (symbol->string soc))) + (base (make-u-boot-package board "aarch64-linux-gnu" + #:configs configs)) + (atf (match soc + ('rk3399 arm-trusted-firmware-rk3399) + ('rk3328 arm-trusted-firmware-rk3328)))) + (package + (inherit base) + (arguments + (substitute-keyword-arguments (package-arguments base) + ((#:phases phases) + #~(modify-phases #$phases + (add-after 'unpack 'set-environment + (lambda* (#:key inputs #:allow-other-keys) + (let ((atf (assoc-ref inputs #$(package-name atf)))) + (setenv "BL31" (string-append atf "/bl31.elf"))))))))) + (inputs (modify-inputs (package-inputs base) (append atf)))))) + (define-public u-boot-am335x-boneblack (let ((base (make-u-boot-package "am335x_evm" "arm-linux-gnueabihf" @@ -1260,19 +1281,7 @@ (define-public u-boot-novena partition.")) (define-public u-boot-orangepi-r1-plus-lts-rk3328 - (let ((base (make-u-boot-package "orangepi-r1-plus-lts-rk3328" "aarch64-linux-gnu"))) - (package - (inherit base) - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:phases phases) - #~(modify-phases #$phases - (add-after 'unpack 'set-environment - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (setenv "BL31" (search-input-file inputs "bl31.elf")))))))) - (inputs - (modify-inputs (package-inputs base) - (append arm-trusted-firmware-rk3328)))))) + (make-u-boot-rockchip-package "orangepi-r1-plus-lts" 'rk3328)) (define-public u-boot-cubieboard (make-u-boot-package "Cubieboard" "arm-linux-gnueabihf")) @@ -1281,22 +1290,7 @@ (define-public u-boot-cubietruck (make-u-boot-package "Cubietruck" "arm-linux-gnueabihf")) (define-public u-boot-puma-rk3399 - (let ((base (make-u-boot-package "puma-rk3399" "aarch64-linux-gnu"))) - (package - (inherit base) - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:phases phases) - #~(modify-phases #$phases - (add-after 'unpack 'set-environment - (lambda* (#:key inputs #:allow-other-keys) - (setenv "BL31" (search-input-file inputs "/bl31.elf")))) - ;; Phases do not succeed on the bl31 ELF. - (delete 'strip) - (delete 'validate-runpath))))) - (inputs - (modify-inputs (package-inputs base) - (append arm-trusted-firmware-rk3399)))))) + (make-u-boot-rockchip-package "puma" 'rk3399)) (define-public u-boot-qemu-arm (make-u-boot-package "qemu_arm" "arm-linux-gnueabihf" @@ -1417,87 +1411,39 @@ (define-public u-boot-starfive-visionfive2 (append opensbi-for-visionfive2)))))) (define-public u-boot-rock64-rk3328 - (let ((base (make-u-boot-package "rock64-rk3328" "aarch64-linux-gnu"))) - (package - (inherit base) - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:phases phases) - #~(modify-phases #$phases - (add-after 'unpack 'set-environment - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (setenv "BL31" (search-input-file inputs "bl31.elf")))))))) - (inputs - (modify-inputs (package-inputs base) - (append arm-trusted-firmware-rk3328)))))) + (make-u-boot-rockchip-package "rock64" 'rk3328)) (define-public u-boot-firefly-rk3399 - (let ((base (make-u-boot-package "firefly-rk3399" "aarch64-linux-gnu"))) - (package - (inherit base) - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:phases phases) - #~(modify-phases #$phases - (add-after 'unpack 'set-environment - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (setenv "BL31" (search-input-file inputs "bl31.elf")))) - ;; Phases do not succeed on the bl31 ELF. - (delete 'strip) - (delete 'validate-runpath))))) - (inputs - (modify-inputs (package-inputs base) - (append arm-trusted-firmware-rk3399)))))) + (make-u-boot-rockchip-package "firefly" 'rk3399)) (define-public u-boot-rockpro64-rk3399 - (let ((base (make-u-boot-package "rockpro64-rk3399" "aarch64-linux-gnu" - #:configs '("CONFIG_USB=y" - "CONFIG_AHCI=y" - "CONFIG_AHCI_PCI=y" - "CONFIG_SATA=y" - "CONFIG_SATA_SIL=y" - "CONFIG_SCSI=y" - "CONFIG_SCSI_AHCI=y" - "CONFIG_DM_SCSI=y" - ;; Disable SPL FIT signatures, - ;; due to GPLv2 and Openssl - ;; license incompatibilities - "# CONFIG_SPL_FIT_SIGNATURE is not set")))) + (let ((base (make-u-boot-rockchip-package + "rockpro64" 'rk3399 + '("CONFIG_USB=y" + "CONFIG_AHCI=y" + "CONFIG_AHCI_PCI=y" + "CONFIG_SATA=y" + "CONFIG_SATA_SIL=y" + "CONFIG_SCSI=y" + "CONFIG_SCSI_AHCI=y" + "CONFIG_DM_SCSI=y" + ;; Disable SPL FIT signatures, due to GPLv2 and + ;; OpenSSL license incompatibilities. + "# CONFIG_SPL_FIT_SIGNATURE is not set")))) (package (inherit base) (arguments (substitute-keyword-arguments (package-arguments base) ((#:phases phases) #~(modify-phases #$phases - (add-after 'unpack 'set-environment - (lambda* (#:key inputs #:allow-other-keys) - (setenv "BL31" (search-input-file inputs "/bl31.elf")))) (add-after 'unpack 'patch-header (lambda _ (substitute* "include/config_distro_bootcmd.h" (("\"scsi_need_init=") - "\"setenv scsi_need_init")))))))) - (inputs - (modify-inputs (package-inputs base) - (append arm-trusted-firmware-rk3399)))))) + "\"setenv scsi_need_init"))))))))))) (define-public u-boot-pinebook-pro-rk3399 - (let ((base (make-u-boot-package "pinebook-pro-rk3399" "aarch64-linux-gnu"))) - (package - (inherit base) - (arguments - (substitute-keyword-arguments (package-arguments base) - ((#:phases phases) - #~(modify-phases #$phases - (add-after 'unpack 'set-environment - (lambda* (#:key native-inputs inputs #:allow-other-keys) - (setenv "BL31" (search-input-file inputs "bl31.elf")))) - ;; Phases do not succeed on the bl31 ELF. - (delete 'strip) - (delete 'validate-runpath))))) - (inputs - (modify-inputs (package-inputs base) - (append arm-trusted-firmware-rk3399)))))) + (make-u-boot-rockchip-package "pinebook-pro" 'rk3399)) (define*-public (make-u-boot-bin-package u-boot-package #:key -- 2.45.2