irq_enable() can be directly called from relevant irq config function
and thus voids the necessity to store the IRQ number, saving some
memory.
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
There is no such thing as CAVS DMA IP block, the DMA IP block found on
CAVS based chips is made with DesignWare one.
This will help to centralize DW based DMA device into one driver.
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Change to display RSSI and SNR values of the received data.
This change helps to test LoRa's communication distance and
communication quality.
Signed-off-by: Kwon Tae-young <tykwon@m2i.co.kr>
The sx1276_rx_done() function supports RSSI and SNR.
Change to support RSSI and SNR through sx1276_lora_recv() function.
Signed-off-by: Kwon Tae-young <tykwon@m2i.co.kr>
The RF2XX driver not always sent ACK when a RX frame requests. This
happen because RF2XX transceiver asserts TRX_END interrupt after
confirm that the FCS is valid. The driver can now decode the frame
but in parallel the radio still processing the ACK frame. This will
sync the radio FSM state to ensure that ACK will be send.
Fixes#21659
Signed-off-by: Gerson Fernando Budke <nandojve@gmail.com>
Use f-strings instead of .format() to make the code easier to read,
especially for long multiline strings.
f-strings were added in Python 3.6, which Zephyr requires now.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
Adds this commit, needed to avoid a false positive warning when running
pylint on genrest.py:
The KconfigCheck test in check_compliance.py uses
scripts/kconfig/kconfiglib.py from Zephyr, and nothing else needs
Kconfiglib to be installed from PyPI either.
Installing the old 10.30.0 version of Kconfiglib makes pylint
generate a warning-turned-error for genrest.py, because it uses a
the suppress_traceback parameter to Kconfig.__init__(), which was
added later.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
So far shell transport was initialized early before any k_poll events
and signals. transport_evt_handler() was passed as callback to transport
initializer and could be executed right away. This was true for example
with shell_uart when it enabled interrupts on RX and there were already
some bytes to read. As a result executed transport_evt_handler() is
operating on uninitialized k_poll signals.
Address this race condition by simply initializing shell transport when
everything is ready for processing data, i.e. on the end of shell
instance initialization.
Signed-off-by: Marcin Niestroj <m.niestroj@grinn-global.com>
Since the various delegates have different data types for their
parameters, this makes the call into this macro a little simpler
(alleviating the need for each call to know how it'll be handed off
down the chain).
Signed-off-by: Erik Johnson <erik.johnson@nimbelink.com>
Initialize function has to fail when a call to get entropy fails.
TinyCrypt prng_init relies on a proper entropy data, so we need to
check if the driver return it properly.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Propagate driver error when getting entropy data when calling a
cryptographically secure random generator.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Remove soc/arm/st_stm32/stm32YY/flash_registers.h files.
Change register accesses in stm32 flash drivers to use FLASH_TypeDef
from modules/hal/stm32/stm32cube/stm32YYxx/soc/stm32xxxxxx.h.
Fixes#16235
Signed-off-by: Sarvesh Patkar <psarvesh314@gmail.com>
In order to better handle incoming data, wait() should return
the # of sockets with data returned by poll().
Based on this new return value, we can call mqtt_input() in a
smarter way.
Signed-off-by: Michael Scott <mike@foundries.io>
Now that mqtt_live() can send an EAGAIN message meaning: no ping
was generated, let's handle that in process_mqtt_and_sleep() by
skipping the call to mqtt_input() since no data will be expected.
Signed-off-by: Michael Scott <mike@foundries.io>
Users of mqtt_live() have no idea when it actually sends a ping.
As a result it's very hard to know when to use mqtt_input() to
process the incoming PINGACK.
Instead of returning a 0 result when a ping isn't generated in
mqtt_live(), let's return -EAGAIN.
Signed-off-by: Michael Scott <mike@foundries.io>
SMI TX is different than other controller features in that it does not
necessarily imply any software changes; whether SMI TX is supported
may be simply a matter of hardware calibration. This change supports
using the same software on chips that do or do not support SMI TX
depending on calibration.
Signed-off-by: Wolfgang Puffitsch <wopu@demant.com>
usb-device.h must be included only if CONFIG_USB_UART_CONSOLE is
defined, otherwise it is not used and will pull a lot of usb code.
Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
This patch introduces the periph to/from memory dma transfer
define new values for dma cells on client side
Signed-off-by: Francois Ramu <francois.ramu@st.com>
when DMA IP is enabled on stm32 series,
the heap size must be configured to large value
because of dma channels configuration.
Signed-off-by: Francois Ramu <francois.ramu@st.com>
This patches defines constants from dma registers
depending on the dma configuration of the stm32 soc
Some devices have 6 or 7 or 8 dma channels per dma instance
Signed-off-by: Francois Ramu <francois.ramu@st.com>
This checks if the DMA controller supports or not
the memory-to-memory transfers. For DMA Version1,
in the stm32f2xx, stm32f4xx, stm32f7xx series,
only DMA instance 2 is able to transfer mem-to-mem.
For other series, with DMA Version2, there is no such a limitation.
Signed-off-by: Francois Ramu <francois.ramu@st.com>
Overlooked dependency in commit 97de99adca ("console: kconfig: Have
CONSOLE_{GETCHAR,GETLINE} depend on UART_CONSOLE"). CONSOLE_GETCHAR and
CONSOLE_GETLINE select CONSOLE_HANDLER, which selects
UART_INTERRUPT_DRIVEN, which depends on SERIAL_SUPPORT_INTERRUPT.
Fixed some selects with unsatisfied dependencies in CI.
(CONSOLE_HANDLER also depends on SERIAL, but it's redundant, since it
already depends on UART_CONSOLE, which depends on SERIAL. This is
simplified in https://github.com/zephyrproject-rtos/zephyr/pull/22116.)
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
The samd20 does not have hardware support for controlling the SS pin.
Declare a cs-gpio to be able to use the SS pin for samd20 xplained pro
board.
Signed-off-by: Sean Nyekjaer <sean@geanix.com>
This fixes a problem which appeared after bossac version was downgraded
to 1.7 which no longer accepts the -o/--offset parameter. Now the offset
is fed to bossac executable only if it's explicitly provided and not by
default.
Signed-off-by: Kuba Sanak <contact@kuba.fyi>
'type: path' was added to edtlib for completeness in commit 23a5b4963b
("dts: edtlib: Add 'type: path' for path references"). gen_defines.py
crashes if it's ever used though, because it gets confused for a
'type: phandle-array'.
Ignore 'type: path' properties in gen_defines.py, like how
'type: phandle' and 'type: phandles' are currently ignored too.
(Note that gen_defines.py is only one possible user of edtlib.)
Fixes: #22197
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
Adafruit Feather M0 and Adafruit Trinket M0 boards aren't set up
to use their defined flash partition table to generate the 0x2000
flash offset for code. This should be enabled by default as the
boards ship with a write-protected bootloader and code should be
flashed where it expected by default.
Signed-off-by: Kuba Sanak <contact@kuba.fyi>
Check with 'const:' that #address-cells is 1 and #size-cells is 0. That
way other values will get flagged by edtlib.
Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
dtc is only used for static analysis (producing warnings) of the
DeviceTree sources. This means that valid Zephyr firmware can sanely
be built without it.
For some users, for instance Windows users that are not permitted to
use Chocolatey, installing dtc is problematic and installing it is not
worth the DT warnings that it provides.
To make using Zephyr easier for these users we make using DTC
recommended and opt-out, instead of mandatory.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
Fix#22188
Introduce config option to disable automatic acknowledge via
virtual wires on response to eSPI host suspend and reset warnings.
This will give the opportunity for eSPI slave systems that need to
perform preparations before reset or suspend.
Signed-off-by: Jose Alberto Meza <jose.a.meza.arellano@intel.com>
Introduce a new counter API function for reading the current counter
value (counter_get_value()) and deprecate the former counter_read() in
favor of this.
Update all drivers and calling code to match the new counter API.
The previous counter driver API function for reading the current value
of the counter (counter_read()) did not support indicating whether the
read suceeded. This is fine for counters internal to the SoC where the
read always succeeds but insufficient for external counters (e.g. I2C
or SPI slaves).
Fixes#21846.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>