Skip to content

Commit

Permalink
Fix formatting error
Browse files Browse the repository at this point in the history
Signed-off-by: Gaurav Aggarwal <[email protected]>
  • Loading branch information
aggarg committed Nov 15, 2021
1 parent 44fc137 commit 6ac9aae
Showing 1 changed file with 30 additions and 30 deletions.
60 changes: 30 additions & 30 deletions include/mpu_wrappers.h
Original file line number Diff line number Diff line change
Expand Up @@ -168,40 +168,40 @@

#else /* MPU_WRAPPERS_INCLUDED_FROM_API_FILE */

/* Ensure API functions go in the privileged execution section. */
/* Ensure API functions go in the privileged execution section. */
#define PRIVILEGED_FUNCTION __attribute__( ( section( "privileged_functions" ) ) )
#define PRIVILEGED_DATA __attribute__( ( section( "privileged_data" ) ) )
#define FREERTOS_SYSTEM_CALL __attribute__( ( section( "freertos_system_calls" ) ) )

/**
* @brief Calls the port specific code to raise the privilege.
*
* Sets xRunningPrivileged to pdFALSE if privilege was raised, else sets
* it to pdTRUE.
*/
#define xPortRaisePrivilege( xRunningPrivileged ) \
{ \
/* Check whether the processor is already privileged. */ \
xRunningPrivileged = portIS_PRIVILEGED(); \
\
/* If the processor is not already privileged, raise privilege. */ \
if( xRunningPrivileged == pdFALSE ) \
{ \
portRAISE_PRIVILEGE(); \
} \
}

/**
* @brief If xRunningPrivileged is not pdTRUE, calls the port specific
* code to reset the privilege, otherwise does nothing.
*/
#define vPortResetPrivilege( xRunningPrivileged ) \
{ \
if( xRunningPrivileged == pdFALSE ) \
{ \
portRESET_PRIVILEGE(); \
} \
}
/**
* @brief Calls the port specific code to raise the privilege.
*
* Sets xRunningPrivileged to pdFALSE if privilege was raised, else sets
* it to pdTRUE.
*/
#define xPortRaisePrivilege( xRunningPrivileged ) \
{ \
/* Check whether the processor is already privileged. */ \
xRunningPrivileged = portIS_PRIVILEGED(); \
\
/* If the processor is not already privileged, raise privilege. */ \
if( xRunningPrivileged == pdFALSE ) \
{ \
portRAISE_PRIVILEGE(); \
} \
}

/**
* @brief If xRunningPrivileged is not pdTRUE, calls the port specific
* code to reset the privilege, otherwise does nothing.
*/
#define vPortResetPrivilege( xRunningPrivileged ) \
{ \
if( xRunningPrivileged == pdFALSE ) \
{ \
portRESET_PRIVILEGE(); \
} \
}

#endif /* MPU_WRAPPERS_INCLUDED_FROM_API_FILE */

Expand Down

0 comments on commit 6ac9aae

Please sign in to comment.