mirror of https://github.com/FDOS/kernel.git
95 lines
3.3 KiB
Plaintext
95 lines
3.3 KiB
Plaintext
FreeDOS kernel with memdisk support compiled in:
|
|
|
|
When enabled one can supplement (or replace) CONFIG.SYS from the memdisk
|
|
command line. The kernel upon booting will verify running on a 386+ and
|
|
then check for memdisk using int 13h call with magic values. If found
|
|
then the memdisk command line is processed and simulated CONFIG.SYS lines
|
|
are evaluated left to right as though they logically followed the last
|
|
line in CONFIG.SYS (or FDCONFIG.SYS).
|
|
|
|
Example syslinux.cfg section:
|
|
LABEL FreeDOS
|
|
KERNEL memdisk
|
|
MENU LABEL FreeDOS example
|
|
INITRD FDSTD.img
|
|
APPEND {ECHO Booting FreeDOS}{ECHO This is the second line.}
|
|
|
|
|
|
FreeDOS config lines are denoted by surrounding the line in curly braces {}
|
|
thus allowing multiple simulated lines on a single APPEND line. However,
|
|
the closing brace } may be omitted if it would be immediately followed by
|
|
an opening brace { or end of the APPEND line. Anything on the memdisk line
|
|
outside of the curly braces {} is ignored. The lines may be preceeded by
|
|
FD= to be compatible with earlier FD kernel release or any other key= to
|
|
specify the environment variable generated by getargs utility. All simulated
|
|
config lines (text between the { and }) are evaluated by the kernel asis
|
|
except the final line (the line within final {}).
|
|
|
|
The final } is optional which results in the memdisk options initrd= and
|
|
BOOT_IMAGE= to appear as part of the config.sys line. To avoid issues
|
|
several memdisk options are ignored if after the last opening brace {.
|
|
Note that the syslinux/memdisk options are case sensitive. Currently
|
|
ignored options are: initrd, BOOT_IMAGE, floppy, harddisk, and iso.
|
|
|
|
Additionally, to simplify passing and overriding arguments when syslinux
|
|
is booting, any key=value pairs seen after any memdisk options will cause
|
|
all corresponding key=??? prior to any memdisk options to be cleared on
|
|
the resulting config line.
|
|
For example if the final assembled memdisk line appears to the kernel as:
|
|
{ECHO HI{ECHO X=1 X=2 Y=1 Z=1 initrd=FDSTD10.img BOOT_IMAGE=memdisk X=386
|
|
then the following two lines will evaluated by the kernel after processing
|
|
any CONFIG.SYS lines.
|
|
ECHO HI
|
|
ECHO Y=1 Z=1 X=386
|
|
|
|
The following APPEND lines are all treated identically by the kernel.
|
|
APPEND floppy FD={ECHO Welcome}{ECHO 2nd line}{ECHO third}
|
|
APPEND floppy FD={ECHO Welcome{ECHO 2nd line{ECHO third
|
|
APPEND {ECHO Welcome} {ECHO 2nd line} {ECHO third} floppy
|
|
APPEND {ECHO Welcome{Echo 2nd line} {ECHO third floppy
|
|
resulting in the following equivalent three CONFIG.SYS lines
|
|
ECHO Welcome
|
|
ECHO 2nd line
|
|
ECHO third
|
|
|
|
|
|
The following complete example syslinux.cfg and FreeDOS configuration files
|
|
could be used to boot various kernel options avoiding the use of the FreeDOS
|
|
kernel menu in addition to the Sylinux menu.
|
|
|
|
# CONFIG.SYS
|
|
REM always executed, in common with all choices
|
|
FILES=20
|
|
LASTDRIVE=Z
|
|
SHELLHIGH=\COMMAND.COM /E:256 /P
|
|
|
|
|
|
#AUTOEXEC.BAT
|
|
@ECHO OFF
|
|
CLS
|
|
ECHO Welcome to FreeDOS (http://www.freedos.org)!
|
|
ECHO User selected menu %CONFIG%
|
|
|
|
|
|
# SYSLINUX.CFG
|
|
UI vesamenu.c32
|
|
DEFAULT clean
|
|
|
|
LABEL clean
|
|
MENU LABEL FreeDOS with no drivers
|
|
KERNEL memdisk
|
|
INITRD /fdos0360.img
|
|
APPEND floppy FD={SET config=0}
|
|
|
|
LABEL jemm
|
|
MENU LABEL FreeDOS with memory manager
|
|
KERNEL memdisk
|
|
INITRD /fdos0360.img
|
|
APPEND floppy FD={SET config=1}{DEVICE?=JEMMEX.EXE
|
|
|
|
|
|
Syslinux boot-prompt (when vesamenu not used):
|
|
jemm
|
|
or
|
|
jemm NOEMS
|