Add GPIO driver support for RZ/A3UL
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
Signed-off-by: Quang Le <quang.le.eb@bp.renesas.com>
Signed-off-by: Tien Nguyen <tien.nguyen.zg@renesas.com>
This is the initial commit to support UART driver for Renesas RZ/A3UL.
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
Signed-off-by: Tien Nguyen <tien.nguyen.zg@renesas.com>
This is the initial commit to support pinctrl driver for Renesas RZ/A3UL
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
Signed-off-by: Phuc Pham <phuc.pham.xr@bp.renesas.com>
RTC alarm is not supported by the driver for now due to the complexity it
would take to work around an hardware erratum. However, it is not possible
to prevent CONFIG_RTC_ALARM from being enabled at Kconfig level.
Modify the RTC driver such that enabling CONFIG_RTC_ALARM on STM32WB0
series does not cause build errors anymore.
Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
This include seems redundant as the driver builds fine without
it being included. When including soc.h it also causes issues
if one utilises the xenvm board when compiling. I suggest this
is removed completely as it seems unnecessary to create this
tight coupling to a specific SoC as the driver implementation
is describing itself perfectly well, and works well without
this soc.h-file.
Signed-off-by: Kent Stark Olsen <kent.stark.olsen@gmail.com>
The Xilinx xuartps driver fails to find the correct pre-scaler
parameters for the BAUDDIV and BAUDGEN registers. This fix
corrects that behaviour. The reason why it fails is due to
the stop condition for the search being ill-conditioned.
The stop condition is based on a baudrate error, and this
was chosen to be 3 percent. This would cause the parameter
search to stop too early returning ill-condotioned pre-scaler
parameters. This has been corrected by setting the stop condition
to be 3 permille instead of 3 percent. This change was tested
with an AMD Zynq Ultrascale+ MPSoC ZU3EG.
Signed-off-by: Kent Stark Olsen <kent.stark.olsen@gmail.com>
-Update the ETH_STM32_HAL menu configuration to conditionally
select USE_STM32_HAL_RIF if SOC_SERIES_STM32N6X is enabled.
-Align Ethernet descriptors to 32 bytes for STM32N6 to ensure
efficient DMA operations and improve cache line efficiency
and overall performance
-Add RISAF configuration in eth_initialize function for STM32N6
series to set up master and slave security attributes
for the Ethernet peripheral.
-Ensure RISAF configuration is done before enabling
the Ethernet clock to maintain proper security attributes.
Signed-off-by: IBEN EL HADJ MESSAOUD Marwa <marwa.ibenelhadjmessaoud-ext@st.com>
When converting raw values to integer and fractional (micro) parts, the
fractional part must be a signed integer.
- Fix prototypes where the fractional part was declared as unsigned.
- Fix comments which did not match the declared type.
Signed-off-by: Christophe Tournery <christophe.tournery@freshape.com>
Currently, siwx917 have three instances of uart: ulpuart, uart1 and
uart2. However:
- The other drivers on siwx91x (i2c, dma, i2s, etc...) rather use
'ulp', '0' and '1'.
- The reference manual also uses 'ulp', '0' and '1'.
The source of the confusion probably come from the clock driver in
WiseConnect which use clocks USART1 and USART2. However, this probably
not expected.
So, this patch renames uart1 and uart2 in uart0 and uart1. This change
also impacts the names of pins and the names of the clocks.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
WiseConnect documentation says:
Default value of 100 millisecs is used when
SL_WIFI_DEFAULT_ACTIVE_CHANNEL_SCAN_TIME is passed".
However, this is not true. Currently, DEFAULT_ACTIVE_CHANNEL_SCAN_TIME
is 0xFFFF and the scan time is set to 65 seconds.
To have the default scan time, the value '0' must be used.
Fortunately, '0' is also the value we get when the user does not specify
any default scan time. So the code can be simplified.
Signed-off-by: Jérôme Pouiller <jerome.pouiller@silabs.com>
Allow to configure the preemtiveness of the ethernet rx-thread independent
of the traffic-class queue.
Signed-off-by: Cla Mattia Galliard <cla-mattia.galliard@zuehlke.com>
In the case where more than a full tick was unannounced when
sys_clock_set_timeout() was called, the timer driver would
subtract it from the next timeout. However, this is already
done by the caller through the elapsed() function in timeout.c,
leading to the timer interrupt firing too early.
With this fix, SYS_CLOCK_TICKS_PER_SEC can be increased to the
full speed of the low frequency timer. The underlying sleeptimer
API must be called with a timeout of at least 1, and will if needed
increase the value to the minimum value required by the hardware.
Signed-off-by: Aksel Skauge Mellbye <aksel.mellbye@silabs.com>
The adsp_mm_save_context function was previously mapping memory without
explicitly setting write permissions, which could lead to a "store
prohibited" exception when attempting to write to the memory. This patch
adds the K_MEM_PERM_RW flag to the arch_mem_map call to ensure that the
memory is mapped with write permissions.
This change resolves the issue of accessing memory without the necessary
permissions, preventing potential exceptions and ensuring correct memory
operations. The issue was found when running the firmware on a
simulation with the MMU enabled.
Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
On Zephyr devices that has an Ethernet switch IC with the Zephyr device
connected to the CPU port, there aren't necessarilly any register to
check the link state on that port. If the check is kept on such devices,
Zephyr will believe the link disappears
CONFIG_ETH_STM32_CARRIER_CHECK_RX_IDLE_TIMEOUT_MS after last message was
received, until a new message is received. If the application tries to
send data while the link is considered gone, sending returns an error,
sometimes indicating that the interface is down.
It also seems conceptually meaningless to try determining link state on
such devices, since as long as both the microcontroller and the switch
IC is powered, the link should always be up.
This commit therefore introduces a new Kconfig to allow disabling the
entire checking of link state, so that on devices where there is no
relevant PHY register to read, the check can be disabled.
Signed-off-by: Ole Morten Haaland <omh@ixys.no>
Previously the net_linkaddr struct had pointers to the link address.
This is error prone and difficult to handle if cloning the packet as
those pointers can point to wrong place. Mitigate this issue by
allocating the space for link address in net_linkaddr struct. This will
increase the size of the net_pkt by 4 octets for IEEE 802.15.4 where the
link address length is 8, but there no increase in size if link address
is 6 bytes like in Ethernet/Wi-Fi.
Signed-off-by: Jukka Rissanen <jukka.rissanen@nordicsemi.no>
Due to historical reasons, there were two implementations of
R7FA4M1AB3CFM. However, the migration has been completed,
so the old one is now being removed.
Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
Instead of requiring the edata struct, just receive full-scale
parameter. This simplifies the decoding process for FIFO data
during streaming.
Signed-off-by: Luis Ubieda <luisf@croxel.com>
This reverts commit 99e7223a1c.
Breaks CI with the following compilation error in SPI.c:52:
error: 'SPI_MASTER' undeclared here (not in a function)
Failing tests (cc3220sf_launchxl/cc3220sf)
- sample.net.sockets.echo.offload.simplelink
- sample.net.sockets.http_get.offload.simplelink
- sample.net.wifi
Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
Zephyr GPIO drivers require the pin mask `struct gpio_driver_data` to be
the first element of the driver config. Reordering fixes failures in ASSERT
statements of the GPIO driver due to the base address being interpreted as
supported pin mask.
Signed-off-by: Mika Braunschweig <mika.braunschweig@siemens.com>
This is the initial commit to support PINCTRL driver for Renesas RZ/T2L
Signed-off-by: Nhut Nguyen <nhut.nguyen.kc@renesas.com>
Signed-off-by: Hieu Nguyen <hieu.nguyen.ym@bp.renesas.com>
- It seems that the mask variants of GPIO functions are not present in
the latest sdk, so replace those with direct register access.
Signed-off-by: Ayush Singh <ayush@beagleboard.org>
Introduces the Z_IS_TIMEOUT_RELATIVE() macro to help ensure that
checking for relative/absolute timeouts is consistent. Using this
macro also helps ensure that we get the correct behavior when using
32-bit timeouts (CONFIG_TIMEOUT_64BIT=n).
Signed-off-by: Peter Mitsis <peter.mitsis@intel.com>
Removed nested spinlock acquisition in i2c_xilinx_axi_write to prevent
ztest failures due to invalid spinlock usage.
Ensured spinlocks are not consecutively acquired without unlocking,
preventing potential deadlocks.
Signed-off-by: Ajay Neeli <ajay.neeli@amd.com>
This driver had some issues with interrupt-driven operation, which
manifested by the console breaking when enabling the Zephyr shell on the
kv260_r5 target for example. Fixed the following:
-Ensure device is fully hardware reset during initialization
-Changed poll_out to be more consistent with other drivers, i.e. only
wait for the UART to accept the character, not for it to be fully
transmitted.
-Added implementation for err_check function, as otherwise there was no
way to detect or clear the error interrupts enabled by irq_err_enable.
-Fixed logic for enabling/disabling interrupts. This should only be done
by explicit enable/disable calls, not as part of fifo_fill etc.
-This hardware does not produce interrupts for TX FIFO empty or RX FIFO
threshold when enabling them if the TX FIFO is already empty or RX FIFO
already contains data. When enabling interrupts in these cases, use a
timer to trigger a user callback to match the normal UART API usage,
similar to the xlnx_uartlite driver.
-Other minor cleanups to interrupt-driven functions.
Signed-off-by: Robert Hancock <robert.hancock@calian.com>
Reset the watchdog back to the initial state before enabling the
expiry interrupt. This prevents the watchdog expiring immediately if
there is a long gap between `wdt_install_timeout` and `wdt_setup`.
Signed-off-by: Jordan Yates <jordan@embeint.com>
- The current code will cause stall if some other subsystem (like subg)
also needs to manage pm states.
- So add a check to only re-enable suspend if it was disabled by PWM.
Signed-off-by: Ayush Singh <ayush@beagleboard.org>
Guard the neorv32_uart_config_get() function to avoid compilation warning
with CONFIG_UART_USE_RUNTIME_CONFIGURE=n.
Signed-off-by: Henrik Brix Andersen <henrik@brixandersen.dk>
There is a bug here clearly which is that if there is some error in the
transceive function, it returns without releasing the context.
This should be fixed by properly handling the errors with a context release
before returning.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>