⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 mmu.s

📁 HAL硬件抽象层源码
💻 S
字号:
;/*************************************************************************** 
; *  Copyright (C) Hynix Semiconductor Limited 2002. All rights reserved. 
; ***************************************************************************/
;******************************************************************************
;  All functions for MMU are disabled because HMS39C7092 is embedded by ARM7TDMI
;******************************************************************************/

	INCLUDE	bits.s
	INCLUDE	sizes.s
	INCLUDE	platform.s
;	INCLUDE target.s

	EXPORT	uHALr_InitMMU		; Setup page tables, MMU etc.
	EXPORT	uHALr_ResetMMU		; Reset Memory to initial state, no MMU

	EXPORT	uHALir_MMUSupported
	EXPORT	uHALir_MPUSupported
	EXPORT	uHALir_CacheSupported
	EXPORT	uHALir_CheckUnifiedCache

	EXPORT	uHALir_WriteCacheMode
	EXPORT	uHALir_ReadCacheMode
	EXPORT	uHALir_DisableICache
	EXPORT	uHALir_DisableDCache
	EXPORT	uHALir_DisableWriteBuffer
	EXPORT	uHALir_CleanDCache
	EXPORT	uHALir_CleanDCacheEntry
	
	; Enter Supervisor mode & disable IRQ.
	IMPORT	uHALir_EnterLockedSvcMode
	IMPORT	uHALir_ExitSvcMode	; Exit Supervisor mode.

	IMPORT	uHAL_AddressTable
	IMPORT	uHAL_MappingTable
	IMPORT	uHALiv_TopOfMemory	; Top of RAM.

        	IMPORT	|Image$$RO$$Base|	; linked location of code

	KEEP

	AREA	uHAL_MMU, CODE, READONLY

;-------------------------------------------------------------------
; Routine to initialise the page tables & MMU to memmap layout.
;
; See SETUPMMU macro for description
; WARNING:	The MMU must be disabled when this routine is called,
;		but routine checks MMU, will do nothing if enabled.
;
; void uHALir_InitMMU(void)	- Init MMU to flat-memory map

uHALr_InitMMU
	mov	pc,lr

;-------------------------------------------------------------------
; void uHALr_ResetMMU(void)	- Function to reset the MMU.
;
; Flushes the Icache, cleans & flushes the Dcache, disables IC, DC, WB and
; MMU returning the memory system to its powerup state (flat map allows this)
;
; Never call ResetMMU without having called InitMMU first.
;
; When running semihosted, care should be exercised to leave the debugger
; in a state similar to that when starting our application.

uHALr_ResetMMU
	mov	pc,lr

;-------------------------------------------------------------------
; Shell routines around MMU/cache query macros

uHALir_MMUSupported
	mov	r0,#0
	MOV	pc, lr

uHALir_MPUSupported
	mov	r0,#0
	MOV	pc, lr

uHALir_CacheSupported
	mov	r0,#0
	MOV	pc, lr

uHALir_CheckUnifiedCache
	mov	r0,#0
	MOV	pc, lr


;-------------------------------------------------------------------
; unsigned int uHALir_ReadCacheMode(void)
;
; Routine to read the mmu state from the Co-processor

uHALir_ReadCacheMode
	mov	r0,#0
	MOV	pc, lr


;-------------------------------------------------------------------
; void uHALir_WriteCacheMode(unsigned int)
;
; Routine to write the mmu state to the Co-processor

uHALir_WriteCacheMode
	mov	pc,lr


;-------------------------------------------------------------------
; void uHALir_DisableICache(void)
;
; Routine to flush and disable the I Cache

uHALir_DisableICache
	mov	pc,lr

;-------------------------------------------------------------------
; void uHALir_DisableDCacheAnd(void)
;
; Routine to flush and disable the D Cache

uHALir_DisableDCache
	mov	pc,lr

;-------------------------------------------------------------------
; void uHALir_DisableWriteBuffer(void)
;
; Routine to disable the Write Buffer

uHALir_DisableWriteBuffer
	mov	pc,lr

;-------------------------------------------------------------------
;void uHALir_CleanDCacheEntry (void *)
;
; Routine to clean (at least) one Data Cache entry

uHALir_CleanDCacheEntry
	mov	pc,lr

;-------------------------------------------------------------------
; void uHALir_CleanDCache(void)
;
; Routine to clean D cache

uHALir_CleanDCache
	mov	pc,lr

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

	END

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -