Commit graph

4522 commits

Author SHA1 Message Date
Daniel DeGrasse 46bed8896e soc: nxp: rw: add support for USBOTG controller
Add code to clock and release reset signal for USBOTG controller on
RW6xx SOC when USB is enabled, and add KConfig selection to indicate to
build system which USB controller this SOC uses.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-04-11 09:09:00 +02:00
Flavio Ceolin 8a63a0a563 intel_adsp: ipc: Fix policy state lock usage
IPC has inverted the usage of the state lock API.
In this API semantics, the get method disallow the policy of
using the given state, while the put() release this constraint.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-04-11 09:07:13 +02:00
Kai Vehmanen 7fee1bdd39 soc: intel_adsp: cavs: fix power_down documentation
Fix the inline documentation to match implementation. As IPFL is used,
the correct matching function is xthal_icache_region_lock().

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2024-04-10 15:55:21 +02:00
Kai Vehmanen 03057f33d4 soc: intel_adsp: ace: fix power_down documentation
Fix the inline documentation to match implementation. As IPFL is used,
the correct matching function is xthal_icache_region_lock().

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2024-04-10 15:55:21 +02:00
Grzegorz Swiderski 7d45f3c92a soc: nordic: Provide z_arm_platform_init at link time
Nordic SoCs use this hook to execute `SystemInit` as early as possible
after ARM core reset. Previously, `z_arm_platform_init` was defined as
assembly code, which would simply jump to the other function.

However, this extra code can be avoided by using `SystemInit` directly
in place of the `z_arm_platform_init` symbol (whenever it's undefined).
This is now done with a linker script containing a `PROVIDE` directive.

This saves 4 bytes of ROM (0-16 depending on alignment) and also makes
it possible to override `z_arm_platform_init` out of tree, if needed.

Signed-off-by: Grzegorz Swiderski <grzegorz.swiderski@nordicsemi.no>
2024-04-10 07:45:42 -04:00
Daniel Baluta a8fa742b18 soc: nxp: imx8: Fix Kconfig.defconfig.* filenames
We need to use correct SOC name when naming the Kconfig.defconfig*
files.

So we need the following changes:
	- mimx8mp -> mimx8ml8
	- mimx8mm -> imx8mm6
	- mimx8mn -> mimx8mn6
	- mimx8mq -> mimx8mq6

Then we also need to take care of qualifiers name. Standard notation
uses "_" instead of "."

e.g : Kconfig.defconfig.mimx8mp.a53 -> Kconfig.defconfig.mimx8ml8_a53

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2024-04-10 10:00:40 +02:00
Flavio Ceolin e85226fd1a soc/intel_adsp: ipc: Remove fragile device state check
Checking if the device state is locked is not correct, device runtime
put / get is no longer checking for it and the only place that was
locking device's state was the pm action callback and if the idea
was to protect some concurrent call, using it is not enough.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-04-09 20:11:48 +02:00
Flavio Ceolin 741bbaca6d soc/intel_adsp: ipc: Remove unnecessary device state lock
There is no needed to lock/unlock a device state in its pm action
callback. The power management subsystem should take care of
serialize these calls.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-04-09 20:11:48 +02:00
Tomasz Leman d5897a48aa ipc: intel_adsp: Ensure IPC completion before runtime idle
Prevent the system from entering runtime idle state during IPC
transactions until the HOST acknowledgment is received.

This patch modifies the IPC mechanism to:
- Lock the runtime idle state immediately after sending an IPC message
  to the HOST, preventing the system from entering a low-power state.
- Unlock the runtime idle state once the IPC transaction is acknowledged
  by the HOST, allowing the system to enter low-power states if
  conditions permit.

The changes ensure that the DSP does not enter a power state that could
interrupt the IPC communication process, maintaining the integrity of
the IPC state machine.

Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
2024-04-09 16:58:24 +02:00
Daniel Maslowski 50c24f17e3 soc: starfive: jh71xx: select 64BIT for SOC_JH7110
We get a 32bit binary otherwise.

Signed-off-by: Daniel Maslowski <info@orangecms.org>
2024-04-09 14:20:39 +02:00
Laurentiu Mihalcea 399c2cba65 nxp: imx8ulp: enable pinctrl
This commit enables pinctrl on i.MX8ULP. This includes:
	1) Adding `pinctrl_soc.h` header file.
	2) Adding DTS node for IOMUXC1, which is one of the
	IPs responsible for managing the 8ULP pads.
	3) Adding .dtsi with pin definitions. For now, only
	the LPUART7 pads are added to this file because this
	is going to be the only consummer for now.
	4) Modifying the `pinctrl_imx.c` driver to work for 8ULP.
	5) Enabling the `CONFIG_HAS_MCUX_IOMUXC`, which is a
	dependency of `CONFIG_PINCTRL_IMX`.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-04-09 11:06:14 +02:00
