git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@1958 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
1a9115dff3
commit
9ffa6324d4
|
@ -80,7 +80,7 @@ struct context {
|
||||||
* @details This code usually setup the context switching frame represented
|
* @details This code usually setup the context switching frame represented
|
||||||
* by an @p intctx structure.
|
* by an @p intctx structure.
|
||||||
*/
|
*/
|
||||||
#define SETUP_CONTEXT(workspace, wsize, pf, arg) { \
|
#define SETUP_CONTEXT(workspace, wsize, pf, arg) { \
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -113,9 +113,9 @@ struct context {
|
||||||
/**
|
/**
|
||||||
* @brief Computes the thread working area global size.
|
* @brief Computes the thread working area global size.
|
||||||
*/
|
*/
|
||||||
#define THD_WA_SIZE(n) STACK_ALIGN(sizeof(Thread) + \
|
#define THD_WA_SIZE(n) STACK_ALIGN(sizeof(Thread) + \
|
||||||
sizeof(struct intctx) + \
|
sizeof(struct intctx) + \
|
||||||
sizeof(struct extctx) + \
|
sizeof(struct extctx) + \
|
||||||
(n) + (INT_REQUIRED_STACK))
|
(n) + (INT_REQUIRED_STACK))
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -123,7 +123,7 @@ struct context {
|
||||||
* @details This macro is used to allocate a static thread working area
|
* @details This macro is used to allocate a static thread working area
|
||||||
* aligned as both position and size.
|
* aligned as both position and size.
|
||||||
*/
|
*/
|
||||||
#define WORKING_AREA(s, n) stkalign_t s[THD_WA_SIZE(n) / sizeof(stkalign_t)];
|
#define WORKING_AREA(s, n) stkalign_t s[THD_WA_SIZE(n) / sizeof(stkalign_t)]
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief IRQ prologue code.
|
* @brief IRQ prologue code.
|
||||||
|
|
|
@ -118,15 +118,15 @@ struct stm8_startctx {
|
||||||
* @details This code usually setup the context switching frame represented
|
* @details This code usually setup the context switching frame represented
|
||||||
* by an @p intctx structure.
|
* by an @p intctx structure.
|
||||||
*/
|
*/
|
||||||
#define SETUP_CONTEXT(workspace, wsize, pf, arg) { \
|
#define SETUP_CONTEXT(workspace, wsize, pf, arg) { \
|
||||||
struct stm8_startctx *scp; \
|
struct stm8_startctx *scp; \
|
||||||
scp = (struct stm8_startctx *)((uint8_t *)workspace + wsize - \
|
scp = (struct stm8_startctx *)((uint8_t *)workspace + wsize - \
|
||||||
sizeof(struct stm8_startctx)); \
|
sizeof(struct stm8_startctx)); \
|
||||||
scp->ts = _port_thread_start; \
|
scp->ts = _port_thread_start; \
|
||||||
scp->arg = arg; \
|
scp->arg = arg; \
|
||||||
scp->pc = (stm8func_t)pf; \
|
scp->pc = (stm8func_t)pf; \
|
||||||
scp->ret = (stm8func_t)chThdExit; \
|
scp->ret = (stm8func_t)chThdExit; \
|
||||||
tp->p_ctx.sp = (struct intctx *)scp; \
|
tp->p_ctx.sp = (struct intctx *)scp; \
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -159,9 +159,9 @@ struct stm8_startctx {
|
||||||
/**
|
/**
|
||||||
* @brief Computes the thread working area global size.
|
* @brief Computes the thread working area global size.
|
||||||
*/
|
*/
|
||||||
#define THD_WA_SIZE(n) STACK_ALIGN(sizeof(Thread) + \
|
#define THD_WA_SIZE(n) STACK_ALIGN(sizeof(Thread) + \
|
||||||
(sizeof(struct intctx) - 1) + \
|
(sizeof(struct intctx) - 1) + \
|
||||||
(sizeof(struct extctx) - 1) + \
|
(sizeof(struct extctx) - 1) + \
|
||||||
(n) + (INT_REQUIRED_STACK))
|
(n) + (INT_REQUIRED_STACK))
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -183,9 +183,9 @@ struct stm8_startctx {
|
||||||
* @details This macro must be inserted at the end of all IRQ handlers
|
* @details This macro must be inserted at the end of all IRQ handlers
|
||||||
* enabled to invoke system APIs.
|
* enabled to invoke system APIs.
|
||||||
*/
|
*/
|
||||||
#define PORT_IRQ_EPILOGUE() { \
|
#define PORT_IRQ_EPILOGUE() { \
|
||||||
if (chSchIsRescRequiredExI()) \
|
if (chSchIsRescRequiredExI()) \
|
||||||
chSchDoRescheduleI(); \
|
chSchDoRescheduleI(); \
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -60,6 +60,7 @@
|
||||||
|
|
||||||
*** 1.5.8 ***
|
*** 1.5.8 ***
|
||||||
- FIX: Fixed missing files from ST library zip file (bug 3006629).
|
- FIX: Fixed missing files from ST library zip file (bug 3006629).
|
||||||
|
- Formatting fixes to the port templates.
|
||||||
- Added notes about copyright assignment to the documentation. Fixed some
|
- Added notes about copyright assignment to the documentation. Fixed some
|
||||||
problems in the licensing FAQ page.
|
problems in the licensing FAQ page.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue