Files
qasm/IIGS.601.SRC/GS.OS/P8/Loader.Expansion.Notes
Shawn Quick dfcaae62dd Add qlink, the disk tools, and a bootable ProDOS 8 image.
Move the assembler to src/qasm. qlink links OMF 1.0 and 2.0 from a script. makeBin flattens a load file, qomf dumps OMF, and qpro builds ProDOS volumes. APW and MPW assemble through the ORCA front end. Relocatable modules emit OMF objects. Listings stay off unless -l is set.

make boot assembles the GS/OS 6.0.1 ProDOS 8 kernel and BASIC.SYSTEM into an 800K volume. BASIC.SYSTEM accepts ls and pfx, and its splash reports PRODOS BASIC 2.0, copyright 1983-2026. IIGS.601.SRC is the source and the BASIC.SYSTEM oracle that image is built from.
2026-10-16 14:41:55 -07:00

1 line
3.2 KiB
Plaintext

ProDOS 8 Loader Code Expansion Notes by Monte Benaresh
May 19, 1989
Revised May 23, 1989 by Monte Benaresh
ABOUT THIS DOCUMENT
This document contains my log of steps taken to expand the "loader" portion of the
"P8" file on the GS/OSª System Disk. This portion of code gets executed when P8 is
loaded into the machine and is then discarded once ProDOS is installed into the machine
(assuming the installation is successful). This code includes special-cased routines
to set up the environment and to relocate the various drivers and managers to their
final execution locations. This code also displays the splash screen, identifies
online devices, and loads the ".SYSTEM" file.
The loader portion of the code is of predefined size and is currently $B00 bytes long.
This fact is hard-coded in some of the P8 sourcecode and in the makefile, so expansion
of this area is a non-trivial task that presently requires some changes to be made by
hand. This document is intended to be a log of those changes so that subsequent
attempts to expand the loader section will require the engineer to merely use this
document as a cookbook-type guide. Better yet, the aforementioned interdependencies
could be bound by the build system so that expansion of the loader portion would be
automated.
This task is motivated by a need to make room for a patch which will support programs
which run under ProDOS 8 and which make QuickDraw2 calls. This patch fixes a bug in
the 5.0 System Disk where QuickDraw makes GS/OSª calls without first checking that the
System is installed in the machine. The patch installs code which is vectored into
the GS/OSª entry points and returns an error for GS/OSª calls. This fixes things
because QuickDraw handles errors properly.
The patch is run during the load/setup phase of starting P8. The loader code checks
that the current machine is a GS and that P8 is being booted directly, i.e., not
being installed by GQuit. The patch disables interrupts (for no specific reason,
only as a precaution), switches the machine to native mode, allocates memory for
the "real" GS/OS patch, copies that code into the allocated memory, sets up both
GS/OSª entry points to point to their appropriate pieces of the code, restores the
environment and then returns to the P8 loader code.
This change is documented in rev note #101 in the P8 mlisrc.aii file.
NOTES
file; PROC; location changes
-------------------- -------
ram.n; PROC RAM1; label "SRCE" (2 places) "EQU $2B00" becomes "EQU $2C00"
ram.n; PROC RAM2; proc header "ORG $2B00" becomes "ORG $2C00"
mlisrc.aii; before PROC PROCONE; label "ram_1" "equ mli_0+$b00" becomes "equ mli_0+$C00"
Hex addresses in comments on following
equates should be updated.
mlisrc.aii; PROC PROCONE; label "ram_1" exact duplicate of above change
mlisrc.aii; PROC PROCONE; label "loader_end" from here to the end of the proc (ENDP):
"$B00" becomes "$C00"
"$2B00" becomes "$2C00"
make.p8; build commands for "ram.bin" "-lseg RAM2 -org $002B00" becomes
"-lseg RAM2 -org $002C00"
make.p8; build commands for "{workfolder}p8" in "Overlayiigs" commands, all hex values
after a "-a" directive must be augmented
by $100, e.g., "-a $2F36" becomes
"-a $3036"