git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@671 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
672fb83fa4
commit
65206b0880
|
@ -202,11 +202,16 @@ struct context {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This port function is implemented as inlined code for performance reasons.
|
* This port function is implemented as inlined code for performance reasons.
|
||||||
|
* @note The port code does not define a low poer mode, this macro has to be
|
||||||
|
* defined externally. The default implementation is a "nop", not a
|
||||||
|
* real low power mode.
|
||||||
*/
|
*/
|
||||||
#if ENABLE_WFI_IDLE != 0
|
#if ENABLE_WFI_IDLE != 0
|
||||||
|
#ifndef port_wait_for_interrupt
|
||||||
#define port_wait_for_interrupt() { \
|
#define port_wait_for_interrupt() { \
|
||||||
asm volatile ("wfi"); \
|
asm volatile ("nop"); \
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
#else
|
#else
|
||||||
#define port_wait_for_interrupt()
|
#define port_wait_for_interrupt()
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -22,7 +22,8 @@
|
||||||
* order to formally change state because this may change).
|
* order to formally change state because this may change).
|
||||||
* - <b>Serving Regular Interrupt</b>. Normal interrupt service code.
|
* - <b>Serving Regular Interrupt</b>. Normal interrupt service code.
|
||||||
* - <b>Serving Fast Interrupt</b>. Not present in this architecture.
|
* - <b>Serving Fast Interrupt</b>. Not present in this architecture.
|
||||||
* - <b>Serving Non-Maskable Interrupt</b>. Not present in this architecture.
|
* - <b>Serving Non-Maskable Interrupt</b>. The MSP430 has several non
|
||||||
|
* maskable interrupt sources that can be associated to this state.
|
||||||
* - <b>Halted</b>. Implemented as an infinite loop with interrupts disabled.
|
* - <b>Halted</b>. Implemented as an infinite loop with interrupts disabled.
|
||||||
*
|
*
|
||||||
* @section MSP430_NOTES The MSP430 port notes
|
* @section MSP430_NOTES The MSP430 port notes
|
||||||
|
@ -30,6 +31,12 @@
|
||||||
* enough stack space for interrupts in each thread stack. This can be done
|
* enough stack space for interrupts in each thread stack. This can be done
|
||||||
* by modifying the @p INT_REQUIRED_STACK macro into
|
* by modifying the @p INT_REQUIRED_STACK macro into
|
||||||
* <b>./ports/MSP430/chcore.h</b>.
|
* <b>./ports/MSP430/chcore.h</b>.
|
||||||
|
* - The state of the hardware multiplier is not saved in the thread context,
|
||||||
|
* make sure to use it in <b>Suspended</b> state (interrupts masked).
|
||||||
|
* - The port code does not define the switch to a low power mode for the
|
||||||
|
* idle thread because the MSP430 has several low power modes. You can
|
||||||
|
* select the proper low power mode for you application by defining the
|
||||||
|
* macro @p port_wait_for_interrupt().
|
||||||
*
|
*
|
||||||
* @ingroup Ports
|
* @ingroup Ports
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in New Issue