;
; Copyright (c) Microsoft Corporation.  All rights reserved.
;
;
; Use of this source code is subject to the terms of the Microsoft end-user
; license agreement (EULA) under which you licensed this SOFTWARE PRODUCT.
; If you did not accept the terms of the EULA, you are not authorized to use
; this source code. For a copy of the EULA, please see the LICENSE.RTF on your
; install media.
;
MEMORY
IF IMGMULTIXIP
#define CHAIN_ADDRESS 80220000
	   CHAIN		$(CHAIN_ADDRESS)	00001000			RESERVED
	   pdwXIPLoc	00000000			$(CHAIN_ADDRESS)	FIXUPVAR
	   
	   NK		80221000  	009DF000  RAMIMAGE
	   REGION1  80C00000  	00100000  RAMIMAGE
	   RAM      80D00000  	03300000  RAM
ELSE
	IF IMGRAM64
;------------------------------------------------------
; THIS SETTINGS IS FOR STATIC VIDEO MEMORY CONFIG
;       - AUTOSIZE IS OFF
;       - 64 MB of RAM TOTAL
;       - 18 MB for NK IMAGE + CONV MEM DMA BUFFS
;       - 32 MB for RAM SPACE
;       - 14MB BALANCE UNUSED IS FOR VIDEO MEMORY
;              - start address will go into registr
;              - but, if SYSBIOS exists, then it's 12MB

	   ; below (current) is for retail - more RAM
           ; ------------------------------------------
           ;NK       80220000  00FE0000  RAMIMAGE
           ; --> 18MB for nk.bin + low mem area DMA BUFF
           ;RAM      81200000  02000000  RAM
           ; --> 32MB for ram


	   ; below is for debug build - more NKIMG space
           ; ------------------------------------------
           ;NK       80220000  017E0000  RAMIMAGE
           ; --> 26MB for nk.bin + low mem area DMA BUFF
	   ;RAM      81A00000  01800000  RAM
           ; --> 24MB for RAM

;------------------------------------------------------
; THIS SETTINGS IS FOR DYNAMIC VIDEO MEMORY CONFIG
;       - AUTOSIZE CAN BE ON
;       - 64 MB of RAM TOTAL
;       - 18 MB for NK IMAGE + CONV MEM DMA BUFFS
;       - 44 MB for RAM SPACE
;       - NO BALANCE (except top 2Mb for SYSBIOS)

	   ; below (current) is for retail - more RAM
           ; ------------------------------------------
           NK       80220000  00FE0000  RAMIMAGE
           ; --> 18MB for nk.bin + low mem area DMA BUFF
           RAM      81200000  02C00000  RAM
           ; --> 44MB for ram


	   ; below is for debug build - more image space
           ; ------------------------------------------
           ;NK       80220000  017E0000  RAMIMAGE
           ; --> 26MB for nk.bin + low mem area DMA BUFF
           ;RAM      81A00000  02400000  RAM
           ; --> 36MB for RAM

;------------------------------------------------------

	ENDIF
ENDIF

; Hard reset the system on a software reboot?
;
IF BSP_HARDRESET
    pdwHardReset        00000000        1       FIXUPVAR
ELSE
    pdwHardReset        00000000        0       FIXUPVAR
ENDIF

   FRAMEBUF  800A0000  00020000  RESERVED
   PCMCIABUF 800D0000  00010000  RESERVED
   NSCIRDA   801BC000  00020000  RESERVED
   AUDIOBUF  801FC000  00002000  RESERVED
   LOADRBUF  801FFF00  00000100  RESERVED
   EDBG      80200000  00020000  RESERVED	; EDBG DMA buffer


;--------------------------------------------------------------------
; ADDITIONAL RESERVATION NEEDED FOR STATIC VIDEO MEMORY CONFIG ONLY

            ; IGD       83200000  00E00000  RESERVED	
            ; --> Intel Embedded Graphics Driver Video Memory
            ; --> last 14MB of total 64MB of RAM
            ; must match registry static mem config data
;--------------------------------------------------------------------


CONFIG
   AUTOSIZE=ON

IF IMGMULTIXIP
   RAM_AUTOSIZE=ON
   ROM_AUTOSIZE=ON
   DLLADDR_AUTOSIZE=ON
   
   XIPSCHAIN=$(CHAIN_ADDRESS)
   
   AUTOSIZE_ROMGAP=10000
   AUTOSIZE_DLLADDRGAP=0
   AUTOSIZE_DLLDATAADDRGAP=0
   AUTOSIZE_DLLCODEADDRGAP=0
ENDIF

; @CESYSGEN IF !NK_NKNOCOMP
   COMPRESSION=ON
; @CESYSGEN ENDIF !NK_NKNOCOMP
; @CESYSGEN IF NK_NKNOCOMP
   COMPRESSION=OFF
; @CESYSGEN ENDIF NK_NKNOCOMP

IF IMGPROFILER   
   PROFILE=ON
ELSE
   PROFILE=OFF
ENDIF

   KERNELFIXUPS=ON

;
; ROMFLAGS is a bitmask of options for the kernel
;	ROMFLAGS	0x0001	Disallow Paging
;	ROMFLAGS	0x0002	Not all KMode
;       ROMFLAGS        0x0010  Trust Module only
;
IF IMGTRUSTROMONLY
    IF IMGNOTALLKMODE
       ROMFLAGS=12
    ELSE
       ROMFLAGS=10
    ENDIF
ELSE
    IF IMGNOTALLKMODE
       ROMFLAGS=2
    ELSE
       ROMFLAGS=0
    ENDIF
ENDIF


IF _TGTCPUFAMILY=x86
    ROMOFFSET=80000000
ENDIF

IF IMGTINYFSRAM
    FSRAMPERCENT=0x00000080
ENDIF