Nikodem Kastelik 6bce78937d soc: nordic: add nRF54 PWM HAS_HW & base addr validation
Add HAS_HW symbols for PWM instances
found on nRF54H20 and nRF54L15 devices.

Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
2024-04-09 11:05:46 +02:00
Marek Matej 2395f08d48 soc: espressif: esp32: simple boot support
Add simplistic booting method which allows to run
applications without the 2nd stage bootloader.

- introduce memory layout header file
- update and optimize default and mcuboot linker scripts
- remove building multiple binaries during the application build

Signed-off-by: Marek Matej <marek.matej@espressif.com>
2024-04-08 09:16:41 -04:00
Marek Matej 323f811c7c soc: espressif: esp32s2: simple boot support
Add simplistic booting method which allows to run
applications without the 2nd stage bootloader.

- introduce memory layout header file
- update and optimize default and mcuboot linker scripts
- remove building multiple binaries during the application build

Signed-off-by: Marek Matej <marek.matej@espressif.com>
2024-04-08 09:16:41 -04:00
Marek Matej 553238704f soc: espressif: esp32s3: simple boot support
Add simplistic booting method which allows to run
applications without the 2nd stage bootloader.

- introduce memory layout header file
- update and optimize default and mcuboot linker scripts
- remove building multiple binaries during the application build

Signed-off-by: Marek Matej <marek.matej@espressif.com>
2024-04-08 09:16:41 -04:00
Marek Matej f9008b5330 soc: espressif: esp32c3: simple boot support
Add simplistic booting method which allows to run
applications without the 2nd stage bootloader.

- introduce memory layout header file
- update and optimize default and mcuboot linker scripts
- remove building multiple binaries during the application build

Signed-off-by: Marek Matej <marek.matej@espressif.com>
2024-04-08 09:16:41 -04:00
Marek Matej 43e3088c2d soc: espressif: Simple boot support
Add simplistic booting method which allows to load without 2nd stage
bootloader.
Update common architecture loader to support all build scenarios.

- simple boot: using single binary application without bootloader
- mcuboot: zephyr port of MCUboot
- application: loaded by the MCUboot

Signed-off-by: Marek Matej <marek.matej@espressif.com>
2024-04-08 09:16:41 -04:00
Adam Berlinger e3c759e835 soc: st: add PM support for STM32H5
Single STOP mode level supported on STM32H5

Signed-off-by: Adam Berlinger <adam.berlinger@st.com>
2024-04-08 15:55:24 +03:00
Jose Alberto Meza 83c031556b soc: arm: microchip: mec172x: Add macro to get pin mux value
Add macro to read pin mux control value

Signed-off-by: Jose Alberto Meza <jose.a.meza.arellano@intel.com>
2024-04-05 23:47:32 +03:00
Filip Kokosinski ab84989a12 arch/riscv: remove the Kconfig.core file
This commit removes the `Kconfig.core` file. It's been largely unused, and
the only symbol it provides (`RISCV_CORE_E31`) overlaps with the SoC-layer
provided `SOC_SERIES_SIFIVE_FREEDOM_FE300`.

As of date, the only SoC that uses the E31 core in Zephyr is the FE310 SoC.

Signed-off-by: Filip Kokosinski <fkokosinski@antmicro.com>
2024-04-05 16:46:01 +03:00
Sylvio Alves ad12a06e2e soc: espressif: esp32c3: update to hal_espressif v5.1
Modify and reorganize SoC to meet updated hal.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
2024-04-05 13:39:53 +02:00
Sylvio Alves 561f31bb54 soc: espressif: esp32s3: update to hal_espressif v5.1
Modify and reorganize SoC to meet updated hal.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
2024-04-05 13:39:53 +02:00
Sylvio Alves 072ea896d7 soc: espressif: esp32s2: update to hal_espressif v5.1
Modify and reorganize SoC to meet updated hal.

Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2024-04-05 13:39:53 +02:00
Sylvio Alves e587249704 soc: espressif: esp32: update to hal_espressif v5.1
Modify and reorganize SoC to meet updated hal.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
2024-04-05 13:39:53 +02:00
Sylvio Alves e63ddb70b3 soc: espressif: common: update to hal_espressif v5.1
Modify and reorganize SoC to meet updated hal.

