Zephyr Project API 4.1.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
cpuconf.h File Reference
#include <stdbool.h>
#include <stddef.h>
#include <zephyr/drivers/firmware/nrf_ironside/call.h>
#include <zephyr/toolchain/common.h>
#include <nrf.h>

Go to the source code of this file.

Macros

#define IRONSIDE_CALL_ID_CPUCONF_V0   2
 
#define IRONSIDE_CPUCONF_SERVICE_MSG_MAX_SIZE   (4 * sizeof(uint32_t))
 
#define IRONSIDE_CPUCONF_SERVICE_RETCODE_IDX   0
 
CPUCONF service error codes.
#define IRONSIDE_CPUCONF_ERROR_WRONG_CPU   (1)
 An invalid or unsupported processor ID was specified.
 
#define IRONSIDE_CPUCONF_ERROR_MESSAGE_TOO_LARGE   (2)
 The boot message is too large to fit in the buffer.
 

Enumerations

enum  {
  IRONSIDE_CPUCONF_SERVICE_CPU_PARAMS_IDX , IRONSIDE_CPUCONF_SERVICE_VECTOR_TABLE_IDX , IRONSIDE_CPUCONF_SERVICE_MSG_0 , IRONSIDE_CPUCONF_SERVICE_MSG_1 ,
  IRONSIDE_CPUCONF_SERVICE_MSG_2 , IRONSIDE_CPUCONF_SERVICE_MSG_3 , IRONSIDE_CPUCONF_NUM_ARGS
}
 

Functions

int ironside_cpuconf (NRF_PROCESSORID_Type cpu, const void *vector_table, bool cpu_wait, const uint8_t *msg, size_t msg_size)
 Boot a local domain CPU.
 

Macro Definition Documentation

◆ IRONSIDE_CALL_ID_CPUCONF_V0

#define IRONSIDE_CALL_ID_CPUCONF_V0   2

◆ IRONSIDE_CPUCONF_ERROR_MESSAGE_TOO_LARGE

#define IRONSIDE_CPUCONF_ERROR_MESSAGE_TOO_LARGE   (2)

The boot message is too large to fit in the buffer.

◆ IRONSIDE_CPUCONF_ERROR_WRONG_CPU

#define IRONSIDE_CPUCONF_ERROR_WRONG_CPU   (1)

An invalid or unsupported processor ID was specified.

◆ IRONSIDE_CPUCONF_SERVICE_MSG_MAX_SIZE

#define IRONSIDE_CPUCONF_SERVICE_MSG_MAX_SIZE   (4 * sizeof(uint32_t))

◆ IRONSIDE_CPUCONF_SERVICE_RETCODE_IDX

#define IRONSIDE_CPUCONF_SERVICE_RETCODE_IDX   0

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
IRONSIDE_CPUCONF_SERVICE_CPU_PARAMS_IDX 
IRONSIDE_CPUCONF_SERVICE_VECTOR_TABLE_IDX 
IRONSIDE_CPUCONF_SERVICE_MSG_0 
IRONSIDE_CPUCONF_SERVICE_MSG_1 
IRONSIDE_CPUCONF_SERVICE_MSG_2 
IRONSIDE_CPUCONF_SERVICE_MSG_3 
IRONSIDE_CPUCONF_NUM_ARGS 

Function Documentation

◆ ironside_cpuconf()

int ironside_cpuconf ( NRF_PROCESSORID_Type  cpu,
const void *  vector_table,
bool  cpu_wait,
const uint8_t msg,
size_t  msg_size 
)

Boot a local domain CPU.

Parameters
cpuThe CPU to be booted
vector_tablePointer to the vector table used to boot the CPU.
cpu_waitWhen this is true, the CPU will WAIT even if the CPU has clock.
msgA message that can be placed in radiocore's boot report.
msg_sizeSize of the message in bytes.
Note
cpu_wait is only intended to be enabled for debug purposes and it is only supported that a debugger resumes the CPU.
the call always sends IRONSIDE_CPUCONF_SERVICE_MSG_MAX_SIZE message bytes. If the given msg_size is less than that, the remaining bytes are set to zero.
Return values
0on success or if the CPU has already booted.
Positivenon-0 error status if reported by IRONside call.
-IRONSIDE_CPUCONF_ERROR_WRONG_CPUif cpu is unrecognized
-IRONSIDE_CPUCONF_ERROR_MESSAGE_TOO_LARGEif msg_size is greater than IRONSIDE_CPUCONF_SERVICE_MSG_MAX_SIZE.