summaryrefslogtreecommitdiff
path: root/gnu/system
diff options
context:
space:
mode:
authorDenis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>2025-12-22 20:04:36 +0100
committerVagrant Cascadian <vagrant@debian.org>2026-02-24 21:29:40 -0800
commit40269978c00faaa377c475635620742e3ab43276 (patch)
tree9331fd7a8d592da0a2bb7b8f568ae55c4238cdcf /gnu/system
parent99556e7724b3dd65e2be0dd06b7b69695c9c7901 (diff)
images: Add am335x-evm support.
* gnu/system/images/am335x-evm.scm: New file. * gnu/local.mk (GNU_SYSTEM_MODULES): Add it. Change-Id: Ic3695d9d26a4870500a9bf1b2a3d53d93fed6db6 Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> Signed-off-by: Vagrant Cascadian <vagrant@debian.org>
Diffstat (limited to 'gnu/system')
-rw-r--r--gnu/system/images/am335x-evm.scm84
1 files changed, 84 insertions, 0 deletions
diff --git a/gnu/system/images/am335x-evm.scm b/gnu/system/images/am335x-evm.scm
new file mode 100644
index 00000000000..06e26e390c5
--- /dev/null
+++ b/gnu/system/images/am335x-evm.scm
@@ -0,0 +1,84 @@
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2021 Marius Bakke <marius@gnu.org>
3;;; Copyright © 2025 Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
4;;;
5;;; This file is part of GNU Guix.
6;;;
7;;; GNU Guix is free software; you can redistribute it and/or modify it
8;;; under the terms of the GNU General Public License as published by
9;;; the Free Software Foundation; either version 3 of the License, or (at
10;;; your option) any later version.
11;;;
12;;; GNU Guix is distributed in the hope that it will be useful, but
13;;; WITHOUT ANY WARRANTY; without even the implied warranty of
14;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15;;; GNU General Public License for more details.
16;;;
17;;; You should have received a copy of the GNU General Public License
18;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
19
20(define-module (gnu system images am335x-evm)
21 #:use-module (gnu bootloader u-boot)
22 #:use-module (gnu bootloader)
23 #:use-module (gnu image)
24 #:use-module (gnu packages bootloaders)
25 #:use-module (gnu packages linux)
26 #:use-module (gnu services base)
27 #:use-module (gnu services networking)
28 #:use-module (gnu services)
29 #:use-module (gnu system file-systems)
30 #:use-module (gnu system image)
31 #:use-module (gnu system)
32 #:use-module (guix platforms arm)
33 #:use-module (srfi srfi-26)
34 #:export (am335x-evm-barebones-os
35 am335x-evm-image-type
36 am335x-evm-barebones-raw-image))
37
38;; See the comment in u-boot-am335x-evm-bootloader to know which computers are
39;; supported by this image.
40(define am335x-evm-barebones-os
41 (operating-system
42 (host-name "guadalajara")
43 (timezone "Europe/Madrid")
44 (locale "en_US.utf8")
45 (bootloader (bootloader-configuration
46 (bootloader u-boot-am335x-evm-bootloader)
47 (targets '("/dev/sda"))))
48 (initrd-modules '())
49 (kernel linux-libre-arm-generic)
50 (file-systems (cons (file-system
51 (device (file-system-label "my-root"))
52 (mount-point "/")
53 (type "ext4"))
54 %base-file-systems))
55 (services (append (list
56 (service
57 agetty-service-type
58 (agetty-configuration
59 (extra-options '("-L")) ;no carrier detect
60 (baud-rate "115200")
61 (term "vt100")
62 (tty "ttyS0")))
63 (service dhcpcd-service-type))
64 %base-services))))
65
66(define am335x-evm-image-type
67 (image-type
68 (name 'am335x-evm-raw)
69 (constructor (lambda (os)
70 (image
71 ;; Reserve 4 MiB for the partition table and the
72 ;; bootloader.
73 (inherit (raw-with-offset-disk-image (expt 2 22)))
74 (operating-system os)
75 (platform armv7-linux))))))
76
77(define am335x-evm-barebones-raw-image
78 (image
79 (inherit
80 (os+platform->image am335x-evm-barebones-os armv7-linux
81 #:type am335x-evm-image-type))
82 (name 'am335x-evm-barebones-raw-image)))
83
84am335x-evm-barebones-raw-image