README.altboot revision 1.7 1 /// notes about altboot ///
2
3 $NetBSD: README.altboot,v 1.7 2012/01/01 14:16:41 phx Exp $
4
5 Altboot is a functional bridge to fill the gap between a NAS product
6 custom bootloader and the NetBSD kernel startup environment. Altboot
7 irons out and rectifies erroneously configured HW by product
8 bootloaders and prepares a sane runtime, better suited for booting
9 NetBSD kernels.
10
11 - provides the foundation of a fast NetBSD porting cycle with functionalities
12 product bootloaders don't have.
13 - facilitates a flexible and clean NetBSD implementation tailoured
14 to target HW in detail, minimizing bumpy adjustments and hacks in
15 locore asm and machdeps in very early kernel startup stage.
16 - levels out differences among similar-but-not-the-same porting
17 targets to make it possible having common NetBSD kernels for them.
18 - builds and hands a bootinfo list to the NetBSD kernel.
19
20 Altboot is known working on at least these models:
21
22 - KuroBox or LinkStation with a popular U-Boot as replacement of
23 the vendor's proprietary one
24
25 U-Boot 1.1.4 LiSt 2.1.0 (Sep 21 2006 - 00:22:56) LinkStation / KuroBox
26
27 - Synology 101g+ with vendor custom PPCboot
28
29 PPCBoot 2.0.0 (Mar 1 2005 - 15:31:41)
30
31 - Synology 106j, 207, 407e with vendor custom PPCboot
32
33 PPCBoot 2.0.0 (Jan 30 2007 - xx:xx:xx)
34
35 - D-Link DSM-G600 with heavily restricted vendor custom U-Boot
36
37 U-Boot 0.2.0 (May 26 2005 - 19:38:32)
38
39 - QNAP TS-101 (V200) with vendor custom U-Boot
40
41 U-Boot 1.1.2 (Aug 28 2005 - 13:37:25) QNAP System, Inc.
42
43 - Iomega StorCenter with vendor custom U-Boot
44
45 U-Boot 1.0.0 (Sep 2 2005 - 14:49:11)
46
47 The standard use of altboot is to invoke it with a short script from
48 U-Boot/PPCboot, where the altboot.bin image is stored in an unoccupied 128KB
49 section of the target's HW NOR flash. Combined with standard
50 U-Boot/PPCboot functions, it is possible to boot a NetBSD kernel off
51 it right after power-on, without the help of manual intervention. Note
52 that the original U-Boot/PPCboot still remains useful and altboot works
53 as a functional extension for them.
54
55 In case the firmware was crippled by the vendor so that it only boots
56 Linux U-Boot images (D-Link), you can still use altboot by uploading
57 altboot.img instead of the Linux kernel.
58
59 Altboot passes the following bootinfo records to the NetBSD/sandpoint
60 kernel.
61 - processor clock tick value driving MPC8241/8245.
62 - serial console selection.
63 - booted kernel filename and which device it was fetched from.
64 - Ethernet MAC address, if target HW lacks SEEPROM to store a unit unique
65 value.
66 - product family indication.
67 - preloaded kernel module names (under development).
68
69 When no arguments are given, altboot defaults to boot a kernel called
70 "netbsd" from the root partition of the first disk in multiuser mode.
71
72 Boot arguments may be passed in three ways:
73 - On the command line, directly after the "go 0x1000000" command.
74 - From the U-Boot "bootargs" environment variable, when started by "bootm".
75 - By entering the interactive mode.
76
77 The following boot arguments are recognized:
78 - multi boot into multiuser
79 - auto boot into multiuser
80 - single boot into singleuser
81 - ask ask for boot device
82 - ddb drop into the kernel debugger
83 - userconf change configured devices
84
85 The following boot flags are recognized:
86 - norm boot normally
87 - quiet boot quietly
88 - verb boot verbosely
89 - silent boot silently
90 - debug boot with debug output
91
92 Additionally the special argument "altboot" is recognized, which replaces
93 the actually running altboot program with the loaded binary file and
94 restarts itself. Mainly useful for altboot testing.
95
96 Multiple arguments may be specified at once, although not all combinations
97 make sense. The format of an altboot command line is:
98
99 [[<bootargs> ...] <devicename>:[<bootfile>]]
100
101 The following device names are supported:
102 - tftp boot from TFTP (address retrieved by DHCP)
103 - nfs boot from NFS (address retrieved by DHCP)
104 - wd[N[P]] boot from disk N, partition P, defaults to wd0a
105 - mem boot from memory
106
107 For tftp and nfs the bootfile is determined by DHCP, when missing.
108 For wd it defaults to "netbsd".
109 For mem the bootfile is actually a hexadecimal address to load from and
110 is mandatory.
111
112 ### ### ###
113