If the users configures this option in devicetree, ie,
```
&uicr {
nfct-pins-as-gpios;
};
```
CMake will inject the HAL-specific CONFIG_NFCT_PINS_AS_GPIOS definition,
so that the necessary operations are performed during system init.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Usage of application level for device drivers needs to be avoided. Also
introduced a new init level, with default to 90 as other dependencies of
USB-C run at priority 80.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
In a first place, hardcoding priorities like this is a bad idea, but
this patch just moves the device to late POST_KERNEL stage, as
APPLICATION level should be avoided for device drivers.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
There's no need to use APPLICATION level. In case of the IPM console
test, priorities have been adjusted to make sure sender/receiver are
initialized in the correct order.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
There's no need to use APPLICATION level. Also create a custom init
level that runs late in the process (depends e.g. on SPI which runs at
high priority level, 70).
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Convert the driver to a dt-based device. Also update Kconfig so that it
depends on the right compatible being enabled, initialize in POST_KERNEL
(APPLICATION should not be used for devices) and remove one redundant
include.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
The device model was not used for anything useful, only to call some
init code. Change to SYS_INIT instead.
Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
Rework the can_dlc_to_bytes table lookup code in a way that allow the
compiler to guess the resulting output and somehow fix the build
warning:
zephyr/drivers/can/can_nxp_s32_canxl.c:757:9: warning:
'__builtin___memcpy_chk' forming offset [16, 71] is out of the bounds
[0, 16] of object 'frame' with type 'struct can_frame' [-Warray-bounds]
757 | memcpy(frame->data, msg_data.data, can_dlc_to_bytes(frame->dlc));
where the compiler detects that frame->data is 8 bytes long but
can_dlc_to_bytes could return more than that.
Can be reproduced with:
west build -p -b s32z270dc2_rtu1_r52 \
-T samples/net/sockets/can/sample.net.sockets.can.one_socket
Suggested-by: Martin Jäger <martin@libre.solar>
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
This reverts commit 3127d7b54c which
was forgotten when switching back to breathe from docleaf and causing
unecessary "here's a warning about something that's not actually
a warning" :)
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Include the nrf peripheral kconfig definitions for all simulated
nrf boards, not just for the nrf52_bsim.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
Doxygen gets confused by the macro expansion in
include/zephyr/xen/public/domctl.h as that is only defined if
CONFIG_ARM64=y, add a no-op expansion of that macro when building the
documention so it has something to work on.
Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
ESP32C3 LuatOS core is a dev board with esp32-c3.
It has similar functions to esp32c3 devkitm, but smaller in size.
Signed-off-by: YuLong Yao <feilongphone@gmail.com>
Instead of detecting that we are in a native/POSIX arch based
board by checking for each board specifically,
let checks for the architecture.
In that way other boards (like the upcoming nrf53_bsim ones)
will also work.
Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>