A new minor release of ELKS, version 0.2.0, has been released. Source
code and pre-built generic disk images are available at:
https://github.com/jbruchon/elks/releases/tag/v0.2.0
Quick summary of changes and features:
- An easy build script (build.sh) was written to simplify builds for
people new to ELKS
- The general build process is now explained in a README file
- Disk images are now completely fixed and will now build properly
- Fix builds when host system is x86_64
- Tons of kernel fixes, some of which were major long-term problems
- Numerous errors, warnings, and compilation failures are now fixed
As always, please test things out and let me know if anything doesn't
work as expected.
***
Full changelog sine 0.1.5 follows.
commit 3c302cad12d34de58aba1b166da06c9173a43364
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sun Mar 1 14:46:23 2015 -0500
Release ELKS 0.2.0 with massive improvements
Many improvements in this commit:
- Add a script "build.sh" that makes building ELKS dead simple
- Add a script "elkscmd/image_stats.sh" to get detailed image file
statistics such as free space and inode counts
- Fix failure to build 360K floppy images due to insufficient
available inodes. mkfs.minix defaults to 128 inodes for a 360K
Minix filesystem, but the minimal root filesystem "min_rfs"
would populate the image with well over 128 inodes. A disk image
that has no free inodes is useless anyway, so the mkfs.minix
options were modified to make 360 inodes for all images. The
largest image available still has over 100 inodes available when
fully populated, so there is plenty of room for the future.
- Add a new disk image type called 'full1722'. This image is made
to fit on a 1.722MB formatted floppy disk. Most 1.44MB floppies
can be formatted to 1.722MB using the Linux 'fdformat' command
and special options. The only reason this has been added is to
increase the available disk space for capable systems.
- Improved disk image creation options. There are now four ways to
build all of the disk images and package them up:
make images - build all image types but don't make an archive
make images.zip - make images into a Zip archive
make images.tar.xz - make images into a Gzip-compressed tarball
make images.tar.xz - make images into a XZ-compressed tarball
(images.tar.xz compresses to about 1/7 the size of the others)
- Disk image builds will automatically link /bin/sh to either ash
(preferred) or sash, depending on what is available.
- All disk image build types were tested in QEMU to ensure they
boot correctly.
- Bump kernel version to 0.2.0 (yay!)
- Pre-built disk images for ELKS 0.2.0 will be made generally
available at: https://github.com/jbruchon/elks/releases
Special thanks to Juan Perez-Sanchez for all his recent ELKS
kernel patches!
commit dbffde5de94d40d1531f4b389a944db451146a3a
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sun Mar 1 14:27:46 2015 -0500
Update .gitignore to include some kernel build files
commit 71d9477adb6b693c8a61da540858e7000b0bfa60
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sun Mar 1 14:24:22 2015 -0500
rootfs_template: remove some unnecessary stuff, fix root shell
ELKS has two shells: ash and sash. The proper system shell should
be symlinked at /bin/sh and the default shell for root should be
set to this symlink. Some totally unnecessary bogus users exist in
the passwd/group files and just happened to make those files a bit
larger than a 1K disk block, so a few of these were removed to
lower the default size of these files and possibly save a tiny bit
of disk space.
commit c8f1a49c3167565ae813a93b3389406ec130c6fa
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sun Mar 1 11:16:41 2015 -0500
elksnet: allow parallel make
commit a5a7dee9ce8431073c5754c20714909714c85d5a
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sun Mar 1 11:12:12 2015 -0500
ash/mkinit.c: change from K&R C to ANSI C; fix compiler warnings
commit b472cc1f3364149ae1b0e78098d48cb4be18a67f
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Feb 28 15:00:37 2015 -0500
Add a README file with project information and build procedure
commit 0928f61e0d4b639b9982a3a626c4756c7b434c6f
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Feb 28 14:32:13 2015 -0500
Update .gitignore to not include 'dev86' directory
commit d0a74229dc58d1baddce87ec587ea5452f8dbf2a
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sat Feb 28 14:30:30 2015 -0500
Simplify file structure initialization
Functions sys_execve(), get_pipe_inode(), sys_open(), close_fp()
and get_fd() repeated a lot of code. Now most of the work is done in
the new functions open_filp() and close_filp().
The new kernel was tested under QEMU and a PentiumPro PC booting
from floppy.
There was a reduction of 176 bytes in code size.
commit 1f83c20dfb4341fa83907646daabcc44f9e533c9
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sat Feb 28 14:29:23 2015 -0500
Fix to exec syscall, improve find_buffer performance
In function sys_execve() in file fs/exec.c, if after opening an
executable file an error was found, closed the file and returned an
error
code, but the corresponding inode structure was not released. Now,
the inode is released on errors.
In file fs/buffer.c, function find_buffer() now looks for the
requested block in the direction most likely to find it faster.
Moved prototype for function get_unused_fd() from include/arch/system.h
to the more reasonable place in include/linuxmt/fs.h.
Code size was reduced by 16 bytes.
commit 9e99aad2123a868817697a312ea0af6c95f67f3a
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Mon Dec 8 08:24:41 2014 -0500
lxdialog: update headers and C flags for modern systems
The Makefile in scripts/lxdialog used -fomit-frame-pointer but
there is no reason to use it. Added flags for C99 and pedantic
warnings. Also added strings.h to dialog.h since some of the
string functions are supposed to use it. Without strings.h there
were many implicit function declaration warnings.
commit 70c62f6e3ba60e4f3a75bb661ea538f0d10a1436
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Mon Dec 8 08:00:04 2014 -0500
lxdialog: code cleanups
Fixed some lxdialog compiler warnings and removed an unused
variable. The unused "y" variable cannot be removed because
the ncurses standard interface getyx() requires it.
commit b0e951dd49187be0a51d75aea7076a03b6cb0541
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Mon Dec 8 07:37:52 2014 -0500
fdisk: create boot signature after partition table
Disk partitions created with ELKS fdisk are not recognized by the
ELKS kernel because they lack a signature. This patch fixes the
problem.
commit dac696b17cb75e6da6be6f581849424542883b8b
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Mon Dec 8 07:37:05 2014 -0500
Fix a bug when processing backspaces
Fixed a bug in ntty.c when processing backspaces.
Rewrited xt-key.c to reduce code size.
Clean code in some functions in fs directory.
Code size was reduced by 288 bytes and data size increased 84 bytes.
commit 62a1a88fc95481c9c2188abce3527200d14b7041
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Mon Dec 8 07:36:03 2014 -0500
Fix write to an array beyond its size
This patch fixes a bug in file fs/devices.c, function kdevname(),
where it overwrites the memory location following the end of static
array "buffer".
In file fs/minix/dir.c, function minix_dir_read(), changed its
declaration from using traditional C to ansi C.
Several improvements to code in fs and fs/minix directories
Code size was reduced by 176 bytes and data size reduced in 96 bytes.
commit 194c46b5c75bb189a4efd043c9adc8a5cb9bd217
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Mon Dec 8 07:35:19 2014 -0500
Fix for release of pipe buffers
After finishing using pipes, the allocated buffers should be
freed, but the required functions were missing. The pipe
syscall allocated a new buffer on each call, until available
buffers were exhausted. Then, it returned ENFILE (NOT -ENFILE),
crashing the system.
This patch provides the missing functions and returns the
right value when buffers are not available, besides other minor
improvements to code in the fs directory.
Code size was reduced by 48 bytes.
commit a72b23c9db65014b7089b09493a9b8dcdc64866f
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Thu Nov 27 11:53:27 2014 -0500
Simplify inode initialization
Initialization of inode structures was done in functions
get_empty_inode() and minix_new_inode(). But some
initializations were repeated at later stages.
The attached patch puts rationality to the initialization
of inode structures, placing initial values at the
earliest possible place and removing repeated initializations.
Also the simplification of several functions in the
fs/minix directory and prepare function get_pipe_inode()
for a future implementation of named pipes.
The new functions are simpler, easier to understand with
smaller code size.
Code size was reduced by 144 bytes.
commit dd97f4ac2e171953d3c26f941ff592d5fe941e81
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Thu Nov 27 11:51:28 2014 -0500
Fix symlinks, clean up inode functions
Symlinks can't be correctly created by ELKS. If a prebuilt filesystem
with symlinks is mounted under ELKS, it is recognized by command
ls, but programs cannot follow the link.
The attached patch fixes both problems. In addition, also fixes
the function strlen_fromfs(), which always returned zero.
I also took the opportunity to rewrite some functions in
fs/inode.c and fs/minix/inode.c to make them clearer and reduce
code size.
Code size was reduced by 128 bytes and data increased by 32 bytes.
commit 5bad583d4f9cfc8a5334ceffe6b697d3a693ec7f
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sun Nov 16 09:20:56 2014 -0500
Loop code cleanups, sys_execve() error handling bug fix
Transform "while" and "for" loops to "do {} while()" loops, when it
made cleaner code.
Cleaned handling of error in sys_execve().
Code size was reduces by 112 bytes.
commit e618adbf1df344fad65d7a05559ba23a250421f1
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sun Nov 16 09:19:31 2014 -0500
peek/poke fixups, unused variable cleanups
Some functions still used peek*/poke* to access userspace. Those
were replaced by architecture neutral get_user_*/put_user_*.
Unused functions peekd, pokeb, poked, get_bp, get_sp were removed.
Files for the first 3 functions remain in the source tree, together
with many other unused files. Unused variables "end" (in function
stack_check), "arch_segs", "marker" (in file sleepwake.c) and code
to initialize their never used contents was removed
Messages for printing startup errors were moved from init_task()
to a single print statement in function run_init_process().
Code size was reduced by 160 bytes and data reduced by 124 bytes.
commit efe4aa9037480c9fb670de84bc25b1f0bb9fd292
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sun Nov 16 09:18:22 2014 -0500
fork()/tswitch() bug fixes, task_struct init cleanup
System call fork() did not preserved user registers SI and DI
for the child task, and getting user register BP was unnecessa-
rily complex. The code was greatly simplified and assembly
function fake_save_regs() was completely removed.
Function tswitch() preserved registers BX and DX, but this is
not required by the calling conventions. The code was
simplified.
Initialization of struct task_struct was repeated at several
places in the source tree. Now, function find_empty_process()
does some initialization.
Code size was reduced by 128 bytes.
commit b012851309dc256ee4374b5c99a7e4220cebc9a9
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sun Nov 16 09:16:56 2014 -0500
File struct init unification, get_pipe_mem() improvements
Function get_empty_filp() now initializes some fields of file struct.
Previously, these initializations were repeated at several points in
the source tree: open.c, pipe.c, socket.c and exec.c.
Variable nr_files always equals NR_FILE. So, removed it and simplified
the code that uses it.
Function get_pipe_mem() uses a boolean array. Replaced it with a
bitmap.
Code size was reduced by 112 bytes and data reduced by 20 bytes.
commit 66b26efbc309c97619bf9cc6cd61620a57accd75
Author: Juan Perez-Sanchez <lithoxs@xxxxxxxxx>
Date: Sun Nov 16 09:12:28 2014 -0500
Task 0 cleanups, code size reduction
Claim 768 bytes memory used for the stack of task 0 during startup.
This task has 1 Kbytes reserved for stack in its task-struct, but
instead used a memory space reserved in file arch/i86/boot/ctr0.S.
Cleans a bit the mess of conditional compilation statements in
file arch/i86/boot/ctr0.S.
Removes unneeded function redirect_main() in file kernel/printk.c.
See comments in file arch/i86/boot/crt0.S.
Code size gets reduced by 64 bytes and data reduced by 768 bytes.
commit 68a726f1ab949dfa986b4a029074c86c0ad69f48
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 23:12:31 2014 -0400
Various build fixes
commit 637f687f3542f8280657ce86572dd7e280eb6afa
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 20:48:44 2014 -0400
elkscmd: Makefile fixes
commit b7af2e9f4df1d87750385e12b0c86ca7351ea29e
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 20:20:18 2014 -0400
Do not offer XMS support if CPU is not 80286 or higher
commit 3f584bc1856608d4fe2f8c4d24ef6f02d04dd291
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 19:59:05 2014 -0400
menuconfig: Fix hang when changing "int" values, add bounds check
commit 36f298516f1573c3d68d4d58fd0363b93045c737
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 18:45:18 2014 -0400
elkscmd: Easier dev86 path, add kernel check, add bootblock build rule
commit 824e1d4e53c5e6bfa9b93256c8bc6802ac46a505
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 18:30:59 2014 -0400
Minor improvements to "make clean"
commit 7507be9d0e1747b565791b18d61ab4f299bc9ef4
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 18:26:33 2014 -0400
Add compress.host to Makefiles for compressed target manpages
commit 3f4f84dc093540ffe97b5f161ef62805837ea6fb
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 18:16:14 2014 -0400
misc_utils: Make "compress" compile with GCC and add to Makefile
commit 9e125e94bbe1672bca3003f102c93d019a756522
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 00:24:08 2014 -0400
Fix more elkscmd compilation errors
commit 21196b2c737dc65bf14c9593f328f1bec0c7f38f
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 00:12:18 2014 -0400
Fix elksnet program suite compilation failures
commit 4ae48abe91fe3c399d5166ff4645000cb551b5f0
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Sat Apr 26 00:02:19 2014 -0400
Fix elkscmd inet program compilation failures
commit 2688a73b2bdb7a2f407f20290d8b96508dcf176f
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Fri Apr 25 18:19:40 2014 -0400
German to English change: mkurlader.c -> mkbootloader.c
commit b44030b35957c137659df4322dbd8cd36810b914
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Fri Apr 25 17:22:23 2014 -0400
Moved currently irrelevant documentation out of the way
commit e38ddc542db10c0c07d1264dae81972cd9cf48d7
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Fri Apr 25 15:37:05 2014 -0400
Fix building on 64-bit systems by using better types from stdint.h
commit 016d11fda5107814509c95c4a97214e5fa7adfd8
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Fri Apr 25 12:29:48 2014 -0400
Fix erroneous Makefile newlines
commit 7aa31c8a602e8b414150e8576d1b692abf369ba6
Author: Jody Bruchon <jody@xxxxxxxxxxx>
Date: Fri Apr 25 12:03:18 2014 -0400
Add .gitignore
commit e77732305254b19b8d5d5dfac51c8998c084d237
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 12:03:24 2013 -0400
fsck fix and general optimizations by Juan Perez-Sanchez:
Fixed a problem which produced a kernel message error when running
the command "fsck". Now that the implementation of read and write file
is cleaner, it was very easy to find and fix the problem in file
fs/block_dev.c.
General optimization in files arch/i86/drivers/block/doshd.c,
arch/i86/mm/init.c, arch/i86/mm/malloc.c, arch/i86/mm/user.c,
fs/buffer.c fs/minix/file.c, kernel/printk.c and kernel/sched.c,
removing unused variables and redundant statements, using pointers
instead of array indexing, using do{}while() whenever possible and
simplifying code.
3. As result of the modifications the code size was reduced in 112
bytes.
commit ea71dbdc894ba1ae03a44fde89412cdc18761d66
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 11:58:43 2013 -0400
Speed patch by Juan Perez-Sanchez:
Modified the implementation of functions find_first_non_zero_bit()
and find_first_zero_bit() in file arch/i86/lib/bitops.c to make them
faster. This came at the cost of an increase in code size. To
compensate for this, also optimized numerous functions in the
arch/i86/lib directory.
Code size increased by 32 bytes.
commit d7422cd0ab5495464511e5c0e368261572ecf2ad
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 11:54:06 2013 -0400
Driver and cleanup patch by Juan Perez-Sanchez:
In block driver doshd.c (the default driver), reading and writing
sectors is now done directly from/to block buffers. Previously the
sectors were copied to a buffer located at BUFSEG:0x0000 as an
intermediate and unnecessary step. These changes were tested copying a
lot of files running elks under qemu, checking the integrity of the
copied files and running fsck for the modified filesystem under linux.
Under the dioscuri emulator, with the ability to emulate the processor
speed, obtained a reduction of 15 sec. in running time when copying
the entire /bin directory from a total of 80 secs.
The modifications above, and other small changes to have a closer
implementation with "directhd.c" also reduced the code size.
Small changes in fs/exec.c and kernel/sys.c to remove unused
variables and redundant statements.
As result of the modifications the code size was reduced in 112 bytes.
commit ad990a059d496a0684e44e1ac02eb0e664bb7625
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 11:52:57 2013 -0400
Another FS patch from Juan Perez-Sanchez:
General optimization of fs/inode.c code. Changed the role of variable
"first_inode", changed the direction of walking through the inode list
depending in the intended operation, prefer the use of pointers over
array indexing, use do {}while() loops when possible (which bcc
"prefers"). The changes reduce both code size and processing time and
were tested copying a lot of files running elks under qemu, checking
the integrity of the copied files and running fsck for the modified
filesystem under linux.
A small optimization in file fs/minix/file.c, function
minix_file_read().
Code size reduced by 192 bytes.
commit 29dbcd46dda2d9650f431f18ce16a83baa8c290b
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 11:51:25 2013 -0400
FS patch by Juan Perez-Sanchez:
Modification of file read and write operations in fs/block_dev.c,
fs/minix/file.c and fs/pipe.c to have a closer implementation. Also,
fixed some minor problems in file.c (e.g. minix_file_read checks
*inode to be nonzero after actually dereferencing it).
The purpose of a closer implementation of these functions is to see
what are the important differences and provide insight on how to write
a unique generic implementation (as in mainstream linux).
The modified functions do the same things than the originals, only
the pointers and counters book keeping was greatly simplified. These
were tested copying a lot of files running elks under qemu, checking
the integrity of the copied files and running fsck for the modified
filesystem under linux.
As result of the modifications the code size was reduced in 352 bytes.
commit b5ae5d96196087be52ba2ea7fc30e81d13e33d35
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 11:47:30 2013 -0400
IRQ patch from Juan Perez-Sanchez:
A small modification to reduce interrupt latency time.
Code cleanup in file arch/i86/kernel/irqtab.c.
Code size reduced by 16 bytes.
commit da0faa30ad44bdad02064fbe863f324a95ae5d9b
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Mon Mar 18 11:46:02 2013 -0400
elkscmd patch my Juan Perez-Sanchez: "Fix to more pager"
commit 3ccc3cf4092c7241dd831d2c5e764d72eacbec9e
Author: Jody Bruchon <jody@xxxxxxxxxxxxxxx>
Date: Thu Dec 6 19:00:14 2012 -0500
Huge patch set from Juan Perez-Sanchez <lithoxs@xxxxxxxxx>:
[PATCH] Bug fixes to block drivers
[PATCH] standardization of get_user_* and put_user_* functions
[PATCH] Standardization of memcpy_form/tofs functions
[PATCH] Fix for bug in inode list
[PATCH] Improvements to block device code
[PATCH] Fixed bug when copying many files
--
To unsubscribe from this list: send the line "unsubscribe linux-8086" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html