Zephyr API Documentation 4.0.0
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
init_function Union Reference

Initialization function for init entries. More...

#include <init.h>

Data Fields

int(* sys )(void)
 System initialization function.
 
int(* dev )(const struct device *dev)
 Device initialization function.
 

Detailed Description

Initialization function for init entries.

Init entries support both the system initialization and the device APIs. Each API has its own init function signature; hence, we have a union to cover both.

Field Documentation

◆ dev

int(* init_function::dev) (const struct device *dev)

Device initialization function.

Parameters
devDevice instance.
Return values
0On success
-errnoIf device initialization fails.

◆ sys

int(* init_function::sys) (void)

System initialization function.

Return values
0On success
-errnoIf init fails.

The documentation for this union was generated from the following file: