summaryrefslogtreecommitdiff
path: root/gnu/bootloader
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/bootloader')
-rw-r--r--gnu/bootloader/u-boot.scm69
1 files changed, 35 insertions, 34 deletions
diff --git a/gnu/bootloader/u-boot.scm b/gnu/bootloader/u-boot.scm
index 1da9d04eb25..c57d4964c85 100644
--- a/gnu/bootloader/u-boot.scm
+++ b/gnu/bootloader/u-boot.scm
@@ -45,7 +45,7 @@
45 u-boot-wandboard-bootloader)) 45 u-boot-wandboard-bootloader))
46 46
47(define install-u-boot 47(define install-u-boot
48 #~(lambda (bootloader device mount-point) 48 #~(lambda (bootloader root-index image)
49 (if bootloader 49 (if bootloader
50 (error "Failed to install U-Boot")))) 50 (error "Failed to install U-Boot"))))
51 51
@@ -56,74 +56,74 @@
56 ;; the MLO and is expected at 0x60000. Write both first stage ("MLO") and 56 ;; the MLO and is expected at 0x60000. Write both first stage ("MLO") and
57 ;; second stage ("u-boot.img") images, read in BOOTLOADER directory, to the 57 ;; second stage ("u-boot.img") images, read in BOOTLOADER directory, to the
58 ;; specified DEVICE. 58 ;; specified DEVICE.
59 #~(lambda (bootloader device mount-point) 59 #~(lambda (bootloader root-index image)
60 (let ((mlo (string-append bootloader "/libexec/MLO")) 60 (let ((mlo (string-append bootloader "/libexec/MLO"))
61 (u-boot (string-append bootloader "/libexec/u-boot.img"))) 61 (u-boot (string-append bootloader "/libexec/u-boot.img")))
62 (write-file-on-device mlo (* 256 512) 62 (write-file-on-device mlo (* 256 512)
63 device (* 256 512)) 63 image (* 256 512))
64 (write-file-on-device u-boot (* 1024 512) 64 (write-file-on-device u-boot (* 1024 512)
65 device (* 768 512))))) 65 image (* 768 512)))))
66 66
67(define install-allwinner-u-boot 67(define install-allwinner-u-boot
68 #~(lambda (bootloader device mount-point) 68 #~(lambda (bootloader root-index image)
69 (let ((u-boot (string-append bootloader 69 (let ((u-boot (string-append bootloader
70 "/libexec/u-boot-sunxi-with-spl.bin"))) 70 "/libexec/u-boot-sunxi-with-spl.bin")))
71 (write-file-on-device u-boot (stat:size (stat u-boot)) 71 (write-file-on-device u-boot (stat:size (stat u-boot))
72 device (* 8 1024))))) 72 image (* 8 1024)))))
73 73
74(define install-allwinner64-u-boot 74(define install-allwinner64-u-boot
75 #~(lambda (bootloader device mount-point) 75 #~(lambda (bootloader root-index image)
76 (let ((spl (string-append bootloader "/libexec/spl/sunxi-spl.bin")) 76 (let ((spl (string-append bootloader "/libexec/spl/sunxi-spl.bin"))
77 (u-boot (string-append bootloader "/libexec/u-boot.itb"))) 77 (u-boot (string-append bootloader "/libexec/u-boot.itb")))
78 (write-file-on-device spl (stat:size (stat spl)) 78 (write-file-on-device spl (stat:size (stat spl))
79 device (* 8 1024)) 79 image (* 8 1024))
80 (write-file-on-device u-boot (stat:size (stat u-boot)) 80 (write-file-on-device u-boot (stat:size (stat u-boot))
81 device (* 40 1024))))) 81 image (* 40 1024)))))
82 82
83(define install-imx-u-boot 83(define install-imx-u-boot
84 #~(lambda (bootloader device mount-point) 84 #~(lambda (bootloader root-index image)
85 (let ((spl (string-append bootloader "/libexec/SPL")) 85 (let ((spl (string-append bootloader "/libexec/SPL"))
86 (u-boot (string-append bootloader "/libexec/u-boot.img"))) 86 (u-boot (string-append bootloader "/libexec/u-boot.img")))
87 (write-file-on-device spl (stat:size (stat spl)) 87 (write-file-on-device spl (stat:size (stat spl))
88 device (* 1 1024)) 88 image (* 1 1024))
89 (write-file-on-device u-boot (stat:size (stat u-boot)) 89 (write-file-on-device u-boot (stat:size (stat u-boot))
90 device (* 69 1024))))) 90 image (* 69 1024)))))
91 91
92(define install-puma-rk3399-u-boot 92(define install-puma-rk3399-u-boot
93 #~(lambda (bootloader device mount-point) 93 #~(lambda (bootloader root-index image)
94 (let ((spl (string-append bootloader "/libexec/u-boot-spl.rksd")) 94 (let ((spl (string-append bootloader "/libexec/u-boot-spl.rksd"))
95 (u-boot (string-append bootloader "/libexec/u-boot.itb"))) 95 (u-boot (string-append bootloader "/libexec/u-boot.itb")))
96 (write-file-on-device spl (stat:size (stat spl)) 96 (write-file-on-device spl (stat:size (stat spl))
97 device (* 64 512)) 97 image (* 64 512))
98 (write-file-on-device u-boot (stat:size (stat u-boot)) 98 (write-file-on-device u-boot (stat:size (stat u-boot))
99 device (* 512 512))))) 99 image (* 512 512)))))
100 100
101(define install-firefly-rk3399-u-boot 101(define install-firefly-rk3399-u-boot
102 #~(lambda (bootloader device mount-point) 102 #~(lambda (bootloader root-index image)
103 (let ((idb (string-append bootloader "/libexec/idbloader.img")) 103 (let ((idb (string-append bootloader "/libexec/idbloader.img"))
104 (u-boot (string-append bootloader "/libexec/u-boot.itb"))) 104 (u-boot (string-append bootloader "/libexec/u-boot.itb")))
105 (write-file-on-device idb (stat:size (stat idb)) 105 (write-file-on-device idb (stat:size (stat idb))
106 device (* 64 512)) 106 image (* 64 512))
107 (write-file-on-device u-boot (stat:size (stat u-boot)) 107 (write-file-on-device u-boot (stat:size (stat u-boot))
108 device (* 16384 512))))) 108 image (* 16384 512)))))
109 109
110(define install-rock64-rk3328-u-boot 110(define install-rock64-rk3328-u-boot
111 #~(lambda (bootloader device mount-point) 111 #~(lambda (bootloader root-index image)
112 (let ((idb (string-append bootloader "/libexec/idbloader.img")) 112 (let ((idb (string-append bootloader "/libexec/idbloader.img"))
113 (u-boot (string-append bootloader "/libexec/u-boot.itb"))) 113 (u-boot (string-append bootloader "/libexec/u-boot.itb")))
114 (write-file-on-device idb (stat:size (stat idb)) 114 (write-file-on-device idb (stat:size (stat idb))
115 device (* 64 512)) 115 image (* 64 512))
116 (write-file-on-device u-boot (stat:size (stat u-boot)) 116 (write-file-on-device u-boot (stat:size (stat u-boot))
117 device (* 16384 512))))) 117 image (* 16384 512)))))
118 118
119(define install-rockpro64-rk3399-u-boot 119(define install-rockpro64-rk3399-u-boot
120 #~(lambda (bootloader device mount-point) 120 #~(lambda (bootloader root-index image)
121 (let ((idb (string-append bootloader "/libexec/idbloader.img")) 121 (let ((idb (string-append bootloader "/libexec/idbloader.img"))
122 (u-boot (string-append bootloader "/libexec/u-boot.itb"))) 122 (u-boot (string-append bootloader "/libexec/u-boot.itb")))
123 (write-file-on-device idb (stat:size (stat idb)) 123 (write-file-on-device idb (stat:size (stat idb))
124 device (* 64 512)) 124 image (* 64 512))
125 (write-file-on-device u-boot (stat:size (stat u-boot)) 125 (write-file-on-device u-boot (stat:size (stat u-boot))
126 device (* 16384 512))))) 126 image (* 16384 512)))))
127 127
128(define install-pinebook-pro-rk3399-u-boot install-rockpro64-rk3399-u-boot) 128(define install-pinebook-pro-rk3399-u-boot install-rockpro64-rk3399-u-boot)
129 129
@@ -138,28 +138,29 @@
138 (inherit extlinux-bootloader) 138 (inherit extlinux-bootloader)
139 (name 'u-boot) 139 (name 'u-boot)
140 (package #f) 140 (package #f)
141 (installer install-u-boot))) 141 (installer #f)
142 (disk-image-installer install-u-boot)))
142 143
143(define u-boot-beaglebone-black-bootloader 144(define u-boot-beaglebone-black-bootloader
144 (bootloader 145 (bootloader
145 (inherit u-boot-bootloader) 146 (inherit u-boot-bootloader)
146 (package u-boot-am335x-boneblack) 147 (package u-boot-am335x-boneblack)
147 (installer install-beaglebone-black-u-boot))) 148 (disk-image-installer install-beaglebone-black-u-boot)))
148 149
149(define u-boot-allwinner-bootloader 150(define u-boot-allwinner-bootloader
150 (bootloader 151 (bootloader
151 (inherit u-boot-bootloader) 152 (inherit u-boot-bootloader)
152 (installer install-allwinner-u-boot))) 153 (disk-image-installer install-allwinner-u-boot)))
153 154
154(define u-boot-allwinner64-bootloader 155(define u-boot-allwinner64-bootloader
155 (bootloader 156 (bootloader
156 (inherit u-boot-bootloader) 157 (inherit u-boot-bootloader)
157 (installer install-allwinner64-u-boot))) 158 (disk-image-installer install-allwinner64-u-boot)))
158 159
159(define u-boot-imx-bootloader 160(define u-boot-imx-bootloader
160 (bootloader 161 (bootloader
161 (inherit u-boot-bootloader) 162 (inherit u-boot-bootloader)
162 (installer install-imx-u-boot))) 163 (disk-image-installer install-imx-u-boot)))
163 164
164(define u-boot-nintendo-nes-classic-edition-bootloader 165(define u-boot-nintendo-nes-classic-edition-bootloader
165 (bootloader 166 (bootloader
@@ -196,7 +197,7 @@
196 (bootloader 197 (bootloader
197 (inherit u-boot-bootloader) 198 (inherit u-boot-bootloader)
198 (package u-boot-firefly-rk3399) 199 (package u-boot-firefly-rk3399)
199 (installer install-firefly-rk3399-u-boot))) 200 (disk-image-installer install-firefly-rk3399-u-boot)))
200 201
201(define u-boot-mx6cuboxi-bootloader 202(define u-boot-mx6cuboxi-bootloader
202 (bootloader 203 (bootloader
@@ -232,25 +233,25 @@
232 (bootloader 233 (bootloader
233 (inherit u-boot-bootloader) 234 (inherit u-boot-bootloader)
234 (package u-boot-puma-rk3399) 235 (package u-boot-puma-rk3399)
235 (installer install-puma-rk3399-u-boot))) 236 (disk-image-installer install-puma-rk3399-u-boot)))
236 237
237(define u-boot-rock64-rk3328-bootloader 238(define u-boot-rock64-rk3328-bootloader
238 ;; SD and eMMC use the same format 239 ;; SD and eMMC use the same format
239 (bootloader 240 (bootloader
240 (inherit u-boot-bootloader) 241 (inherit u-boot-bootloader)
241 (package u-boot-rock64-rk3328) 242 (package u-boot-rock64-rk3328)
242 (installer install-rock64-rk3328-u-boot))) 243 (disk-image-installer install-rock64-rk3328-u-boot)))
243 244
244(define u-boot-rockpro64-rk3399-bootloader 245(define u-boot-rockpro64-rk3399-bootloader
245 ;; SD and eMMC use the same format 246 ;; SD and eMMC use the same format
246 (bootloader 247 (bootloader
247 (inherit u-boot-bootloader) 248 (inherit u-boot-bootloader)
248 (package u-boot-rockpro64-rk3399) 249 (package u-boot-rockpro64-rk3399)
249 (installer install-rockpro64-rk3399-u-boot))) 250 (disk-image-installer install-rockpro64-rk3399-u-boot)))
250 251
251(define u-boot-pinebook-pro-rk3399-bootloader 252(define u-boot-pinebook-pro-rk3399-bootloader
252 ;; SD and eMMC use the same format 253 ;; SD and eMMC use the same format
253 (bootloader 254 (bootloader
254 (inherit u-boot-bootloader) 255 (inherit u-boot-bootloader)
255 (package u-boot-pinebook-pro-rk3399) 256 (package u-boot-pinebook-pro-rk3399)
256 (installer install-pinebook-pro-rk3399-u-boot))) 257 (disk-image-installer install-pinebook-pro-rk3399-u-boot)))