-
Notifications
You must be signed in to change notification settings - Fork 1
/
ChangeLog
343 lines (220 loc) · 11.7 KB
/
ChangeLog
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
Version 2.3:
Fixed crashing caused by calling vfs_translate_path() with no disk set
or passing too few arguments to 'find' command.
Updated filename autocompletion: partial names are appended where
possible and complete ones are displayed.
Added boot_index and boot_target command line options.
Added GRUB 2 configuration support.
Updated to kexec-tools 2.0.2.
Version 2.2.2:
Added chroot jail support to the VFS layer and a rootdir kernel argument
to override the root directory path on the boot disk.
Added stack trace with symbol lookup and register dump upon segfault to
make debugging crashes less insanity-inducing.
Added GRUB autodetection support.
Version 2.2.1:
Lots of code cleanup.
Updated list_add() to set the 'next' pointer of the new node to NULL as
not setting it to NULL could cause segfaults.
Moved disk comparison code from find_disk() to compare_disk_id().
Wrote mount_by_id() function to replace mount_retry() and direct
mount_disk() calls.
Added filter argument to get_disks() and removed find_disk().
Changed boot messages to be less verbose, verbose information is still
sent to debug console if needed.
Set VFS root to "rootfs" instead of "debug" it /noboot exists.
Rewrote tarmods.pl script.
Updated makefile to explicitly set --build to the result of config.guess
if a cross compiler is used.
Updated to kexec-tools 2.0.1.
Added message to warn when no targets are defined.
Updated PATH_COMMAND() macro to allow unsetting paths.
Version 2.2:
Added 'floppy' target to automatically build floppy images.
Updated mkinitramfs.sh to create an LZMA compressed archive.
Cleaned up mkinitramfs.sh.
Wrote improved VFS wrapper functions, removed some old ones.
Added kexec-loader specific errno values for the new VFS layer.
Added 'debug' disk for... debugging.
Updated get_cmdline() to return values in a static buffer instead of
returning a string on the heap.
Updated modprobe code to mmap() module files instead of reading them
into memory, gzipped modules are no longer supported.
Added gzip support to TAR extractor to replace gzipped modules.
Updated addmod.sh to accept multiple modules.
Wrote script and make targets for generating ISO images.
Rewrote and changed large portions of the GRUB intergration code to fix
bugs and improve readability.
Version 2.1.1:
Updated config loading code to look for kxloader.cfg if there is no
kexec-loader.conf file.
Changed behaviour of timeout directive: 0 timeout will boot instantly
instead of waiting forever, use "off" to force no timeout. The default
setting is "off", but will be overridden by menu.lst unless explicitly
set in kexec-loader.conf.
Fixed bug: Module loading failed due to my lack of testing.
Changed ls command to not output timestamps or list ./.. directories.
Fixed bug: Append option ignored and cmdline used in its place.
Fixed bug: Error from kexec-tools dying not visible when booting menu
target as alert was not set on failure.
Added support for modules packed in TAR archives, optionally compressed
with LZMA using the .tlz extension.
Version 2.1:
Fixed a bug: grub-map caused an "Unknown directive" error.
Added support for loading keymaps.
Updated module loading code: kernel modules in /modules/ on the rootfs
will be loaded before trying to mount the boot disk.
Fixed bug: forgot to pass --reset-vga to kexec
Added contextual shell autocompletion, only returns results appropriate
for the current command.
Fixed bug: skipped "chainload" GRUB targets instead of "chainloader"
Updated menu.lst parser to skip entries with empty root devices, since
some distros use this (broken?) behaviour for divider lines.
Added check for /noboot file on rootfs to load everything from rootfs
instead of searching for a boot disk.
Implemented console_getchar() wrapper to handle terminal escapes in one
place and to allow characters to be queued from processing escapes.
Version 2.0:
Full rewrite, far more stable code.
Version 1.6.2:
Fixed a bug: specifying filesystem type AND /dev/ for a non-existant
device no longer attempts to free an invalid address.
Rewrote the shell input code, autocompletion will be re-implemented in a
later version, after some design choices are finalized.
Updated the shell to accept arguments containing spaces without them
being quoted or escaped for the kernel, initrd, cmdline and append
commands.
Updated detect_fstype() and check_magic() to correctly identify ext4
filesystems instead of identifying them as ext3.
Version 1.6.1:
Fixed a bug: config_parse() silently ignored initrd due to a typo.
Added reboot, halt and cat commands to shell.
Implemented autocompletion for commands and filenames in the shell.
Fixed a bug: pressing a key to stop searching for boot disk no longer
results in an infinite loop.
Changed behaviour of kexec_config kernel option, it now forces the boot
device instead of just adding it to the top of the search list.
Version 1.6:
Replaced unsafe mmap() code in detect_fstype() which crashed on small
partitions, such as MS-DOS extended.
Upgraded kexec-tools to version 2.0.0
Fixed a bug: console_getsize() returned 0x0 on serial consoles, it now
defaults to 80x24 if the ioctl() call returns 0x0.
Rewrote shell input code to support decent line editing.
Updated shell history code to not log empty lines, or repeat commands.
Rewrote command parsing code to be more like that of a normal shell,
the new parser stores arguments in argv[] and sets argc.
Added basic shell commands (cd, ls, find, etc...)
Changed module loading behaviour: All files in /modules/ named *.ko are
loaded automatically, options may be set in /modules/modules.conf
Version 1.5:
Rewrote code which finds the boot disk.
Removed capability to reload configuration by pressing R at the main
menu.
Added support for loading Linux modules and inserting them into the
kernel, gzip compressed modules are also supported.
Fixed a bug: nptr->mpoint was not set to the return value of
str_append() in config_add_mount(), which could cause a segfault
depending on state of OS memory management code.
Updated styling of status messages to make them more consistant.
Rewrote detect_fstype() to use mmap() instead of reading MAGIC_BUF_SIZE
bytes of into stack memory.
Updated mount code to create device nodes from /proc/diskstats and
removed hdx/sdx mknod code from mkinitramfs.sh
Version 1.4.3:
Fixed bug caused by my stupidity and lack of testing:
grub_loadcfg() incorrectly checked that grub_root was set, why
does this seem so familiar? Oh yeah! Version 1.3.1!
Version 1.4.2:
Replaced malloc() calls with allocate() calls for simplicity.
Replaced most fixed-length strings with dynamic strings in order to
save memory.
Replaced kl_target.modules array with a linked-list to remove the limit
on multiboot modules.
Added multiboot module support for GRUB configuration files.
Version 1.4.1:
Added support for ISO-9660 to detect_fstype().
Added command history, scrolls through previous commands on up/down
arrow keys, by default the history size is 32 commands.
Added nano-like scrolling for editing commands which are longer then
the screen, otherwise backspacing before column 1 deletes characters
from the command buffer, but not from the screen.
Added module command and configuration directive to support loading
multiboot modules.
Version 1.4:
Added cmdline configuration directive.
Updated load_kernel() to take a kl_target as its argument and store the
argument strings in dynamic memory.
Removed STACK_BUF macro and replaced it with fixed buffers of smaller
sizes since 2048 is overkill for any of them.
Fixed a bug: unmount_list() now returns if mounts = NULL instead of
getting stuck in an infinite loop.
Wrote shell for interactively configuring and booting targets, will be
improved a lot over the next versions.
Added reset-vga directive/command which passes kexec the --reset-vga
argument when loading the kernel.
Updated the kexec-tools merge patch to make die() output error messages
in the same style as kexec-loader.
Implemented free_targets(), fixed a memory leak in config_load() and
used value2 in config_parse() to get rid of a warning.
Version 1.3.1:
Updated makefile structure and added new targets.
Updated run_kexec() to directly call kexec_main() in the child process
instead of calling itself with argv[0]="kexec" via execv().
Fixed bug: grub_loadcfg() now checks that grub_root is set before
attempting to mount it, how the hell did I overlook this?!
Fixed bug: load_menu() now correctly handles the 'default' directive
in menu.lst.
Version 1.3:
Created mount_dev() function to cut down on duplicate mounting code.
Added support for reading GRUB menu.lst and device.map files.
Version 1.2:
Rewrote fatal() function and removed pointless calls to it.
Fixed bug: main_menu() no longer crashes if you have zero targets.
Fixed bug: Timeout is no longer displayed after a one second delay.
Rewrote a lot of code used for loading configuration.
Removed obsolete mount_add(), mount_copy(), mount_free(), target_add()
and target_free() functions.
Added STACK_LIMIT and STACK_BUF macros which configure the maximum
stack size and the size of auto buffers.
Wrote check_device() function for checking that devices exist before
attempting to mount, determine FS type, etc.
Updated config_add_mount() to prepend /mnt/ to kl_mount.mpoint so that
an extra buffer isn't required in mount_list() or unmount_list().
Updated config_mount() to retry finding the configuration disk upto 3
times upon failure with delay increasing with each attempt.
Optimised some of the screen drawing code to not write pointless
characters to the console.
Implemented new console output API: printm(), printM(), printd() and
printD() which are macro wrappers around print2().
Improved status messages displayed while loading a target.
Updated list_devices() to display the filesystem type of all devices
found in /proc/diskstats.
Updated build system to download and patch kexec-tools then build the
kexec program into kexec-loader like busybox to save space.
Removed HOST and CC variables from root Makefile and added ifdef to set
the CC and configure options as required if a HOST variable is passed
in the environment.
Updated mount_config() to check for the kernel option kexec_config and
insert the supplied device at the start of the devices list.
Updated mount_config() to detect the filesystem type using
detect_fstype() instead of using the hardcoded BOOTFS_TYPE macro.
Version 1.1:
Removed directives for creating devices, all devices inodes should be
included with the initramfs.
Redesigned mkinitramfs.sh to create a CPIO archive and to use fakeroot
if the script is not being run as root.
Updated configuration file parser.
Added seperate debug console and /proc/kmsg monitor.
Rewrote code which deals with mounting/unmounting the disk containing
CONFIG_FILE.
Rewrote mount_list() to be more effecient by ordering the mounts in
order of depth.
Replaced unmount_tree() function with unmount_list().
Added support for detecting ext2, ext3, XFS, ReiserFS, minix, FAT and
NTFS filesystem types.
Rewrote menu code, it's slightly more sane now.
Implemented list_devices() function, pressing L at the menu displays
a list of all devices listed in /proc/diskstats.
Version 1.0:
Initial release.