FreeCalypso > hg > fc-tourmaline
view src/cs/system/main/gcc/int_dummy.S @ 51:04aaa5622fa7
disable deep sleep when Iota LEDB is on
TI's Iota chip docs say that CLK13M must be running in order for
LEDB to work, and practical experience on Mot C139 which uses
Iota LEDB for its keypad backlight concurs: if Calypso enters
deep sleep while the keypad backlight is turned on, the light
flickers visibly as the chipset goes into and out of deep sleep.
TI's original L1 sleep manager code had logic to disable deep sleep
when LT_Status() returns nonzero, but that function only works
for B-Sample and C-Sample LT, always returns 0 on BOARD 41 - no
check of Iota LEDB status anywhere. Change this code for our
current hardware: disable deep sleep when Iota LEDB has been
turned on through LLS.
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Mon, 19 Oct 2020 05:11:29 +0000 |
parents | 4e78acac3d88 |
children |
line wrap: on
line source
/* * This assembly module contains a few dummy INT_*() functions * which are needed by Nucleus (tcc.c) but aren't used in TI's * environment. This code used to be in the big messy int.s * assembly module in the original version. */ .text .code 32 /*************************************************************************/ /* */ /* FUNCTION */ /* */ /* INT_Vectors_Loaded */ /* */ /* DESCRIPTION */ /* */ /* This function returns the flag that indicates whether or not */ /* all the default vectors have been loaded. If it is false, */ /* each LISR register also loads the ISR shell into the actual */ /* vector table. */ /* */ /* AUTHOR */ /* */ /* Barry Sellew, Accelerated Technology, Inc. */ /* */ /* CALLED BY */ /* */ /* TCC_Register_LISR Register LISR for vector */ /* */ /* CALLS */ /* */ /* None */ /* */ /* INPUTS */ /* */ /* None */ /* */ /* OUTPUTS */ /* */ /* None */ /* */ /* HISTORY */ /* */ /* NAME DATE REMARKS */ /* */ /* B. Sellew 01-19-1996 Created initial version 1.0 */ /* B. Sellew 01-22-1996 Verified version 1.0 */ /* */ /*************************************************************************/ @INT INT_Vectors_Loaded(void) @{ .globl INT_Vectors_Loaded INT_Vectors_Loaded: @ @ /* Just return the loaded vectors flag. */ @ return(INT_Loaded_Flag); @ MOV a1,#1 @ Always return TRUE since there @ are really only two normal @ vectors IRQ & FIQ BX lr @ Return to caller @} /*************************************************************************/ /* */ /* FUNCTION */ /* */ /* INT_Setup_Vector */ /* */ /* DESCRIPTION */ /* */ /* This function sets up the specified vector with the new vector */ /* value. The previous vector value is returned to the caller. */ /* */ /* AUTHOR */ /* */ /* Barry Sellew, Accelerated Technology, Inc. */ /* */ /* CALLED BY */ /* */ /* Application */ /* TCC_Register_LISR Register LISR for vector */ /* */ /* CALLS */ /* */ /* None */ /* */ /* INPUTS */ /* */ /* vector Vector number to setup */ /* new Pointer to new assembly */ /* language ISR */ /* */ /* OUTPUTS */ /* */ /* old vector contents */ /* */ /* HISTORY */ /* */ /* NAME DATE REMARKS */ /* */ /* B. Sellew 01-19-1996 Created initial version 1.0 */ /* B. Sellew 01-22-1996 Verified version 1.0 */ /* */ /*************************************************************************/ @VOID *INT_Setup_Vector(INT vector, VOID *new) @{ .globl INT_Setup_Vector INT_Setup_Vector: @ @VOID *old_vector; /* Old interrupt vector */ @VOID **vector_table; /* Pointer to vector table */ @ @ /* Calculate the starting address of the actual vector table. */ @ vector_table = (VOID **) 0; @ @ /* Pickup the old interrupt vector. */ @ old_vector = vector_table[vector]; @ @ /* Setup the new interrupt vector. */ @ vector_table[vector] = new; @ @ /* Return the old interrupt vector. */ @ return(old_vector); @ MOV a1,#0 @ This routine is not applicable to @ THUMB, return a NULL pointer BX lr @ Return to caller @} /*************************************************************************/ /* */ /* FUNCTION */ /* */ /* INT_Retrieve_Shell */ /* */ /* DESCRIPTION */ /* */ /* This function retrieves the pointer to the shell interrupt */ /* service routine. The shell interrupt service routine calls */ /* the LISR dispatch routine. */ /* */ /* AUTHOR */ /* */ /* Barry Sellew, Accelerated Technology, Inc. */ /* */ /* CALLED BY */ /* */ /* TCC_Register_LISR Register LISR for vector */ /* */ /* CALLS */ /* */ /* None */ /* */ /* INPUTS */ /* */ /* vector Vector number to setup */ /* */ /* OUTPUTS */ /* */ /* shell pointer */ /* */ /* HISTORY */ /* */ /* NAME DATE REMARKS */ /* */ /* B. Sellew 01-19-1996 Created initial version 1.0 */ /* B. Sellew 01-22-1996 Verified version 1.0 */ /* */ /*************************************************************************/ @VOID *INT_Retrieve_Shell(INT vector) @{ .globl INT_Retrieve_Shell INT_Retrieve_Shell: @ @ /* Return the LISR Shell interrupt routine. */ @ return(INT_Vectors[vector]); @ MOV a1,#0 @ This routine is not applicable to @ THUMB, return a NULL pointer BX lr @ Return to caller @}