Signed-off-by: Lucas Tamborrino <lucas.tamborrino@espressif.com>
Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
2024-04-05 13:39:53 +02:00
Gerard Marull-Paretas 37f9958fea soc: nordic: nrf54h: set DMASEC for CCM030 if enabled
DMASEC is set to non-secure by default, which prevents CCM from
accessing secure memory. Change DMASEC to secure.

Signed-off-by: Gerard Marull-Paretas <gerard@teslabs.com>
2024-04-05 13:19:21 +02:00
Daniel DeGrasse b6477deb4a soc: nxp: rw: add reset code for LCDIC
Clear LCDIC reset signal at init when the LCDIC peripheral is enabled.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-04-04 23:59:37 +03:00
Georgios Vasilakis 7a8d454e22 soc: nordic: Refactor soc_secure.h
The soc_secure_* function are used by the non-secure application
to access hardware resources which are mapped as secure.
Using these functions for hardware resources mapped as non-secure
is missleading.

We have some soc_secure_* functions which read FICR values.
In nRF91 and nRF53 platforms this made sense since FICR
has hardware fixed mapping as secure.
For nRF54 though the FICR has hardware fixed mapping as non-secure.

This change refactors the soc_secure.h to exclude the functions
which read FICR values from being included when FICR is mapped as
non-secure.

Also updates the hwinfo and ieee802154 drivers to adjust to this change.

Signed-off-by: Georgios Vasilakis <georgios.vasilakis@nordicsemi.no>
2024-04-04 13:17:13 -05:00
Steven Chang e44c0987b9 driver: watchdog: prevent floating point usage
Prevent the use of floating point operations

Signed-off-by: Steven Chang <steven@ene.com.tw>
2024-04-03 21:12:17 +01:00
Daniel Baluta cffea52fa8 boards: nxp: Rename mimxrt685_evk to mimxrt685_evk_mimxrt685s_cm33
In preparation for adding AMP support for i.MX RT6xx family we need
to rename existing cm33 support files to more specific names.

e.g mimxrt685_evk.dts -> mimxrt685_evk_mimxrt685s_cm33.dts

This will allow us to later add support for Cadence DSP found on i.MX
RT6xx series.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2024-04-03 15:41:16 +01:00
Daniel Baluta 68a7057513 soc: nxp: imxrt: Prepare imxrt6xx soc for AMP support
imxrt6xx are dual core devices featuring an ARM Cortex-M33
core and an Cadence Xtensa HIFI4 Audio DSP.

Currently only m33 core is supported. In order to support
the Cadence DSP we need first to do some code-reorganization
for m33.

We start by moving all cm33 related code to its own directory
and introduce the cpuclusters property in soc.yml file.

Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
2024-04-03 15:41:16 +01:00
Iuliana Prodan 019b813a71 linker: nxp: add orphan linker section
Add missing linker section to avoid warning
about orphans when building with host compiler.

Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
2024-04-03 10:34:18 +02:00
Jimmy Zheng f80377bd4e soc: andestech: linker.ld: clarify usage of __rom_region_end/size
Clarify usage of __rom_region_end/size in XIP system.
When PMP is enabled, __rom_region_end should be padded to meet the
requirement of PMP entry, and the actual ROM region usage ends at
.last_section instead of __rom_region_end.

Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
2024-04-02 21:04:20 -04:00
Jimmy Zheng ed021551dc soc: andestech: linker.ld: fixed ROM padding issue
Updated ROM region padding to utilize LMA instead of location counter,
because the location counter has been assigned to 'RAM_BASE'.

Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
2024-04-02 21:04:20 -04:00
Jimmy Zheng abffe27edb soc: andestech: pma.c: include soc_v5.h
Add include header for CSR definition.

Signed-off-by: Jimmy Zheng <jimmyzhe@andestech.com>
2024-04-02 21:04:20 -04:00
Pieter De Gendt 5944fb38bf dts: arm: nxp: nxp_imx8ml_m7: Add ECSPI instances
Add device tree instances for ECSPI peripherals and update SoC code to
enable clocks.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
2024-04-02 21:03:47 -04:00
Mahesh Mahadevan a9fea59281 soc: nxp: Select the MFD Kconfig when LPFlexcomm is enabled
LPFlexcomm is a MFD device hence select this Kconfig whenever
it is enabled.
Remove the selection from the individual driver Kconfig files.

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2024-04-02 21:00:24 -04:00
Iuliana Prodan 1f55be8b42 nxp: imx8: change CONFIG_SOC_<name> to match the value
Change, for audio DSP and M7 cores, SOC_<name> to match
the exact soc name.
Update the board files accordingly.

These configs are used in SOF and NXP_HAL, so change
sha for these modules.

Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
2024-04-02 10:41:07 +03:00
Declan Snyder a7988f2986 soc: nxp: lpc55s69: Enable Sleep Mode
Enable sleep mode on LPC55S69 (corresponding to zephyr's runtime idle
mode). Add DT description and power api implementations.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-04-02 10:38:17 +03:00
Declan Snyder 2d83371818 soc: nxp: lpc55xxx: Remove duplicate INIT_PLL1
Remove duplicate definition of the INIT_PLL1 kconfig

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-04-02 10:38:17 +03:00
cyliang tw b95e29abd8 soc: nuvoton: numaker: disable DWT in Kconfig
Timing function need Cycle Count Register CYCCNT of DWT,
but Arm-Cortex-M23 only support DWT_CTRL, DWT_PCSR and DWT_COMP
& DWT_FUNCTION registers. It can't meet the requirement of timing
function, so to remove CPU_CORTEX_M_HAS_DWT.

Signed-off-by: cyliang tw <cyliang@nuvoton.com>
2024-04-01 18:20:49 +01:00
Francois Ramu 7291450151 soc: st: stm32 devices: SW JTAG port pins config with hw model V2
During the migration to Hw model V2 the PR #63495
was not fully reported.
This change is adding the support Serial Wire / JTAG port pins

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-04-01 11:05:17 +01:00
Flavio Ceolin 688fbb53ae intel_adsp: ace: Fix sparse error
Fixes the following errors when sparse (SCA) is enabled:

soc/intel/intel_adsp/ace/power.c:46:12: warning:
    cast removes address space '__cache' of expression
/soc/intel/intel_adsp/ace/power.c:48:9: warning:
    incorrect type in argument 1 (different address spaces)

Fixes #70725

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-03-29 17:20:57 -05:00
Francois Ramu d70e96ea96 soc: st: stm32 mcus setting the lptim clock source
Select the LPTIM clock source STM32_LPTIM_CLOCK to be
LSE or LSI depending on the DTS clocks property
of the stm32_lp_tick_source node.
This will also affect the SYS_CLOCK_TICKS_PER_SEC
depending on the lptim prescaler

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-03-29 11:15:27 +00:00
Hou Zhiqiang 5062c51c49 soc: mimx8m: set the UART devices RDC permission
Add SoC initialization to set the UART RDC permission in the early
phase, so that the it can be used by Zephyr on Cortex-A cores.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
2024-03-28 16:01:30 -05:00
Hou Zhiqiang 657e7edd96 soc: mimx8m: add MMU mapping for RDC MMIO
Add MMU mapping for RDC MMIO on i.MX8M SoCs.

Signed-off-by: Hou Zhiqiang <Zhiqiang.Hou@nxp.com>
2024-03-28 16:01:30 -05:00
Marcin Szymczyk 1de13cc96a soc: nordic: vpr: finish pending transactions before calling wfi
To minimize time the CPU spends when preparing for sleep, make sure
the pending transactions are finished before calling `wfi`.

Signed-off-by: Marcin Szymczyk <marcin.szymczyk@nordicsemi.no>
2024-03-28 14:47:40 +00:00
Daniel DeGrasse 5e241970f5 soc: nxp: rw: enable DMIC clock at boot
Enable DMIC clock at boot, so that RW DMIC IP will be useable by driver

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-03-28 09:44:25 +00:00
Laurentiu Mihalcea 9517639390 nxp: imx8ulp: change SOC name to MIMX8UD7
The SOC name `imx8ulp` has been just a placeholder until
support for the SOC's ADSP (since this is the only core
that's supported in Zephyr) could be added to the NXP HAL.
Now that the support has been added, to make use of it, the
SOC name `imx8ulp` has to be changed to `mimx8ud7`. As such,
this commit does the following:
	1) Introduces SOC part number configuration - needed
	by some HAL headers.
	2) Replaces all occurrences of `imx8ulp` (as the SOC
	name) with `mimx8ud7`.
	3) Enables `CONFIG_HAS_MCUX`.
	4) Aligns all `CONFIG_SOC_` configurations with the
	new SOC name.
	5) Updates SOF hash. This is needed to fix build issues
	caused by this name change. This is not done in a separate
	commit to preserve bisectability.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-03-28 09:41:15 +00:00
Daniel Leung b69d2486fe kernel: rename Z_KERNEL_STACK_BUFFER to K_KERNEL_STACK_BUFFER
Simple rename to align the kernel naming scheme. This is being
used throughout the tree, especially in the architecture code.
As this is not a private API internal to kernel, prefix it
appropriately with K_.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-03-27 19:27:10 -04:00
Raffael Rostagno b17712364c drivers: systimer: Removed mention to ESP32C3
Removed mention to C3 SoC, so files are not SoC specific. Ready for C6
integration.

Signed-off-by: Raffael Rostagno <raffael.rostagno@espressif.com>
2024-03-27 15:18:45 +00:00
Jamie McCrae fe8816f278 soc: renesas: rcar_gen3: Fix Kconfigs
Fixes Kconfigs to not use another SOC_SERIES Kconfig name

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-03-26 09:29:03 +00:00
Mahesh Mahadevan b0dbd9a87e soc: mcxnx4x: Add FlexSPI support
Add support for FlexSPI

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2024-03-25 18:40:14 -04:00
Jon Ringle c69986da4c soc: atmel: saml2x: Don't do a GCLK SWRST
Doing a `GCLK->CTRLA.bit.SWRST = 1` will cause boot chaining to hang.
Setting the CPU clock to run from OSCULP32K during initialization is
all that is needed.

Signed-off-by: Jon Ringle <jringle@gridpoint.com>
2024-03-25 16:19:08 +01:00
Mykola Kvach 5554fd17b6 soc: rcar_gen3: set correct NUM_IRQS for ARM64 R-Car Gen3 boards
Align number of interrupts for ARM64 R-Car Gen3 boards with
the documentation.

Signed-off-by: Mykola Kvach <mykola_kvach@epam.com>
2024-03-25 10:06:20 +00:00
Daniel Leung 6ea749de52 arch: rename arch_start_cpu() to arch_cpu_start()
Rename arch_start_cpu() to arch_cpu_start() so it belongs to
the "cpu" namespace.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2024-03-25 09:58:35 +00:00
Marcin Szkudlinski 3fde2c50c6 tracing: add intel ADSP memory window backend
This commits adds a tracing backend based on
Intel ADSP debug memory window

Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com>
2024-03-25 09:33:41 +01:00
Flavio Ceolin 6b9d01f995 intel_adsp/ace: power: No pending transaction before power gate
Issue an upstream read transaction through uncached memory to flush
out all pending transactions before power down the host domain.

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2024-03-22 21:29:33 -04:00
Declan Snyder 711375695e soc: nxp: rw: Support Reset cause setting
Support reset causes on RW SOC

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-22 15:58:03 -05:00
Torsten Rasmussen fd772f8e77 scripts: remove boards_legacy sub-folder from list_boards.py
Fixes: #69785

The boards_legacy sub-folder was temporarily introduce in collab-hwm
branch during porting to HWMv2.

This should have been removed before merging collab-hwm to main as it
prevent looking up boards in oot roots.

Removing the temporary sub-folder for HWMv2.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2024-03-22 11:51:58 +01:00
Erwan Gouriou 7a7abb7b18 soc: st: Set BUILD_WITH_TFM by default (when required)
CONFIG_BUILD_WITH_TFM should always be set when building a non
secure target.

Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
2024-03-22 09:23:30 +00:00
Erwan Gouriou 3a383aad6c boards: st: Clean up compiler related directives
Clean up early days TF-M development directives which are outdated today.
Factorize remaining CMake instructions in soc.

Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
2024-03-22 09:23:30 +00:00
Jamie McCrae f903052f42 soc: Move non-grouped qemu boards into qemu folder
For the 2 SoCs without a vendor, put them into a generic qemu
folder

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-03-22 00:56:51 +01:00
Jamie McCrae f103c82c31 boards/socs: Rename folders to have proper vendor prefix in
Replaces inaccurate or wrong vendor prefixes in board and soc
folder names with those from thr vendor prefix file

