📄 xllp_pm_sleepcontexta.s
字号:
@ cjw Trial version for Swee
@TEST_STUB_PWR_OFF EQU 1
@******************************************************************************
@
@ COPYRIGHT (C) 2002 Intel Corporation.
@
@ This software as well as the software described in it is furnished under
@ license and may only be used or copied in accordance with the terms of the
@ license. The information in this file is furnished for informational use
@ only, is subject to change without notice, and should not be construed as
@ a commitment by Intel Corporation. Intel Corporation assumes no
@ responsibility or liability for any errors or inaccuracies that may appear
@ in this document or any software that may be provided in association with
@ this document.
@
@ Except as permitted by such license, no part of this document may be
@ reproduced, stored in a retrieval system, or transmitted in any form or by
@ any means without the express written consent of Intel Corporation.
@
@ FILENAME: xllp_Pm_SleepContextA.s
@
@ PURPOSE: Provides assembly level code to support context saving,
@ processor sleep and context restoration after sleep
@ for the Bulverde/Mainstone processor/platform.
@
@
@ LAST MODIFIED: 8/27/02
@******************************************************************************
@
@ The functions in this source code are called via a branch with link instruction.
@
@ NOTES:
@
@ These functions assume that the MMU is enabled, except for any which receive all addresses
@ as parameters.
@
.include "xlli_Bulverde_defs.inc" @ Bulverde specific include file
.include "xlli_Mainstone_defs.inc" @ Mainstone specific include file
.include "xllp_Pm_SleepContext.inc" @ Definitions for this file
@ IF 0=1
.ifdef xxNEVER_DO_THIS
.include "mainstone.mac" @ Definitions for this file
.endif @0 : development LED markers
@
.text
.align 5 @ Align =5 required for "ALIGN 32" to work
@
@ Functions made public by this file:
@
.global XllpPmEnterSleep
.global XllpPmChecksumSleepDataVi
.global XllpPmRestoreAfterSleep @ Not called by name elsewhere.
@
@ External functions required for this file:
@
.extern XllpPmSleepCLevelProcessing__FP28XLLP_PM_ENTER_SLEEP_PARAMS_T
.extern XllpPmWakeCLevelProcessing__FP28XLLP_PM_ENTER_SLEEP_PARAMS_TP25XLLP_PM_SLEEP_SAVE_DATA_SUl
@**************************************************************************************************
@
@ XllpPmChecksumSleepDataVi
@
@ Does not assume a stack or MMU enable/disable state.
@
@ Inputs:
@ R0: Base address of area to checksum
@ R1: Number of 4-byte words in area
@ Assumes return address in link register
@
@ Returns:
@ R0: Checksum
@
@ Uses: R0, R1, R2, R3
@
XllpPmChecksumSleepDataVi:
@ do Checksum on the buffer
ldr r2, =(0x5A72) @ Pick a non-zero seed.
@30
XllpPmChVi_Lab1:
ldr r3, [r0], #4 @ get value and increment pointer
add r2, r2, r3
mov r2, r2, ROR #31 @ Rotate left by one bit position
subs r1, r1, #1 @ Count down for entire buffer size
@ bne %b30
bne XllpPmChVi_Lab1
mov r0, r2
.ifdef Interworking
bx lr
.else
.ifdef Thumbing
bx lr
.else
mov pc, lr
.endif
.endif
@; End of XllpPmChecksumSleepDataVi()
@**************************************************************************************************
@******************************************************************************
@
@
@ ********************
@ * *
@ * XllpPmEnterSleep *
@ * *
@ ********************
@
@
@ NOTES: Written for the Bulverde Processor on the Mainstone Development Platform.
@
@;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@ XllpPmEnterSleep() is an assembly-coded function that:
@
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -