fix nasm warning - add missing colon to label

git-svn-id: https://svn.code.sf.net/p/freedos/svn/kernel/trunk@1373 6ac86273-5f31-0410-b378-82cca8765d1b
This commit is contained in:
Kenneth J Davis 2009-05-04 03:12:53 +00:00
parent 240bcc30e2
commit 65f8276a45

View File

@ -32,25 +32,25 @@
%include "ludivmul.inc" %include "ludivmul.inc"
segment PSP segment PSP
extern _ReqPktPtr:wrt LGROUP extern _ReqPktPtr:wrt LGROUP
STACK_SIZE equ 384/2 ; stack allocated in words STACK_SIZE equ 384/2 ; stack allocated in words
;************************************************************ ;************************************************************
; KERNEL BEGINS HERE, i.e. this is byte 0 of KERNEL.SYS ; KERNEL BEGINS HERE, i.e. this is byte 0 of KERNEL.SYS
;************************************************************ ;************************************************************
..start: ..start:
entry: entry:
jmp short realentry jmp short realentry
;************************************************************ ;************************************************************
; KERNEL CONFIGURATION AREA ; KERNEL CONFIGURATION AREA
; this is copied up on the very beginning ; this is copied up on the very beginning
; it's a good idea to keep this in sync with KConfig.h ; it's a good idea to keep this in sync with KConfig.h
;************************************************************ ;************************************************************
global _LowKernelConfig global _LowKernelConfig
_LowKernelConfig: _LowKernelConfig:
db 'CONFIG' ; constant db 'CONFIG' ; constant
@ -68,12 +68,12 @@ BootHarddiskSeconds db 0 ;
configend: configend:
;************************************************************ ;************************************************************
; KERNEL CONFIGURATION AREA END ; KERNEL CONFIGURATION AREA END
;************************************************************ ;************************************************************
;************************************************************ ;************************************************************
; KERNEL real entry (at ~60:20) ; KERNEL real entry (at ~60:20)
; ;
; moves the INIT part of kernel.sys to high memory (~9000:0) ; moves the INIT part of kernel.sys to high memory (~9000:0)
@ -81,7 +81,7 @@ configend:
; to aid debugging, some '123' messages are output ; to aid debugging, some '123' messages are output
; this area is discardable and used as temporary PSP for the ; this area is discardable and used as temporary PSP for the
; init sequence ; init sequence
;************************************************************ ;************************************************************
realentry: ; execution continues here realentry: ; execution continues here
@ -96,13 +96,13 @@ realentry: ; execution continues here
pop bx pop bx
pop ax pop ax
jmp far kernel_start jmp far kernel_start
beyond_entry: resb 256-(beyond_entry-entry) beyond_entry: resb 256-(beyond_entry-entry)
; scratch area for data (DOS_PSP) ; scratch area for data (DOS_PSP)
segment INIT_TEXT segment INIT_TEXT
extern _FreeDOSmain extern _FreeDOSmain
; ;
; kernel start-up ; kernel start-up
@ -117,60 +117,60 @@ kernel_start:
popf popf
pop bx pop bx
mov ax,seg init_tos mov ax,seg init_tos
cli cli
mov ss,ax mov ss,ax
mov sp,init_tos mov sp,init_tos
int 12h ; move init text+data to higher memory int 12h ; move init text+data to higher memory
mov cl,6 mov cl,6
shl ax,cl ; convert kb to para shl ax,cl ; convert kb to para
mov dx,15 + init_end wrt INIT_TEXT mov dx,15 + init_end wrt INIT_TEXT
mov cl,4 mov cl,4
shr dx,cl shr dx,cl
sub ax,dx sub ax,dx
mov es,ax mov es,ax
mov dx,__INIT_DATA_START wrt INIT_TEXT ; para aligned mov dx,__INIT_DATA_START wrt INIT_TEXT ; para aligned
shr dx,cl shr dx,cl
add ax,dx add ax,dx
mov ss,ax ; set SS to init data segment mov ss,ax ; set SS to init data segment
sti ; now enable them sti ; now enable them
mov ax,cs mov ax,cs
mov dx,__InitTextStart wrt HMA_TEXT ; para aligned mov dx,__InitTextStart wrt HMA_TEXT ; para aligned
shr dx,cl shr dx,cl
%ifdef WATCOM %ifdef WATCOM
add ax,dx add ax,dx
%endif %endif
mov ds,ax mov ds,ax
mov si,-2 + init_end wrt INIT_TEXT ; word aligned mov si,-2 + init_end wrt INIT_TEXT ; word aligned
lea cx,[si+2] lea cx,[si+2]
mov di,si mov di,si
shr cx,1 shr cx,1
std ; if there's overlap only std is safe std ; if there's overlap only std is safe
rep movsw rep movsw
; move HMA_TEXT to higher memory ; move HMA_TEXT to higher memory
sub ax,dx sub ax,dx
mov ds,ax ; ds = HMA_TEXT mov ds,ax ; ds = HMA_TEXT
mov ax,es mov ax,es
sub ax,dx sub ax,dx
mov es,ax ; es = new HMA_TEXT mov es,ax ; es = new HMA_TEXT
mov si,-2 + __InitTextStart wrt HMA_TEXT mov si,-2 + __InitTextStart wrt HMA_TEXT
lea cx,[si+2] lea cx,[si+2]
mov di,si mov di,si
shr cx,1 shr cx,1
rep movsw rep movsw
cld cld
%ifndef WATCOM ; for WATCOM: CS equal for HMA and INIT %ifndef WATCOM ; for WATCOM: CS equal for HMA and INIT
add ax,dx add ax,dx
mov es,ax ; otherwise CS -> init_text mov es,ax ; otherwise CS -> init_text
%endif %endif
push es push es
mov ax,cont mov ax,cont
push ax push ax
retf retf
cont: ; Now set up call frame cont: ; Now set up call frame
mov ds,[cs:_INIT_DGROUP] mov ds,[cs:_INIT_DGROUP]
mov bp,sp ; and set up stack frame for c mov bp,sp ; and set up stack frame for c
@ -182,34 +182,34 @@ cont: ; Now set up call frame
popf popf
pop bx pop bx
mov byte [_BootDrive],bl ; tell where we came from mov byte [_BootDrive],bl ; tell where we came from
;!! int 11h ;!! int 11h
;!! mov cl,6 ;!! mov cl,6
;!! shr al,cl ;!! shr al,cl
;!! inc al ;!! inc al
;!! mov byte [_NumFloppies],al ; and how many ;!! mov byte [_NumFloppies],al ; and how many
mov ax,ss mov ax,ss
mov ds,ax mov ds,ax
mov es,ax mov es,ax
jmp _FreeDOSmain jmp _FreeDOSmain
segment INIT_TEXT_END segment INIT_TEXT_END
;************************************************************ ;************************************************************
; KERNEL CODE AREA END ; KERNEL CODE AREA END
; the NUL device ; the NUL device
;************************************************************ ;************************************************************
segment CONST segment CONST
; ;
; NUL device strategy ; NUL device strategy
; ;
global _nul_strtgy global _nul_strtgy
_nul_strtgy: _nul_strtgy:
mov word [cs:_ReqPktPtr],bx ;save rq headr mov word [cs:_ReqPktPtr],bx ;save rq headr
mov word [cs:_ReqPktPtr+2],es mov word [cs:_ReqPktPtr+2],es
@ -218,7 +218,7 @@ _nul_strtgy:
; ;
; NUL device interrupt ; NUL device interrupt
; ;
global _nul_intr global _nul_intr
_nul_intr: _nul_intr:
push es push es
push bx push bx
@ -252,12 +252,12 @@ _intvec_table: db 10h
global _int1e_table global _int1e_table
_int1e_table: times 0eh db 0 _int1e_table: times 0eh db 0
;************************************************************ ;************************************************************
; KERNEL FIXED DATA AREA ; KERNEL FIXED DATA AREA
;************************************************************ ;************************************************************
segment _FIXED_DATA segment _FIXED_DATA
; Because of the following bytes of data, THIS MODULE MUST BE THE FIRST ; Because of the following bytes of data, THIS MODULE MUST BE THE FIRST
; IN THE LINK SEQUENCE. THE BYTE AT DS:0004 determines the SDA format in ; IN THE LINK SEQUENCE. THE BYTE AT DS:0004 determines the SDA format in
@ -303,7 +303,7 @@ _clock dd 0 ; 0008 CLOCK$ device
_syscon dw _con_dev,seg _con_dev ; 000c console device _syscon dw _con_dev,seg _con_dev ; 000c console device
global _maxbksize global _maxbksize
_maxbksize dw 512 ; 0010 maximum bytes/sector of any block device _maxbksize dw 512 ; 0010 maximum bytes/sector of any block device
dd 0 ; 0012 pointer to buffers info structure dd 0 ; 0012 pointer to buffers info structure
global _CDSp global _CDSp
_CDSp dd 0 ; 0016 Current Directory Structure _CDSp dd 0 ; 0016 Current Directory Structure
global _FCBp global _FCBp
@ -342,15 +342,15 @@ _BootDrive db 1 ; 0043 drive we booted from
%ENDIF %ENDIF
dw 0 ; 0045 Extended memory in KBytes dw 0 ; 0045 Extended memory in KBytes
buf_info: buf_info:
global _firstbuf global _firstbuf
_firstbuf dd 0 ; 0047 disk buffer chain _firstbuf dd 0 ; 0047 disk buffer chain
dw 0 ; 004B Number of dirty buffers dw 0 ; 004B Number of dirty buffers
dd 0 ; 004D pre-read buffer dd 0 ; 004D pre-read buffer
dw 0 ; 0051 number of look-ahead buffers dw 0 ; 0051 number of look-ahead buffers
global _bufloc global _bufloc
_bufloc db 0 ; 0053 00=conv 01=HMA _bufloc db 0 ; 0053 00=conv 01=HMA
global _deblock_buf global _deblock_buf
_deblock_buf dd 0 ; 0054 deblock buffer _deblock_buf dd 0 ; 0054 deblock buffer
times 3 db 0 ; 0058 unknown times 3 db 0 ; 0058 unknown
dw 0 ; 005B unknown dw 0 ; 005B unknown
@ -361,31 +361,31 @@ _VgaSet db 0 ; 0060 unknown
global _uppermem_link global _uppermem_link
_uppermem_link db 0 ; 0063 upper memory link flag _uppermem_link db 0 ; 0063 upper memory link flag
_min_pars dw 0 ; 0064 minimum paragraphs of memory _min_pars dw 0 ; 0064 minimum paragraphs of memory
; required by program being EXECed ; required by program being EXECed
global _uppermem_root global _uppermem_root
_uppermem_root dw 0ffffh ; 0066 dmd_upper_root (usually 9fff) _uppermem_root dw 0ffffh ; 0066 dmd_upper_root (usually 9fff)
_last_para dw 0 ; 0068 para of last mem search _last_para dw 0 ; 0068 para of last mem search
SysVarEnd: SysVarEnd:
;; FreeDOS specific entries ;; FreeDOS specific entries
global _os_setver_minor global _os_setver_minor
_os_setver_minor db 0 _os_setver_minor db 0
global _os_setver_major global _os_setver_major
_os_setver_major db 5 _os_setver_major db 5
global _os_minor global _os_minor
_os_minor db 0 _os_minor db 0
global _os_major global _os_major
_os_major db 5 _os_major db 5
global _rev_number global _rev_number
_rev_number db 0 _rev_number db 0
global _version_flags global _version_flags
_version_flags db 0 _version_flags db 0
global _f_nodes global _f_nodes
_f_nodes dd 0 _f_nodes dd 0
global _f_nodes_cnt global _f_nodes_cnt
_f_nodes_cnt dw 0 _f_nodes_cnt dw 0
global os_release global os_release
extern _os_release extern _os_release
os_release dw _os_release os_release dw _os_release
;; The first 5 sft entries appear to have to be at DS:00cc ;; The first 5 sft entries appear to have to be at DS:00cc
times (0cch - ($ - DATASTART)) db 0 times (0cch - ($ - DATASTART)) db 0
@ -591,7 +591,7 @@ _sda_lpFcb times 2 dw 0 ;286 - pointer to callers FCB
_current_sft_idx dw 0 ;28A - SFT index for next open _current_sft_idx dw 0 ;28A - SFT index for next open
; used by MS NET ; used by MS NET
; Pad to 05b2h ; Pad to 05b2h
times (292h - ($ - _internal_data)) db 0 times (292h - ($ - _internal_data)) db 0
dw __PriPathBuffer ; 292 - "sda_WFP_START" offset in DOS DS of first filename argument dw __PriPathBuffer ; 292 - "sda_WFP_START" offset in DOS DS of first filename argument
dw __SecPathBuffer ; 294 - "sda_REN_WFP" offset in DOS DS of second filename argument dw __SecPathBuffer ; 294 - "sda_REN_WFP" offset in DOS DS of second filename argument
@ -654,11 +654,11 @@ _VirtOpen db 0 ;782 - virtual open flag
; end of controlled variables ; end of controlled variables
; ;
segment _BSS segment _BSS
;!! global _NumFloppies ;!! global _NumFloppies
;!!_NumFloppies resw 1 ;!!_NumFloppies resw 1
;!!intr_dos_stk resw 1 ;!!intr_dos_stk resw 1
;!!intr_dos_seg resw 1 ;!!intr_dos_seg resw 1
; mark front and end of bss area to clear ; mark front and end of bss area to clear
@ -676,11 +676,11 @@ __ib_end:
init_tos: init_tos:
; the last paragraph of conventional memory might become an MCB ; the last paragraph of conventional memory might become an MCB
resb 16 resb 16
global __init_end global __init_end
__init_end: __init_end:
init_end: init_end:
segment _DATA segment _DATA
; blockdev private stack ; blockdev private stack
global blk_stk_top global blk_stk_top
times 192 dw 0 times 192 dw 0
@ -723,7 +723,7 @@ segment ID_E
__INIT_DATA_END: __INIT_DATA_END:
segment INIT_TEXT_START segment INIT_TEXT_START
global __InitTextStart global __InitTextStart
__InitTextStart: ; and c version __InitTextStart: ; and c version
@ -731,9 +731,9 @@ __InitTextStart: ; and c version
; ;
; start end end of HMA area ; start end end of HMA area
segment HMA_TEXT_START segment HMA_TEXT_START
global __HMATextAvailable global __HMATextAvailable
__HMATextAvailable __HMATextAvailable:
global __HMATextStart global __HMATextStart
__HMATextStart: __HMATextStart:
@ -748,25 +748,25 @@ begin_hma:
db 0 db 0
; to minimize relocations ; to minimize relocations
global _DGROUP_ global _DGROUP_
_DGROUP_ dw DGROUP _DGROUP_ dw DGROUP
%ifdef WATCOM %ifdef WATCOM
; 32 bit multiplication + division ; 32 bit multiplication + division
global __U4M global __U4M
__U4M: __U4M:
LMULU LMULU
global __U4D global __U4D
__U4D: __U4D:
LDIVMODU LDIVMODU
%endif %endif
resb 0xd0 - ($-begin_hma) resb 0xd0 - ($-begin_hma)
; reserve space for far jump to cp/m routine ; reserve space for far jump to cp/m routine
resb 5 resb 5
;End of HMA segment ;End of HMA segment
segment HMA_TEXT_END segment HMA_TEXT_END
global __HMATextEnd global __HMATextEnd
__HMATextEnd: ; and c version __HMATextEnd: ; and c version
@ -775,20 +775,20 @@ __HMATextEnd: ; and c version
; The default stack (_TEXT:0) will overwrite the data area, so I create a dummy ; The default stack (_TEXT:0) will overwrite the data area, so I create a dummy
; stack here to ease debugging. -- ror4 ; stack here to ease debugging. -- ror4
segment _STACK class=STACK stack segment _STACK class=STACK stack
segment CONST segment CONST
; dummy interrupt return handlers ; dummy interrupt return handlers
global _int22_handler global _int22_handler
global _int28_handler global _int28_handler
global _int2a_handler global _int2a_handler
global _empty_handler global _empty_handler
_int22_handler: _int22_handler:
_int28_handler: _int28_handler:
_int2a_handler: _int2a_handler:
_empty_handler: _empty_handler:
@ -797,8 +797,8 @@ _empty_handler:
global _initforceEnableA20 global _initforceEnableA20
initforceEnableA20: initforceEnableA20:
call near forceEnableA20 call near forceEnableA20
retf retf
global __HMARelocationTableStart global __HMARelocationTableStart
__HMARelocationTableStart: __HMARelocationTableStart:
@ -954,7 +954,7 @@ forceEnableA20success:
pop es pop es
pop ds pop ds
ret ret
; ;
; global f*cking compatibility issues: ; global f*cking compatibility issues:
; ;