Signed-off-by: Jamie McCrae <jamie.mccrae@nordicsemi.no>
2024-03-22 00:56:51 +01:00
Torsten Rasmussen 4370847c75 soc: espressif: move core identifiers esp32 and esp32s3 to Kconfig.soc
Move the Kconfig symbols SOC_ESP32_PROCPU, SOC_ESP32_APPCPU,
SOC_ESP32S3_PROCPU, and SOC_ESP32S3_APPCPU.

The CPU cluster is defined in espessifc/soc.yml and should therefore
be available in the HWMv2 Kconfig.soc tree.

This will allow sysbuild to test for the CPU cluster when targeting
remote board for a build.

Update espressif boards accordingly.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
2024-03-21 15:24:47 +01:00
Marcin Szymczyk a994dc5a35 soc: nordic: vpr: remove enabling MSTATUS.MIE in boot time
Interrupts should not be enabled this early in boot time.
Driver initializations expect IRQs not to arrive when
setting up HW.
Remove enabling `MSTATUS.MIE` in `__start`.
It will be enabled when main thread is switched to,
as threads by default start with enabled `MSTATUS.MIE`.

Signed-off-by: Marcin Szymczyk <marcin.szymczyk@nordicsemi.no>
2024-03-21 14:09:27 +00:00
Marcin Szymczyk d248b7bf07 soc: nordic: vpr: add workaround for MSTATUS.MIE not waking VPR up
Due to HW issue, VPR needs to keep MSTATUS.MIE enabled during sleep.
Otherwise, interrupts will not wake it up.

Signed-off-by: Marcin Szymczyk <marcin.szymczyk@nordicsemi.no>
2024-03-21 14:30:15 +01:00
Declan Snyder a65ae89b9e soc: nxp: rw: Support MRT counter
Add DT entries and peripheral reset for MRT on RW.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-21 09:06:48 +01:00
Declan Snyder 241d41596b soc: nxp: rw: Support CTIMER
Add DT entries and clocking for CTIMER peripherals on RW61x.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-21 09:06:48 +01:00
Daniel DeGrasse 90a8ef11fe soc: nxp: rw: define Kconfigs for MEMC_MCUX_FLEXSPI code relocation
MEMC_MCUX_FLEXSPI depends on code relocation being enabled on parts that
XIP from the FlexSPI by default and requires a string describing the RAM
region to relocate code into. Add these Kconfigs to the RW SOC port.

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-03-20 19:08:06 +00:00
Daniel DeGrasse 9021ce82fc soc: nxp: rw: add support for reclocking flexspi
Add support for reclocking FlexSPI peripheral via flexspi_clock_set_freq
function

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-03-20 19:08:06 +00:00
Declan Snyder 2cb4550dc7 soc: rw: Support WWDT
Add DT entry and SOC code for watchdog

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-20 16:19:12 +00:00
Tomasz Leman 4ea52bdd12 soc: xtensa: intel: Update power status bitfields for LNL
This patch updates the power status register bitfield definitions in the
power management header for the Intel ADSP ACE 2.0 LNL platform.

Modifications include:
- Adjusting the 'ioxpgs' field from 4 bits to 2 bits.
- Adding a 'rsvd11' field with 2 bits to reflect reserved space.
- Changing the 'mlpgs' field from 2 bits to 1 bit.
- Updating the 'rsvd14' field from 1 bit to 2 bits for alignment.

These changes ensure that the power status register bitfields match the
latest hardware specification for the ACE 2.0 LNL SoC, which is crucial
for accurate power domain status monitoring.

Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
2024-03-19 14:54:29 +01:00
Tim Lin 9d9d1ff380 ITE: drivers/i2c/target: Remove hardware reset setting
In the interrupt pending routine, only the interrupt status needs to be
cleared at the end of the interrupt routine. There is no need to do a
hardware reset(HALT) to avoid clearing the next transfer interrupt when
the current transfer is completed.

Test: Testing this function does not cause I2C data/clk to get stuck on
the system platform.

Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
2024-03-19 07:56:19 -04:00
Magdalena Pastula 92f1b3ff96 modules: hal_nordic: nrfx: propagate new configs to nrfx
Add support for propagating SOC_NRF54LX_DISABLE_FICR_TRIMCNF and
SOC_NRF54LX_SKIP_GLITCHDETECTOR_DISABLE values to nrfx.

Signed-off-by: Magdalena Pastula <magdalena.pastula@nordicsemi.no>
2024-03-19 09:47:58 +01:00
Magdalena Pastula b0b4bc0517 soc: nordic: nrf54l: add two new Kconfig options
Add SOC_NRF54LX_DISABLE_FICR_TRIMCNF and
SOC_NRF54LX_SKIP_GLITCHDETECTOR_DISABLE config options.

Signed-off-by: Magdalena Pastula <magdalena.pastula@nordicsemi.no>
2024-03-19 09:47:58 +01:00
Declan Snyder ab7580046a soc: rw: Support I2C Flexcomms
Support I2C flexcomms by clocking in soc.c and adding DT header

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-19 09:47:35 +01:00
Andrzej Głąbek 4d16e5b7d9 soc: nordic: Remove support for nRF54H20 EngA
This was a preview revision of the SoC that will no longer
be supported.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2024-03-18 19:11:36 +00:00
Andrzej Głąbek 4011015fb4 soc: nordic: Add initial support for nRF54H20
Add Kconfig symbols that allow building for the nRF54H20 (not EngA) SoC.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2024-03-18 19:11:36 +00:00
Anas Nashif 1a55caf826 soc: esp32: make SCHED_CPU_MASK depend on SCHED_DUMB
Forcing SCHED_CPU_MASK without SCHED_DUMB results in a global warning
from Kconfig.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-03-18 16:46:40 +01:00
Tim Lin d89e8052da ITE: soc: it8xxx2: Add missing Kconfig file of it82302ax variant
Previous adjustments to hwmv2 lost this Kconfig file.

Test: west build -p always -b it82xx2_evb samples/hello_world
config BOARD_IT82XX2_EVB
   select SOC_IT82302_AX

Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
2024-03-15 18:27:26 -04:00
Kai Vehmanen 010f39a409 soc: intel_adsp_cavs: store PS when power gating secondary core
When non-primary core is powered down and restart with sequence of:
 - PM state set to SOFT_OFF
 - once target core is idle, cut power with soc_adsp_halt_cpu()
 - power up core again with k_smp_cpu_resume()

The execution will continue from stored DSP core context, but
will hit an assert in z_smp_cpu_mobile() as the PS.INTLEVEL
is zero.

Fix this issue by storing and restoring PS register in this flow.

Link: https://github.com/zephyrproject-rtos/zephyr/issues/70181
Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
2024-03-15 18:16:51 -04:00
Declan Snyder fa6e894e1d soc: nxp: rw: Clock SPI Flexcomms
Clock flexcomms if used as SPI

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-15 18:07:45 -04:00
Laurentiu Mihalcea 2f40474c14 nxp: imx8ulp: correct value of CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC
The core clock of 8ULP's HIFI4 DSP runs at 475.2MHz. As such,
correct the value of `CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC` to
reflect this.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-03-15 06:27:13 -04:00
Steven Chang 64b4a3fe08 drivers: pinctrl: initial device driver for ENE KB1200
Add pinctrl driver for ENE KB1200

Signed-off-by: Steven Chang <steven@ene.com.tw>
2024-03-15 09:39:48 +00:00
Steven Chang 388091a4af soc: kb1200 soc
Add support for ENE KB1200 SOC

Signed-off-by: Steven Chang <steven@ene.com.tw>
2024-03-15 09:39:48 +00:00
Jun Lin 0907aff2ae soc: npcx: workaround VCC1_RST hang issue for npcx9m7fb SoC
Apply the bypass for the issue "Possible Hang-Up After VCC1_RST Reset"
in the NPCX99nFB_Errata.

Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
2024-03-15 08:43:47 +00:00
Jun Lin 0bf4ec6d7b drivers: gpio: npcx: workaround both trigger issue for npcx9m7fb
Apply the workaround for the issue "MIWU Any Edge Trigger Condition" in
the NPCX99nFB_Errata.

Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
2024-03-15 08:43:47 +00:00
Jun Lin c2179bcef0 soc: npcx: add support for npcx9m7fb
Add new SoC npcx9m7fb support for npcx9 series.

Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
2024-03-15 08:43:47 +00:00
Serhiy Katsyuba 41b3c71586 drivers: dma: intel_adsp_hda: Fix L1 exit condition
Transition to a low power DMI L1 state should be allowed only after all
pending DMA channels transfers have started.

