2019-05-30 12:44:56 +02:00
|
|
|
; The OS/K Team licenses this file to you under the MIT license.
|
2019-05-30 12:19:38 +02:00
|
|
|
; See the LICENSE file in the project root for more information.
|
|
|
|
|
2019-07-09 19:51:03 +02:00
|
|
|
__sysmain:
|
|
|
|
jmp start
|
|
|
|
|
|
|
|
|
|
|
|
include "crt/crt.k"
|
|
|
|
|
2019-07-10 17:17:45 +02:00
|
|
|
;
|
|
|
|
; Special addresses
|
|
|
|
;
|
2019-08-21 16:57:32 +02:00
|
|
|
DOSKRNL_CODE := 0x100000 ; 1MB
|
|
|
|
DOSKRNL_STACK := 0x104000 ; + 16KB
|
|
|
|
TRAP0_STACK := 0x104800 ; + 18KB
|
|
|
|
INTR0_STACK := 0x105000 ; + 20KB
|
|
|
|
EXCT0_STACK := 0x105800 ; + 22KB
|
|
|
|
|
|
|
|
; The kernel guarantees that COMMAND.COM
|
|
|
|
; will always be loaded on a 16KB boundary
|
|
|
|
; This is guaranteed to be the case in all
|
|
|
|
; future versions as well
|
|
|
|
CMDCOM_LOADP := 0x108000 ; + 32KB
|
2019-07-10 17:17:45 +02:00
|
|
|
CMDCOM_MAXSZ := 0x80000 ; 512KB
|
|
|
|
|
2019-05-30 12:19:38 +02:00
|
|
|
;
|
|
|
|
; Entry point
|
|
|
|
;
|
2019-06-21 22:19:55 +02:00
|
|
|
start:
|
2019-07-10 17:17:45 +02:00
|
|
|
mov rsp, DOSKRNL_STACK
|
2019-07-17 22:25:50 +02:00
|
|
|
mov rbp, zero
|
2019-05-30 12:19:38 +02:00
|
|
|
|
2019-08-14 20:23:05 +02:00
|
|
|
;dump
|
2019-08-06 22:47:39 +02:00
|
|
|
|
2019-05-30 12:27:13 +02:00
|
|
|
call main
|
2019-06-23 20:56:04 +02:00
|
|
|
|
2019-07-09 19:51:03 +02:00
|
|
|
crash
|
2019-06-13 17:13:59 +02:00
|
|
|
|
2019-05-30 18:31:50 +02:00
|
|
|
;
|
2019-06-21 12:13:09 +02:00
|
|
|
; Disk Operating System
|
2019-06-14 16:47:01 +02:00
|
|
|
;
|
2019-06-26 21:25:59 +02:00
|
|
|
|
2019-06-21 19:38:31 +02:00
|
|
|
include "sys/drv/cpudev.k"
|
|
|
|
include "sys/drv/memdev.k"
|
2019-06-26 21:25:59 +02:00
|
|
|
include "sys/drv/diskdev.k"
|
|
|
|
|
2019-08-06 23:21:37 +02:00
|
|
|
include "sys/intr/excepts.k"
|
2019-07-09 19:51:03 +02:00
|
|
|
include "sys/intr/common.k"
|
|
|
|
include "sys/intr/trap0.k"
|
|
|
|
|
2019-08-06 22:47:39 +02:00
|
|
|
include "sys/dumprf.k"
|
2019-08-06 23:21:37 +02:00
|
|
|
include "sys/main.k"
|
2019-05-30 12:19:38 +02:00
|
|
|
|