;       SCCSID = @(#)sicg.inc   6.4 91/08/21
;
;       SysInit Call Gate packets
;
; *
; *   -  002     4/19/91   Mark Rogalski,   IBM
; *      CP20 DCR 1360  Add DOS=HIGH support
;***********************************************************************;BN011;
; 19Jun91 - G.L.Fulk                                                    ;BN011;
; Add support for a DOS ONLY "FILES=" statement in CONFIG.SYS.          ;BN011;
;***********************************************************************;BN011;
; 8/21/91 Stacey Barnes CP20 B723649 sicg_pktA struc was not DWORD aligned,
;         this caused one of the hsem addresses to be zero when referenced.
;***********************************************************************;77939;
; 02/09/94 Defect 77939 Catherine E. Bundy Added SICGFUN18 call gate to ;77939;
;          call ldrfreemodule instead of dosfreemodule to free device   ;77939;
;          drivers                                                      ;77939;
;***********************************************************************;77939;


include sched.inc

DefaultCountry          equ     1       ; Default Country Code
                                        ; move this to include file

SICGFUN0                equ     0       ; Subfunction 0
SICGFUN1                equ     1       ; Subfunction 1
SICGFUN2                equ     2       ; Subfunction 2
SICGFUN3                equ     3       ; Subfunction 3
SICGFUN4                equ     4       ; Subfunction 4
SICGFUN5                equ     5       ; Subfunction 5

sicg_pkt3 struc                         ; Subfunctions 3, 4, 5, 6, 8
        sicg_devhndl    dw      ?       ; Device module handle
        sicg_devhdr     dd      ?       ; Pointer to first header in device
        sicg_devcs      dw      ?       ; Device CS selector (ring 3)
        sicg_protcs     dw      ?       ; Device CS selector (ring 0)
        sicg_protds     dw      ?       ; Device DS selector (ring 0)
        sicg_realcs     dw      ?       ; Device CS segment (real mode)
        sicg_realds     dw      ?       ; Device DS segment (real mode)
        sicg_drvno      db      ?       ; Block device drive number
sicg_pkt3 ends

sicg_ecode              equ     sicg_realcs ; Length of code segment
sicg_edata              equ     sicg_realds ; Length of data segment

SICGFUN6                equ     6       ; Subfunction 6, SYI message routine
sicg_pkt6 struc                         ; Subfunction 6
        si6_psmt        dd      ?       ; DOSINITDATA pointer to SMT
        si6_pfn         dw      ?       ; pointer to SYI message routine
sicg_pkt6 ends

SICGFUN7                equ     7       ; Subfunction 7

sicg_pkt7 struc                         ; Subfunction 7
        si7_devhdr      dd      ?       ; Pointer to device header
        si7_bpbvec      dd      ?       ; Pointer to BPB vector
        si7_nunits      db      ?       ; Number of units defined
        si7_unit        db      ?       ; Unit number for this DPB
sicg_pkt7 ends

SICGFUN8                equ     8       ; Subfunction 8

SICGFUN9                equ     9       ; Subfunction 9
SICG_FSCCHECK           equ     0       ; perform fscCheck in subfunction 9
SICG_FSCADD             equ     1       ; perform fscAdd in subfunction 9
SICG_FSCREPLACE         equ     2       ; perform fscReplace in subfunction 9

sicg_pkt9 struc                         ; Subfunction 9
        si9_funcnum     db      ?       ; = SICG_FSCCHECK/SICG_FSCADD
sicg_pkt9 ends

SICGFUNA                equ     0Ah     ; Subfunction 0Ah

sicg_pktA struc                         ; Subfunction 0Ah
        siA_Shell       dd      0       ; Head of Shell list
        siA_RMDevice    dd      0       ; Head of RM Device list
        siA_VDDDevice   dd      0       ; Head of VDD Device list
        siA_cb          dd      0       ; size of failure code buffer
        siA_pbuf        dd      0       ; 16:16 address of failure code buffer
        siA_pusEC       dd      0       ; 16:16 address of ulInitErrorCode
        siA_hsemMBE     dd      0       ; 16:16 address of hsemVDMMInitMessageBufferEmpty
        siA_hsemEHB     dd      0       ; 16:16 address of hsemVDMMInitErrorHandlerBusy
        siA_rmsize      dw      640     ; Real memory size
        siA_fcbcnt      dw      16      ; FCB count
        siA_fcbkeep     dw      8       ; Number of FCBs to keep
        siA_filescount  dw      20      ; FILES count                   ;BN011;
        siA_break       db      0       ; Break flag
        siA_Dos_Flags   db      3       ; Dos Flags for UMB and LOAD HIGH ;BN002
        siA_protonly    db      0       ; Protect mode only flag
        siA_lastdrive   db      0       ; Lastdrive value
sicg_pktA ends

SICGFUNB                equ     0Bh     ; Subfunction 0Bh

sicg_pktB struc
        siB_Attributes  dw      ?
        siB_Name        dd      ?
sicg_pktB ends

SICGFUNC                equ     0Ch     ; Subfunction 0Ch

sicg_pktC struc
        siC_Subfunc     dw      ?
sicg_pktC ends

SICGFUND                equ     0Dh     ; Subfunction 0D, Panic
sicg_pktD struc
        siD_ssesp       df      ?       ; Panic caller's SS:ESP
        siD_pmsg        df      ?       ; Panic caller's message pointer
        siD_pfn         df      ?       ; Panic caller's filename pointer
        siD_csip        dd      ?       ; Panic caller's CS:IP
sicg_pktD ends

SICGFUNE                equ     0Eh     ; Subfunction 0Eh, swapper reinit

SICGFUN10               equ     10h     ; Subfunction 10h

SICGFUN11               equ     11h     ; Subfunction 11h

sicg_pkt11 struc                        ; Subfunction 11h
        si11_devhdr     dd      ?       ; Pointer to device header
sicg_pkt11 ends

SICGFUN12               equ     12h     ; Subfunction 12h

SICGFUN13               equ     13h     ; Subfunction 13h

SICGFUN14               equ     14h     ; Subfunction 14h
SICGFUN15               equ     15h     ; Subfunction 15h
sicg_pkt15 struc                        ; Subfunction 15h
        si15_pipehdl    dw      ?       ; handle of pipe
sicg_pkt15 ends

SICGFUN16               equ     16h     ; Subfunction 16h
sicg_pkt16 struc                        ; Subfunction 16h
        sicg_msg_num    dw      ?       ; message ID
        sicg_msg_buf    dd      ?       ; returned message text buffer
sicg_pkt16 ends

SICGFUN17               equ     17h     ; Subfunction 17h
SICG_BLINKLOGO          equ     0       ; Blink the logo
SICG_FINISHED           equ     1       ; Finished with logo

SICGFUN18               equ     18h     ; Subfunction 18h  ceb 77939

SICGFUN19               equ     19h     ; Subfunction 19h  ceb 77939

SICGFUN1A               equ     1ah     ; Subfunc 1A (ResourceManager Notify)
sicg_pkt1A struc
        sicg_1A_func    dw      ?       ; 40,41,42,60,61,62 - notify type
        sicg_1A_off     dw      ?       ;       filespec (if 40 or 60)
        sicg_1A_sel     dw      ?
sicg_pkt1A ends

;       Miscellaneous constants

RAS_DATA_LEN            equ     384     ; Length of RAS BIOS save area