Signed-off-by: Serhiy Katsyuba <serhiy.katsyuba@intel.com>
2024-03-15 08:59:12 +01:00
Daniel DeGrasse d1444856c0 soc: nxp: imxrt: fix dependencies of NXP_IMXRT_BOOT_HEADER for RT11xx
Dependencies of NXP_IMXRT_BOOT_HEADER were set incorrectly for the
RT11xx series part when building a dual core image. The boot header
should be enabled by default for the primary M7 core, and always
disabled when MCUBOOT is used or the M4 core is targeted

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-03-15 08:51:24 +01:00
Jun Lin 6057a83060 drivers: entropy: npcx: add rng driver support
This commit add the rng driver support by using the npcx drgb API.

Signed-off-by: Jun Lin <CHLin56@nuvoton.com>
2024-03-14 18:14:04 +00:00
Andrzej Głąbek dde7c47e6a soc: nordic: Fix validation of base addresses
Use `DT_REG_HAS_IDX()` instead of `DT_NODE_EXISTS()` when checking
if for a given nodelabel the base address of the associated node
should be validated, so that the validation is performed only if
the base address is available. This prevents build failures in cases
like the os_mgmt_datetime test where the `rtc` nodelabel is used for
an emulated RTC.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2024-03-14 11:03:27 -05:00
Daniel DeGrasse fcbf03a2dc soc: nxp: imxrt: correct FCB offset for iMXRT1011 SOC to 0x400
Unlike the remainder of the RT10xx series, the RT1011 SOC requires that
the flash configuration block be placed at an offset of 0x400 bytes,
instead of the start of the flash.

Fixes #70090

Signed-off-by: Daniel DeGrasse <daniel.degrasse@nxp.com>
2024-03-14 09:33:43 +01:00
Mahesh Mahadevan f93e37e84b soc: mcxn947: Add support for NXP MCXN947
Add initial support for NXP MCXN947 SoC

Signed-off-by: Emilio Benavente <emilio.benavente@nxp.com>
Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2024-03-13 22:38:46 +00:00
Declan Snyder 5f53afca0a soc: nxp: Add RW SOC Family
Add SOC definition for NXP RW Family

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2024-03-13 16:45:13 +00:00
Pratik Farkase 2b4ce8b3bb soc: starfive: jh71xx: add jh7110 soc support
These list of files add Kconfig support for
Starfive JH7110 SOC support.

Signed-off-by: Pratik Farkase <pratik.farkase@wsisweden.com>
2024-03-13 11:39:51 -05:00
Laurentiu Mihalcea f91065b7c9 nxp: adsp: enable usage of DCACHE API
With the transition to HWMv2, `CONFIG_CPU_HAS_DCACHE` is no
longer selected. This causes issues with Sound Open Firmware
since this configuration allows the usage of DCACHE-related
cache management operations. As such, to fix said issues,
select `CONFIG_CPU_HAS_DCACHE` on all NXP ADSP SOCs.

Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
2024-03-13 11:13:54 +00:00
Francois Ramu 031cdfa23f soc: arm: stm32 with USB Type-C dead battery disabled if needed
Check the driver configuration to disable
the USB Type-C dead battery, only if
 - a USB PD system is in place (the UCPD node is enabled)
 - or the user does not require USB PHY anyway

Signed-off-by: Francois Ramu <francois.ramu@st.com>
2024-03-13 11:09:44 +00:00
Flavio Ceolin 07426a800c intel_adsp/ace: power: Lock interruption when power gate fails
In case the core is not power gated, waiti will restore intlevel. In
this case we lock interruption after it.

In the bug scenario, the host starts streaming and via SOF APIs, keeps a
lock to prevent Zephyr from entering PM_STATE_RUNTIME_IDLE. During the
test case, host removes this block and core0 is allowed to enter IDLE
state.

When core0 enters power gated state, interrrupts are left enabled (so
the core can be woken up when something happens). This leaves a race
where suitably timed interrupt will actually block entry to power gated
state and k_cpu_idle() in power_gate_entry() will return. This is rare,
but happens often enough that the relatively short test plan run on SOF
pull-requests will trigger this case.

Fixes #69807

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2024-03-12 15:12:57 -05:00