Mercurial > hg > Members > kono > nitros9-code
annotate level2/modules/kernel/fgblkmp.asm @ 3195:6eb2edad80d8
L2: Introduce symbol KrnBlk to define kernel block number
This is the block number that the kernel is loaded into. This is
platform-specific, a function of the behaviour of the platform MMU/DAT.
CRCs are unaffected by this change.
author | Neal Crook <foofoobedoo@gmail.com> |
---|---|
date | Thu, 01 Jun 2017 22:13:49 +0100 |
parents | 039ddb7c8ad7 |
children |
rev | line source |
---|---|
1345 | 1 ************************************************** |
2 * System Call: F$GBlkMp | |
3 * | |
3123
039ddb7c8ad7
l2 kernel: Remove tabs and trailing whitespace, align comments
Neal Crook <foofoobedoo@gmail.com>
parents:
1345
diff
changeset
|
4 * Function: |
1345 | 5 * |
6 * Input: X = 1024 byte buffer pointer | |
7 * | |
8 * Output: D = Number of bytes per block | |
9 * Y = Size of system's memory block map | |
10 * | |
11 * | |
12 * Error: CC = C bit set; B = error code | |
13 * | |
1145 | 14 FGBlkMp ldd #DAT.BlSz # bytes per MMU block (8k) |
15 std R$D,u Put into caller's D register | |
16 ldd <D.BlkMap+2 Get end of system block map ptr | |
17 subd <D.BlkMap Subtract start of system block map ptr | |
18 std R$Y,u Store size of system block map in caller's Y reg. | |
19 tfr d,y | |
20 lda <D.SysTsk Get system task # | |
21 ldx <D.Proc Get caller's task # | |
22 ldb P$Task,x get task # of caller | |
23 ldx <D.BlkMap Get start ptr of system block map | |
24 L0978 ldu R$X,u Get addr to put it that caller requested | |
25 os9 F$Move Move it into caller's space | |
3123
039ddb7c8ad7
l2 kernel: Remove tabs and trailing whitespace, align comments
Neal Crook <foofoobedoo@gmail.com>
parents:
1345
diff
changeset
|
26 rts |