From patchwork Fri Aug 12 14:27:15 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: phodina X-Patchwork-Id: 41583 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id E889727BBEA; Fri, 12 Aug 2022 15:28:33 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 3EB3427BBE9 for ; Fri, 12 Aug 2022 15:28:33 +0100 (BST) Received: from localhost ([::1]:39002 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oMVeK-0008Uj-D4 for patchwork@mira.cbaines.net; Fri, 12 Aug 2022 10:28:32 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40390) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oMVdq-0008DH-D1 for guix-patches@gnu.org; Fri, 12 Aug 2022 10:28:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40547) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oMVdq-0006M7-4R for guix-patches@gnu.org; Fri, 12 Aug 2022 10:28:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oMVdp-0002Yb-So for guix-patches@gnu.org; Fri, 12 Aug 2022 10:28:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#48314] [PATCH v3] Install guix system on Raspberry Pi Resent-From: phodina Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 12 Aug 2022 14:28:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48314 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Stefan Cc: Vagrant Cascadian , dannym@scratchpost.org, Ludovic =?utf-8?q?Court=C3=A8s?= , 48314@debbugs.gnu.org Received: via spool by 48314-submit@debbugs.gnu.org id=B48314.16603144519789 (code B ref 48314); Fri, 12 Aug 2022 14:28:01 +0000 Received: (at 48314) by debbugs.gnu.org; 12 Aug 2022 14:27:31 +0000 Received: from localhost ([127.0.0.1]:58529 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMVdK-0002Xp-TH for submit@debbugs.gnu.org; Fri, 12 Aug 2022 10:27:31 -0400 Received: from mail-40131.protonmail.ch ([185.70.40.131]:60241) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oMVdH-0002XZ-Tp for 48314@debbugs.gnu.org; Fri, 12 Aug 2022 10:27:29 -0400 Date: Fri, 12 Aug 2022 14:27:15 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1660314441; x=1660573641; bh=eTae+9b1qVMxTnoj2dIAd/VS0oroNNx3u9MbJHpEq/Q=; h=Date:To:From:Cc:Reply-To:Subject:Message-ID:In-Reply-To: References:Feedback-ID:From:To:Cc:Date:Subject:Reply-To: Feedback-ID:Message-ID; b=r+RTOXDYikjjXMFTiQ5qBcYM2j8Eqcm5bIHVagWUNy62tmYfIzonvpp+pyuIsR412 ydbWoAk4r1fnYmSE45CQ7JEp1TU0Hh2InsM+m/rTHi6SGm5yzcaAz4mASbeuCu4T9z QZJQDiIKpBc+bu+p9yyDg9IRm9s4QoJn8Bx2chlarKRYvuaO3cjaXALLV6lkplO1Qe 4Y/VkQl4G7hWSUCBGq6E39a4IX0N3WbDW/h07pYa+fwEslDavt441rosqpqWdAYt0p eXJOXHrBNWQBd+C9BnkT8ksLjlX7VYWxbKNykY/rQDYxSTyi+akWEbk/85/1yoaAPw gbgZLUKha5ksA== Message-ID: In-Reply-To: <1707AE25-4041-462A-B7D0-8611A02B0E41@vodafonemail.de> References: <1707AE25-4041-462A-B7D0-8611A02B0E41@vodafonemail.de> Feedback-ID: 14143818:user:proton MIME-Version: 1.0 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: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: phodina X-ACL-Warn: , phodina via Guix-patches X-Patchwork-Original-From: phodina via Guix-patches via From: phodina X-getmail-retrieved-from-mailbox: Patches Hi Stefan! Good news. I managed to run Guix libre kernel on the raspberry pi. Thanks for the help along the way! pi@raspberrypi-guix ~$ uname -a Linux raspberrypi-guix 5.18.16-gnu #1 SMP PREEMPT 1 aarch64 GNU/Linux The issue was in the firmware, therefore I'll post the hashes of the files from the EFI partition: pi@raspberrypi-guix ~$ sha256sum /boot/efi/* 010beacf073dbf7a4be24288a5c8b93001f0d852387dce50bf50de51a7412cd6 /boot/efi/bcm2711-rpi-400.dtb 489645357820f2e7e8f13841c901ba9571b779c07b3203f1627538d04ce45ad3 /boot/efi/bcm2711-rpi-4-b.dtb c0f057eea9e357341265910000e56dab94b3200465b0556deb1eda3af117d3c9 /boot/efi/bcm2837-rpi-3-a-plus.dtb df83b6dc6cda7e8eae62e8316b02a4c1659a6b0cf874c6caa075be9413a00b98 /boot/efi/bcm2837-rpi-3-b.dtb c008e84ac57aa9c35aedabd1ed2cb4290088e33d85d1ef8ca56c5ef9b5f0d13c /boot/efi/bcm2837-rpi-3-b-plus.dtb 6a1cc758d38edcf9f9213a8fcbc75d4bf06fbd86806b4430c15742b6ab427de9 /boot/efi/bcm2837-rpi-cm3-io3.dtb 69309823da13dc96b89e3d82b44f820e4f84efa79d207adad2c8784559794f03 /boot/efi/bootcode.bin 1ac38b353f924c56c5d5a587971f3f81d09c433787b99f889368fd342c4336da /boot/efi/bootloader.txt df0ac4af19615f13ff7ffa395ae553c70813ef9d2a82fab0e1175adf80ed1294 /boot/efi/cmdline.txt 9d4975d57f5eb54b08a430cb3d677e5dbf23ed48c73fe33a4e3efdfc35f8d41e /boot/efi/config.txt bcc22553ef64d361270103e84c80ab5362bdb2ffba3c9eea13ee3de60f6cbaff /boot/efi/dtb.txt 22db24c621c326d907c7b8c5975b1730e6ce78dea680bec3958d907093031638 /boot/efi/fixup4cd.dat 7d28775bff4781bda065f37fbb64c88ed1b56d1f4af79d85f792032f55bb6de7 /boot/efi/fixup4.dat b0d299dd46ddecd2c4eeeca61f42d114a0c464dcd6165861a662d118daa3afc0 /boot/efi/fixup4db.dat 495076ed0488703ba59bd0d43bc577ad1695470379263854197a752cd1989330 /boot/efi/fixup4x.dat 22db24c621c326d907c7b8c5975b1730e6ce78dea680bec3958d907093031638 /boot/efi/fixup_cd.dat 8e90c8a379f3f99ee59370c50e48853db82669dbd6515d4ce08a24307d3dc4c5 /boot/efi/fixup.dat 4f5d2433956f64cec640ae91dc47bdea3aa2c6c7cc579faafb779826bd7e554c /boot/efi/fixup_db.dat 82bbf5a3f86f73a41e9f8975deb75e50ab4d7581500a43ec7f0fcc42214948dd /boot/efi/fixup_x.dat 9756eca19be1a443fc6a6cd5f8ffb0759d8b5d68f24248829d39abdc59388490 /boot/efi/manifest 9e1474d3b3078bb80e87f65a5122fd4a8a828b563de5652b37d8b40019b3a51a /boot/efi/start4cd.elf 2dfb27b876ec00e54857e199e939def019b148010f03ce1947e4b48fa226e4f7 /boot/efi/start4db.elf a607afd09523830bd524eafa2eb3f530d70cef643eb8eca14a80dcbd6830ec8f /boot/efi/start4.elf 7ffa3ce1f93f61737fee68f61747b876fd1b15203553ebc096d2b64d79fb7da2 /boot/efi/start4x.elf b21aeceec40aff935f70dfe3adc4d96963e61d4696f909ad910f299da978d8bb /boot/efi/start_cd.elf 378e84616f28e63cb33c794e3430b7deeca5bb84067f79e71408f6aab587e0e7 /boot/efi/start_db.elf e4a374d78f31d333b20ab128a614d3549f9dfe4103781c0938104fc0dd45d3fc /boot/efi/start.elf dbdeb7c679566419035e70db8aff90954ca6ba45a579e990886ddc0b964b2621 /boot/efi/start_x.elf f9c7d5534c787479601f1e70b4b108cd765445aecbc154296d0d35f423045ca4 /boot/efi/sysconf.txt d47f45c6221ccaaf1ca0e66d01b90fca350a0b06b4c7a44a81b6f68a99f36607 /boot/efi/u-boot.bin I'll test it also on RPi3 and I'll change the storage media to SSD on my RPi4 to provide more space and faster reliable storage. - I just have question regarding the example if it wouldn't be better to prepare the whole image - partition the SD card and just copy it to the actual media? - Should there be some manual how to prepare the firmware files or format the SD card in case we prepare just the root filesystem and bootloader? IMHO having ISO image for Raspberry Pi 3,4 (aarch64) would be great as it would allow them to run Guix easily without need to build it on some other aarch64 machine or resort to crosscompile. What do you think? Also there's small patch to fix deprecated calls in os-defintion files. ---- Petr Signed-off-by: Maxim Cournoyer diff --git a/gnu/system/examples/raspberry-pi-64-nfs-root.tmpl b/gnu/system/examples/raspberry-pi-64-nfs-root.tmpl y-pi-64-nfs-root.tmpl index a1e41e3399..279620b0fb 100644 --- a/gnu/system/examples/raspberry-pi-64-nfs-root.tmpl +++ b/gnu/system/examples/raspberry-pi-64-nfs-root.tmpl @@ -30,7 +30,7 @@ (timezone "Europe/Berlin") (bootloader (bootloader-configuration (bootloader grub-efi-bootloader-chain-raspi-64) - (target "/boot/efi") + (targets (list "/boot/efi")) (theme (grub-theme (resolution '(1920 . 1080)) (image (file-append %artwork-repository @@ -49,7 +49,10 @@ (device ":/export/raspberrypi/guix") (options "addr=10.20.30.40,vers=4.1")) %base-file-systems)) - (swap-devices '("/run/swapfile")) + (swap-devices + (list + (swap-space + (target "/run/swapfile")))) (users (cons* (user-account (name "pi") (group "users") diff --git a/gnu/system/examples/raspberry-pi-64.tmpl b/gnu/system/examples/raspberry-pi-64.tmpl index 7e18f00d86..0739582cf0 100644 --- a/gnu/system/examples/raspberry-pi-64.tmpl +++ b/gnu/system/examples/raspberry-pi-64.tmpl @@ -29,7 +29,7 @@ (timezone "Europe/Berlin") (bootloader (bootloader-configuration (bootloader grub-efi-bootloader-chain-raspi-64) - (target "/boot/efi") + (targets (list "/boot/efi")) (theme (grub-theme (resolution '(1920 . 1080)) (image (file-append %artwork-repository @@ -53,7 +53,10 @@ (type "vfat") (device (file-system-label "EFI"))) %base-file-systems)) - (swap-devices '("/run/swapfile")) + (swap-devices + (list + (swap-space + (target "/run/swapfile")))) (users (cons* (user-account (name "pi") (group "users")