changeset 2734:1ad5f8473788

Added krn.asm and nos9l1 makefile changes back into current repo for memory fix and becker files.
author drencor-xeen
date Mon, 10 Dec 2012 13:42:45 -0600
parents ebf319736e9c
children 05b7feef845a
files level1/coco/modules/makefile level1/modules/kernel/krn.asm
diffstat 2 files changed, 37 insertions(+), 29 deletions(-) [+]
line wrap: on
line diff
--- a/level1/coco/modules/makefile	Mon Dec 10 07:28:11 2012 -0500
+++ b/level1/coco/modules/makefile	Mon Dec 10 13:42:45 2012 -0600
@@ -23,7 +23,7 @@
 
 BOOTERS		= boot_1773_6ms boot_1773_30ms \
 		boot_burke boot_rampak boot_wd1002 boot_dw3 boot_dw3_coco1 \
-		boot_tc3 boot_ide boot_rom
+		boot_tc3 boot_ide boot_rom boot_dw3_becker
 BOOTTRACK	= rel $(BOOTERS)
 KERNEL		= krn krnp2 wbug
 SYSMODS		= ioman init sysgo_dd sysgo_h0 rominfo vectors
@@ -33,7 +33,7 @@
 		clock2_messemu clock2_jvemu clock2_dw3
 
 RBF		= rbf.mn \
-		rbdw3.dr dw3.sb dw3_coco1.sb \
+		rbdw3.dr dw3.sb dw3_coco1.sb dw3_becker.sb \
 		rb1773.dr rb1773_scii_ff74.dr rb1773_scii_ff58.dr \
 		ddd0_35s.dd d0_35s.dd d1_35s.dd d2_35s.dd d3_35s.dd \
 		ddd0_40d.dd d0_40d.dd d1_40d.dd d2_40d.dd \
@@ -87,9 +87,15 @@
 boot_dw3_coco1: boot_dw3.asm
 	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aBAUD38400=1
 
+boot_dw3_becker: boot_dw3.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aBECKER=1
+
 dw3_coco1.sb: dw3.asm
 	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aBAUD38400=1
 
+dw3_becker.sb: dw3.asm
+	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aBECKER=1
+
 boot_1773_6ms:	boot_1773.asm
 	$(AS) $< $(ASOUT)$@ $(AFLAGS) -aDNum=0 -aSTEP=0
 
--- a/level1/modules/kernel/krn.asm	Mon Dec 10 07:28:11 2012 -0500
+++ b/level1/modules/kernel/krn.asm	Mon Dec 10 13:42:45 2012 -0600
@@ -5,7 +5,7 @@
 *
 * This is how the memory map looks after the kernel has initialized:
 *
-*     $0000----> ================================== 
+*     $0000----> ==================================
 *               |                                  |
 *               |                                  |
 *  $0020-$0111  |  System Globals (D.FMBM-D.XNMI)  |
@@ -91,7 +91,7 @@
 * OS-9 Genesis!
 
 OS9Cold  equ   *
-         
+
 * clear out system globals from $0000-$0400
 *         ldx   #D.FMBM
          ldx   #$0000
@@ -158,13 +158,13 @@
          leay  ,x
 * Here, Y = end of RAM
 L00C2    leax  ,y                      X = end of RAM
-         
+
          ELSE
-         
+
          IFNE  atari
          ldx   #$8000
          ELSE
-         ldx   #Bt.Start         
+         ldx   #Bt.Start
          ENDC
          ENDC
          stx   <D.MLIM                 save off memory limit
@@ -198,15 +198,15 @@
          ELSE
          ldy	#Bt.Start+Bt.Size
          ENDC
-         
+
          lbsr	ValMods
          IFNE  atari
 
-         ldx   #$D800				
+         ldx   #$D800
          ldy   #$F400
          lbsr	ValMods
          ENDC
-         
+
 * Copy vectors to system globals
 L00EE    leay  >Vectors,pcr
          leax  >ModTop,pcr
@@ -233,7 +233,7 @@
          stx   <D.SysSvc
          stx   <D.SWI2
          leax  >Poll,pcr          point to default poll routine
-         stx   <D.Poll            and save it 
+         stx   <D.Poll            and save it
          leax  >Clock,pcr         get default clock routine
          stx   <D.Clock           and save it to the vector
          stx   <D.AltIRQ          and in the alternate IRQ vector
@@ -252,18 +252,20 @@
          bita  #CRCOn			CRC on?
          beq   GetMem			branch if not (already cleared earlier)
          inc   <D.CRC			else turn on CRC checking
-GetMem   ldd   MaxMem+1,u
-         clrb
-         cmpd  <D.MLIM
-         bcc   L0158
-         std   <D.MLIM
+*GetMem   ldd   MaxMem+1,u
+*         clrb
+*         cmpd  <D.MLIM
+*         bcc   L0158
+*         std   <D.MLIM
+GetMem   equ   *
+         clra
 L0158    ldx   <D.FMBM
 		IFNE	atari
 * In the Atari, memory $0000-$08FF is used by the system
          ldb   #%11111111
          stb   ,x				mark $0000-$07FF as allocated
          stb   $1A,x			mark $D000-$D7FF I/O area as allocated
-         ldb   #%10000000		
+         ldb   #%10000000
          stb   1,x				mark $0800-$08FF as allocated
 		ELSE
 * In the CoCo, memory $0000-$04FF is used by the system
@@ -354,7 +356,7 @@
          std   P$SP,u                  and store it
          bne   L01FD                   branch if not zero (still will sleep)
 L01E7    ldu   P$Queue,x               get process current queue pointer
-         bsr   L021A 
+         bsr   L021A
          leax  ,u
          beq   L01FB
          lda   P$State,x               get process state byte
@@ -381,7 +383,7 @@
 
 
 *FAProc   ldx   R$X,u        Get ptr to process to activate
-*L0D11    clrb  
+*L0D11    clrb
 *         pshs  cc,b,x,y,u
 *         lda   P$Prior,x    Get process priority
 *         sta   P$Age,x      Save it as age (How long it's been around)
@@ -399,14 +401,14 @@
 *L0D29    leay  ,u           point Y to current process
 *L0D2B    ldu   P$Queue,u    get pointer to next process in chain
 *         bne   L0D1F        Still more in chain, keep going
-*         ldd   P$Queue,y    
+*         ldd   P$Queue,y
 *         stx   P$Queue,y    save new process to chain
 *         std   P$Queue,x
 *         puls  cc,b,x,y,u,pc
 
 
          use    faproc.asm
-         
+
 * User-State system call entry point
 *
 * All system calls made from user-state will go through this code.
@@ -630,7 +632,7 @@
          ldy   M$Size,x
          bsr   ChkMCRC                 checkm module CRC
          puls  pc,x
-         
+
 * check module header parity
 * Y = pointer to parity byte
 ChkMHPar pshs  y,x
@@ -876,9 +878,9 @@
 L05E7    puls  pc,u,x
 
 		use   fsrqmem.asm
-         
+
 		use   fallbit.asm
-         
+
 		use   fprsnam.asm
 
 		use   fcmpnam.asm
@@ -901,7 +903,7 @@
 		bcs	valloop@
 valret	puls  y,pc
 
-		
+
 VectCode bra   SWI3Jmp		$0100
          nop
          bra   SWI2Jmp		$0103
@@ -968,17 +970,17 @@
 		emod
 eom      	equ	*
 
-Vectors  fdb   SWI3                    SWI3 
+Vectors  fdb   SWI3                    SWI3
          fdb   SWI2                    SWI2
          fdb   DUMMY                   FIRQ
          fdb   SVCIRQ                  IRQ
          fdb   SWI                     SWI
          fdb   SVCNMI                  NMI
-         
-         
+
+
          IFNE  ATARI
          fdb	$F3FE-(*-OS9Cold)
          ENDC
-         
+
 eomem    equ   *
          end