From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id EEn4MIL4oGNCTwAAbAwnHQ (envelope-from ) for ; Tue, 20 Dec 2022 00:49:22 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id 6Jk4MYL4oGMM5QAA9RJhRA (envelope-from ) for ; Tue, 20 Dec 2022 00:49:22 +0100 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 60AFB15153 for ; Tue, 20 Dec 2022 00:49:22 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p7PsI-0006em-Ei; Mon, 19 Dec 2022 18:48:50 -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 1p7PsH-0006ee-6h for help-guix@gnu.org; Mon, 19 Dec 2022 18:48:49 -0500 Received: from mx2.dismail.de ([159.69.191.136]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p7PsE-0002hD-DY for help-guix@gnu.org; Mon, 19 Dec 2022 18:48:48 -0500 Received: from mx2.dismail.de (localhost [127.0.0.1]) by mx2.dismail.de (OpenSMTPD) with ESMTP id 28c05bfb; Tue, 20 Dec 2022 00:48:42 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=dismail.de; h= mime-version:date:content-type:content-transfer-encoding:from :message-id:subject:to:in-reply-to:references; s=20190914; bh=ID Q9E5SQH9nA9uFe+SC3o2en9qqTYW3tkiWpzHSqVyc=; b=fYTkZWO7469W+jr96u j/t776IKmybMBet1dWaCk7Oj3qv3WpUgzVNcgKb4n2jHnm23Fp9Noqv1bC23gCJA F6wb/l7HvbwvCu/P6e1Vnlwk+TPpMiD9ZY1YbL6hkl34L8wz40nrS21Y595ucNm9 xgttpFdjUKZxl7BY8RQuUvanCwF8DHRzmHvk8qawQY+JQMzSh4uocMOZNKw0hpxb AhlFVFJcdPMar1v8n/OiDM2Wdg9mhUyTfJkfNpdwmkc2KOtKKihBX0qKyIftzWaW WSBSt5jLZVUzvYLL0em7o3VK5LEpypMLMcai+UfgAmZqFt5xU/16LkEzIikZO15w VGeA== Received: from smtp1.dismail.de ( [10.240.26.11]) by mx2.dismail.de (OpenSMTPD) with ESMTP id b08e2657; Tue, 20 Dec 2022 00:48:42 +0100 (CET) Received: from smtp1.dismail.de (localhost [127.0.0.1]) by smtp1.dismail.de (OpenSMTPD) with ESMTP id 98d03cde; Tue, 20 Dec 2022 00:48:41 +0100 (CET) Received: by dismail.de (OpenSMTPD) with ESMTPSA id 08e30fbe (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Tue, 20 Dec 2022 00:48:41 +0100 (CET) MIME-Version: 1.0 Date: Mon, 19 Dec 2022 23:48:40 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Mailer: RainLoop/1.16.0a From: jbranso@dismail.de Message-ID: Subject: Re: Problems running Guix System initrd on an i.MX6 ARM board To: "Maxim Cournoyer" , "help-guix" In-Reply-To: <87pmco3r99.fsf@gmail.com> References: <87pmco3r99.fsf@gmail.com> Received-SPF: pass client-ip=159.69.191.136; envelope-from=jbranso@dismail.de; helo=mx2.dismail.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: help-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=dismail.de header.s=20190914 header.b=fYTkZWO7; dmarc=pass (policy=reject) header.from=dismail.de; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1671493762; a=rsa-sha256; cv=none; b=iL09LY1zrGl7iZr/FPw3kbqwXiCmz4eI+su5i5jbwCnSVdbF9tdTeeVVm7dxeVUf/I83sv BxUsNN6q8YBZTP3Ja9B1QQWQmgQy9e1wa7PPCO5uh6cm9WpquvQGZ6bbne0qXMXwhN+C9L YBVQ3SxUE7ltb3a8qWmTOmpQE3dcMnUZa79zLXwVPEjn7lVSAb0TfeJMans8kxT97JzpFl W9QILk5wXaLGdf1lAGhFKEIMOOo44Unqd7bEyXRrmeJAk2cQrlwEMFYscuQRn8v1nKZZzc WzhnU2E8Fa/88TDfMQecQ52W6bVf7HR28GpimCGelk4dJzxhUoKknsAJyr0ZSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1671493762; h=from:from:sender:sender: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:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=YNOLUOPGxqHBbWDo04fOthfCWmFb5pg9eNoOnmbyvFU=; b=K6SBsJLy14ujwZ6dvrnnklZqwaSHQSkRO4k2bSW9jYNeor9H9TUeWgXOMRMfUbvUFpxRlI biLu7Gf4rlZ8ZRtRPzIVtCIq1xTmLRrJU7V5RqkAWad2kCfD2gXgM2+tk0t5t+CdmBeCPj JTythqsra84/Mlh7peRMUQviQqG+iADefQHoG7bkJ5ODf2eLxcJA4LBVN+klfRNgJU6tQo pqxRanGu3edaffaKLLQ7mNz5HqUEmU/r2R6bTITvpTqPxwfaFILdpGScmDZ5dWtQZjDrtS J8S0tHmkc18FnYAOUnivzkRP/5UrxzQ/q+8vXirk3LFWmV30cK1Uv6HjHBGYRg== Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=dismail.de header.s=20190914 header.b=fYTkZWO7; dmarc=pass (policy=reject) header.from=dismail.de; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Scanner: scn1.migadu.com X-Migadu-Spam-Score: -7.44 X-Spam-Score: -7.44 X-Migadu-Queue-Id: 60AFB15153 X-TUID: ALxcyh6oZeT1 December 12, 2022 10:42 PM, "Maxim Cournoyer" = wrote: > Hi Guix! >=20 >=20I've been trying for some time to run Guix System on an ARM board (a > TS-7970 with an i.MX6 Cortex A9 CPU). I wanted to cross-compile the > image for speed and efficiency, and stumbled upon some problems on the > way, such as https://issues.guix.gnu.org/44924, fixed on core-updates. Please bear in mind that what you are trying is a little beyond my paygra= de. Is this a 32 bit or 64 bit processor? My gut feeling is that running gui= x system on a 32 bit arm board is going to be very painful. I think I recall chatting on guix-devel and someone saying that 1GB or 2G= B RAM memory is the absolute minimum. So you will run into low memory issu= es too. :( I personally have a pinephone, and I haven't tried running guix system on= it. I assume other non-free distros will work better. And I need the non-fre= e drivers for SMS and calling... :( >=20 >=20Then it took me some time to figure out that Guile 3.0.7 was segfault= ing > when running the initrd's init script, which would cause the following > kernel panic and backtrace: >=20 >=20--8<---------------cut here---------------start------------->8--- > [ 5.913371] ALSA device list: > [ 5.913374] #0: On-board Codec > [ 5.913376] #1: imx-hdmi-soc > [ 5.921483] sdhci-esdhc-imx 2190000.usdhc: card claims to support volta= ges below defined range > [ 5.938332] mmc0: new SDIO card at address 0001 > [ 5.987225] mmc2: new DDR MMC card at address 0001 > [ 5.998025] mmcblk2: mmc2:0001 MMC04G 3.60 GiB > [ 6.009623] mmcblk2boot0: mmc2:0001 MMC04G partition 1 16.0 MiB > [ 6.020181] mmcblk2boot1: mmc2:0001 MMC04G partition 2 16.0 MiB > [ 6.031772] mmcblk2rpmb: mmc2:0001 MMC04G partition 3 128 KiB > [ 6.957080] Freeing unused kernel memory: 1024K (80e00000 - 80f00000) > [ 6.967865] Kernel panic - not syncing: Attempted to kill init! exitcod= e=3D0x00008b00 > [ 6.967865] > [ 6.977015] CPU3: stopping > [ 6.979732] CPU: 3 PID: 0 Comm: swapper/3 Not tainted 4.9.11-tsimx #1 > [ 6.986174] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree) > [ 6.992704] Backtrace: > [ 6.995189] [<80111d48>] (dump_backtrace) from [<80111f38>] (show_stack= +0x18/0x1c) > [ 7.002765] r7:00000000 r6:20000193 r5:00000000 r4:80f2fecc > [ 7.008437] [<80111f20>] (show_stack) from [<8054d61c>] (dump_stack+0x8= 0/0x9c) > [ 7.015669] [<8054d59c>] (dump_stack) from [<8010d8dc>] (handle_IPI+0xe= 0/0x178) > [ 7.022981] r7:00000000 r6:d80b1f18 r5:00000003 r4:80e7f034 > [ 7.028648] [<8010d7fc>] (handle_IPI) from [<801014d8>] (gic_handle_irq= +0x70/0x78) > [ 7.036222] r7:f4a01100 r6:80f0358c r5:f4a00100 r4:d80b1f18 > [ 7.041895] [<80101468>] (gic_handle_irq) from [<80a0a34c>] (__irq_svc+= 0x6c/0xa8) > [ 7.049380] Exception stack(0xd80b1f18 to 0xd80b1f60) > [ 7.054434] 1f00: 00000000 00000001 > [ 7.062617] 1f20: 59eaf000 dad2fec0 9fdcb41d 9f4ecbfd dad2f1a8 00000000= 00000001 00000000 > [ 7.070800] 1f40: 00000001 d80b1f9c d80b1f68 d80b1f68 80826350 80826374= 60000113 ffffffff > [ 7.078981] r7:d80b1f4c r6:ffffffff r5:60000113 r4:80826374 > [ 7.084651] [<80826284>] (cpuidle_enter_state) from [<80826488>] (cpuid= le_enter+0x1c/0x20) > [ 7.092921] r10:d80b1fc0 r9:80e801a0 r8:80f030f4 r7:d80b0000 r6:0000000= 3 r5:80f08cd4 > [ 7.100752] r4:dad2f1a8 > [ 7.103301] [<8082646c>] (cpuidle_enter) from [<80165ccc>] (call_cpuidl= e+0x3c/0x40) > [ 7.110966] [<80165c90>] (call_cpuidle) from [<80165f48>] (cpu_startup_= entry+0x188/0x1a8) > [ 7.119149] [<80165dc0>] (cpu_startup_entry) from [<8010d5b8>] (seconda= ry_start_kernel+0x134/0x164) > [ 7.128196] r7:80f8d320 r4:80f14490 > [ 7.131779] [<8010d484>] (secondary_start_kernel) from [<1010156c>] (0x= 1010156c) > [ 7.139178] r7:80f8d320 r6:10c03c7d r5:00000051 r4:6809806a > [ 7.144839] CPU1: stopping > [ 7.147554] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 4.9.11-tsimx #1 > [ 7.153996] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree) > [ 7.160524] Backtrace: > [ 7.162999] [<80111d48>] (dump_backtrace) from [<80111f38>] (show_stack= +0x18/0x1c) > [ 7.170573] r7:00000000 r6:20000193 r5:00000000 r4:80f2fecc > [ 7.176242] [<80111f20>] (show_stack) from [<8054d61c>] (dump_stack+0x8= 0/0x9c) > [ 7.183471] [<8054d59c>] (dump_stack) from [<8010d8dc>] (handle_IPI+0xe= 0/0x178) > [ 7.190783] r7:00000000 r6:d80adf18 r5:00000001 r4:80e7f034 > [ 7.196449] [<8010d7fc>] (handle_IPI) from [<801014d8>] (gic_handle_irq= +0x70/0x78) > [ 7.204022] r7:f4a01100 r6:80f0358c r5:f4a00100 r4:d80adf18 > [ 7.209689] [<80101468>] (gic_handle_irq) from [<80a0a34c>] (__irq_svc+= 0x6c/0xa8) > [ 7.217173] Exception stack(0xd80adf18 to 0xd80adf60) > [ 7.222227] df00: 00000000 00000001 > [ 7.230410] df20: 59e93000 dad13ec0 9fdcb2cf 9f4ecbfd dad131a8 00000000= 00000001 00000000 > [ 7.238592] df40: 00000001 d80adf9c d80adf68 d80adf68 80826350 80826374= 60000013 ffffffff > [ 7.246773] r7:d80adf4c r6:ffffffff r5:60000013 r4:80826374 > [ 7.252439] [<80826284>] (cpuidle_enter_state) from [<80826488>] (cpuid= le_enter+0x1c/0x20) > [ 7.260709] r10:d80adfc0 r9:80e801a0 r8:80f030f4 r7:d80ac000 r6:0000000= 1 r5:80f08cd4 > [ 7.268539] r4:dad131a8 > [ 7.271082] [<8082646c>] (cpuidle_enter) from [<80165ccc>] (call_cpuidl= e+0x3c/0x40) > [ 7.278746] [<80165c90>] (call_cpuidle) from [<80165f48>] (cpu_startup_= entry+0x188/0x1a8) > [ 7.286931] [<80165dc0>] (cpu_startup_entry) from [<8010d5b8>] (seconda= ry_start_kernel+0x134/0x164) > [ 7.295979] r7:80f8d320 r4:80f14490 > [ 7.299560] [<8010d484>] (secondary_start_kernel) from [<1010156c>] (0x= 1010156c) > [ 7.306959] r7:80f8d320 r6:10c03c7d r5:00000051 r4:6809806a > [ 7.312621] CPU2: stopping > [ 7.315337] CPU: 2 PID: 0 Comm: swapper/2 Not tainted 4.9.11-tsimx #1 > [ 7.321779] Hardware name: Freescale i.MX6 Quad/DualLite (Device Tree) > [ 7.328306] Backtrace: > [ 7.330780] [<80111d48>] (dump_backtrace) from [<80111f38>] (show_stack= +0x18/0x1c) > [ 7.338355] r7:00000000 r6:20000193 r5:00000000 r4:80f2fecc > [ 7.344024] [<80111f20>] (show_stack) from [<8054d61c>] (dump_stack+0x8= 0/0x9c) > [ 7.351254] [<8054d59c>] (dump_stack) from [<8010d8dc>] (handle_IPI+0xe= 0/0x178) > [ 7.358567] r7:00000000 r6:d80aff18 r5:00000002 r4:80e7f034 > [ 7.364232] [<8010d7fc>] (handle_IPI) from [<801014d8>] (gic_handle_irq= +0x70/0x78) > [ 7.371806] r7:f4a01100 r6:80f0358c r5:f4a00100 r4:d80aff18 > [ 7.377472] [<80101468>] (gic_handle_irq) from [<80a0a34c>] (__irq_svc+= 0x6c/0xa8) > [ 7.384956] Exception stack(0xd80aff18 to 0xd80aff60) > [ 7.390010] ff00: 00000000 dad24bc0 > [ 7.398192] ff20: 00000001 d80ae000 9fdcb6b7 9fca06dd dad211a8 00000001= 00000001 00000004 > [ 7.406375] ff40: 00000001 d80aff9c d80aff28 d80aff68 8018eb00 80826374= 20000013 ffffffff > [ 7.414555] r7:d80aff4c r6:ffffffff r5:20000013 r4:80826374 > [ 7.420222] [<80826284>] (cpuidle_enter_state) from [<80826488>] (cpuid= le_enter+0x1c/0x20) > [ 7.428493] r10:d80affc0 r9:80e801a0 r8:80f030f4 r7:d80ae000 r6:0000000= 2 r5:80f08cd4 > [ 7.436323] r4:dad211a8 > [ 7.438866] [<8082646c>] (cpuidle_enter) from [<80165ccc>] (call_cpuidl= e+0x3c/0x40) > [ 7.446531] [<80165c90>] (call_cpuidle) from [<80165f48>] (cpu_startup_= entry+0x188/0x1a8) > [ 7.454714] [<80165dc0>] (cpu_startup_entry) from [<8010d5b8>] (seconda= ry_start_kernel+0x134/0x164) > [ 7.463761] r7:80f8d320 r4:80f14490 > [ 7.467342] [<8010d484>] (secondary_start_kernel) from [<1010156c>] (0x= 1010156c) > [ 7.474742] r7:80f8d320 r6:10c03c7d r5:00000051 r4:6809806a > [ 7.480414] ---[ end Kernel panic - not syncing: Attempted to kill init= ! exitcode=3D0x00008b00 > [ 7.480414] > --8<---------------cut here---------------end--------------->8--- >=20 >=20I found that guile would segfault and return an exit code of 139 > (perhaps ETXTBSY, per guile sources), by adding bash-static to the > initrd and invoking guile from there during the early boot. >=20 >=20Luckily, Guile 3.0.8 doesn't have this problem, so the following fixe= d > it: >=20 >=20--8<---------------cut here---------------start------------->8--- > modified gnu/packages/make-bootstrap.scm > @@ -797,7 +797,7 @@ (define %guile-static-stripped > ;; A stripped static Guile 3.0 binary, for use in initrds > ;; and during bootstrap.=0D > (make-guile-static-stripped > - (make-guile-static guile-3.0 > + (make-guile-static guile-3.0-latest > '("guile-2.2-default-utf8.patch" > "guile-3.0-linux-syscalls.patch" > "guile-3.0-relocatable.patch")))) > --8<---------------cut here---------------end--------------->8--- >=20 >=20The initrd now runs, but it fails with the following error: >=20 >=20--8<---------------cut here---------------start------------->8--- > [ 8.448448] ALSA device list: > [ 8.451472] #0: On-board Codec > [ 8.454768] #1: imx-hdmi-soc > [ 8.461095] Freeing unused kernel memory: 1024K (80e00000 - 80f00000) > GC Warning: pthread_getattr_np or pthread_attr_getstack failed for main= thread > GC Warning: Couldn't read /proc/stat > [ 8.481168] mmc0: new SDIO card at address 0001 > Welcome, this is GNU's early boot Guile. > Use 'gnu.repl' for an initrd REPL. >=20 >=20ice-9/boot-9.scm:1685:16: In procedure raise-exception: > Throw to key `record-abi-mismatch-error' with args `(abi-check "~a: rec= ord ABI mismatch; > recompilation needed" (#>) ())'. >=20 >=20Entering a new prompt. Type `,bt' for a backtrace or `,q' to continue= . > GNU Guile 3.0.8 > Copyright (C) 1995-2021 Free Software Foundation, Inc. >=20 >=20Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. > This program is free software, and you are welcome to redistribute it > under certain conditions; type `,show c' for details. >=20 >=20Enter `,help' for help. > scheme@(guile-user)> > --8<---------------cut here---------------end--------------->8--- >=20 >=20The .go modules appear to be correctly cross-compiled for > arm-linux-gnueabihf (they run fine on the same target using a different > OS that I can boot with). >=20 > Ideas? >=20 >=20--=20 >=20Thanks, > Maxim