Commit Graph

126 Commits

Author SHA1 Message Date
Jacob Wienecke
db63e563a9 drivers: memc: memc_nxp_flexram.h: Move to the public includes directory
Moved to: include/zephyr/drivers/misc/flexram/memc_nxp_flexram.h

This change makes it so that the .h file does not need to be pulled in
using the CMakeLists.txt file, and can be included like other public
includes.

Removes drivers/memc/memc_nxp_flexram.h

Add memc_nxp_flexram.h to include/zephyr/drivers/misc/flexram

Modify drivers/memc/memc_nxp_flexram.c to use the new include path.

Modifies the mimxrt1170 magic_addr sample to include the driver using
the new include path.

Modify the soc file: soc/nxp/imxrt/imxrt11xx/soc.c to use the new path.

Add relevant information to migration-guide-4.2.rst.

Signed-off-by: Jacob Wienecke <jacob.wienecke@nxp.com>
Co-authored-by: Declan Snyder <declan.snyder@nxp.com>
2025-04-26 10:55:09 +02:00
Kate Wang
587042d0df soc: nxp: imxrt: imxrt7xx: update rt7xx soc files
Add functions to configure MIPI_DSI power and clock when
MIPI_DSI is enabled.

Signed-off-by: Kate Wang <yumeng.wang@nxp.com>
2025-04-23 10:03:42 +02:00
Kesavan Yogeswaran
2882dab78c soc: nxp: Fix boot header placement when using lld
As well described in a previous PR [1], the GNU ld and LLVM lld linkers
treat the location counter (`.`) differently. lld always inteprets the
location counter as an absolute address whereas ld interprets it as an
offset from the start of the current object.

The NXP boot header linker script files use `.` assignment to specify an
offset within the rom_start region (ld-style). This causes lld to error
out since it interprets this as the location counter moving backwards.

To fix this, re-use the idea from the previous PR [1]:
replace `. = FOO` with `. += FOO - (. - __rom_start_address)`

This sets the location counter in a way that works with both ld and lld.

[1] https://github.com/zephyrproject-rtos/zephyr/pull/58315

Signed-off-by: Kesavan Yogeswaran <hikes@google.com>
2025-04-21 22:03:38 +02:00
Tim Wang
25fcfff154 soc: mimxrt1180: Add USB Device support
This was tested on the MIMXRT1180 EVK board

Signed-off-by: Tim Wang <tim.wang@nxp.com>
2025-04-01 11:52:09 +02:00
Xiaoli Ji
30da8b5aa8 soc: nxp: imxrt: imxrt118x: Update lpuart clock
1.Update lpuart0102 clock
2.Enable lpuart0304/0506/0708/0910/1112 clock

Signed-off-by: Xiaoli Ji <xiaoli.ji@nxp.com>
2025-03-31 19:50:27 -04:00
Zhaoxiang Jin
7ed7cd191a modules: hal_nxp: Move hal_nxp glue layer to zephyr repo
Move hal_nxp glue layer to zephyr repo.
Fix build warnings and failures caused by hal_nxp upgrade.
Update manifest to contain hal_nxp changes.

Signed-off-by: Zhaoxiang Jin <Zhaoxiang.Jin_1@nxp.com>
2025-03-26 16:26:34 +01:00
Hake Huang
1847b882a2 tests: ztest: enable ztest_no_yield for all in PM
if CONFIG_PM=y, board will enter low power,
which will cause problem for debugger.
So for ztest cases, we need enable this to avoid problem.
This used to apply to soc/platform level, now remove them.

Signed-off-by: Hake Huang <hake.huang@nxp.com>
2025-03-25 22:14:20 +01:00
Mahesh Mahadevan
bc5a60c812 boards: mimxrt700_evk: Fix USB failures
1. Update the USB clock init code
2. Pass a flag to USB HAL driver for cache
   management

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2025-03-25 00:32:14 +01:00
Declan Snyder
f013e20bc5 soc: nxp: Add missing resolve of system timer cfg
These socs were missing a config line to disable SYSTICK if the LPTMR is
configured for the system timer, similar to how other SOCs do this for
alternative system timers than systick.

This fixes build errors in the case where that lptmr kconfig is enabled.

Also, the LPTMR kconfig should be default no because it is a secondary
option for the system timer, being lower resolution than systick. This
also resolves build errors.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-03-20 17:14:28 +01:00
Mahesh Mahadevan
2b0912951b soc: imxrt5xx: Fix for USB Next
Fix to add support for USB Next Device Stack.

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2025-03-19 01:24:35 +01:00
Adrian Bieri
6f6a8d1a99 soc: nxp: imxrt: add config ADJUST_DCDC for RT10xx
There is a configuration of the DCDC in the clock_init for the RT10xx.
The RT11xx has a kconfig flag ADJUST_DCDC to enable or disable DCDC
adjust code. This flag is now also used for the RT10xx to be able to
enable or disable the DCDC adjust code.

Signed-off-by: Adrian Bieri <adrian.bieri@loepfe.com>
2025-03-18 16:44:50 +01:00
Raymond Lei
8199a247a6 boards/soc: nxp: MCXA, imxrt11xx: reconfigure clock source of lpspi
In spi loopback test, high bandrate is 16Mbps while some source of lpspi
are too low to support this bandrate. According the reference mannual,
to support 16Mbps, Input frequency at least should be 2*16MHz.
Update LPSPI input freq to maximum to get more accurate band rate
because band rate must be divisible by input freq.

Signed-off-by: Raymond Lei <raymond.lei@nxp.com>
2025-03-18 08:27:12 +01:00
Mahesh Mahadevan
8534873d9b soc: imxrt: No need for USB linker script on RT7XX
This is not needed for RT7XX

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2025-03-07 19:48:38 +01:00
Iuliana Prodan
6c3e83074c soc: nxp: imxrt700: Add i.MXRT700 HiFi1 DSP support
The i.MX RT700 has an ultra-low power Sense Subsystem
which includes an ARM Cortex-M33 and
Cadence Tensilica HiFi 1 DSP.

Here, we add support for the HiFi1 core.

Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
2025-03-07 19:42:36 +01:00
Iuliana Prodan
b3b6f7e248 soc: nxp: imxrt700: Add i.MXRT700 HiFi4 DSP support
The i.MX RT700 has a compute subsystem which includes
a primary ARM Cortex-M33 running at 325 MHz and
Cadence Tensilica HiFi4 DSP.

Here, we add support for the HiFi4 core.

Signed-off-by: Iuliana Prodan <iuliana.prodan@nxp.com>
2025-03-07 19:42:36 +01:00
Declan Snyder
d46c382950 drivers: ethernet: Remove deprecated eth_mcux
This driver was deprecated and must be removed by Zephyr version
4.1 according to lifecycle/release guidelines.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-02-26 22:04:26 +00:00
Declan Snyder
2ba6ba8494 drivers: nxp_enet: Re-add EXT RMII CLK config
This config was missed when converting from eth_mcux to nxp_enet driver,
re-add it and use new one instead of old one.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-02-26 22:04:26 +00:00
Fabio Baltieri
e10432afce soc: imxrt: drop the ADC_MCUX_12B1MSPS_SAR overrides
Drop the override conditions to ADC_MCUX_12B1MSPS_SAR for imxrt, the
current one causes the driver to be built when it does not have to and
are not needed anyway, and drop the HAS_MCUX_12B1MSPS_SAR option
entirely as it's not needed anymore.

Tested with:

west build -p -b teensy40 tests/lib/devicetree/api_ext

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
2025-02-26 22:03:36 +00:00
Tomas Galbicka
74b93ba47b soc: NXP RT1180 fix trdc permissions set multicore
This commits repairs calling function trdc_enable_all_access() only
when using build for standalone CM33 or CM7 core build.

For the multicore this function should be called only by CM33 core.

Signed-off-by: Tomas Galbicka <tomas.galbicka@nxp.com>
2025-02-22 07:12:32 +01:00
Benjamin Cabé
4586f6c1cf soc: nxp: fix spelling of "manual"
s/mannual/manual/

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-02-21 11:41:46 +00:00
Benjamin Cabé
b9da3e78e6 soc: nxp: fix spelling of "configuration"
s/condfiguration/configuration/

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-02-19 18:51:13 +01:00
Lucien Zhao
ba982a0f85 dts: arm: nxp: register ostimer for cm33_cpu0/1
register ostimer for cm33_cpu0/1
disable systick
set ostimer per sec 1000000 times

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-02-14 17:24:58 +01:00
Lucien Zhao
f378a8c7cc dts: arm: nxp: rt118x: add two usdhc instances
enable clock in soc.c
register two usdhc instances

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-02-14 16:21:11 +00:00
Tomas Galbicka
34575e84cd dts: soc: Add DTS MBOX and CM7 boot for NXP RT1180
This commit adds MBOX device tree entry for RT1180.

Adds functions to copy and boot CM7 core.

Adds MPU region for shared memory without caching.

Signed-off-by: Tomas Galbicka <tomas.galbicka@nxp.com>
2025-02-14 17:11:50 +01:00
Lucien Zhao
ef348187ae soc: nxp: imxrt: imxrt118x: change trdc permission getting strategy
When TRDC permission fails to be obtained, it does not recycle to
access ELE core to prevent blocking problems. The current practice
only generates a log warning alarm.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-02-14 06:56:55 +01:00
Benjamin Cabé
7da7818d4f Revert "soc: nxp: imxrt: imxrt118x: change trdc permission getting strategy"
This reverts commit e3538a3183 as it's
causing CI failures in main.

Signed-off-by: Benjamin Cabé <benjamin@zephyrproject.org>
2025-02-13 13:21:58 +01:00
Lucien Zhao
e3538a3183 soc: nxp: imxrt: imxrt118x: change trdc permission getting strategy
When TRDC permission fails to be obtained, it does not recycle to
access ELE core to prevent blocking problems. The current practice
only generates a log warning alarm.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-02-13 09:11:56 +01:00
Mahesh Mahadevan
9ae310b923 soc: nxp_mxrt7xx: Fix cache implementation for CPU0
This SoC has an external XCACHE controller for CPU0
instruction and data bus.
Add code to enable the data cache. Instruction cache
is already enabled by SystemInit.

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2025-02-13 01:14:20 +01:00
Yangbo Lu
26a59796ed soc: nxp: imxrt118x: add M7 MPU configuration
Added M7 MPU configuration.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
2025-02-11 22:03:48 +01:00
Declan Snyder
b83f8ed070 soc: nxp: Make clock init weak and global
Make clock init functions in SOC level weak and global so they can be
overriden by board/app level.

Ideally these should have been put at board level but for now just make
them weak so they can be overriden without breaking anything.

Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
2025-02-05 10:20:41 +01:00
Gediminas Sidlauskas
88c7a443f9 soc: nxp: imxrt: fixed relocated file name
Added .c ending to lpm_rt1064 file name.

Signed-off-by: Gediminas Sidlauskas <gediminas.sidlauskas@gmail.com>
2025-01-31 21:43:25 +01:00
Felix Schramek
9f2f4a4256 soc: add FlexSPI2 clock configuration in clock_init for rt11xx
The current soc clock_init only configures the FlexSPI1 interface and
not the FlexSPI2.

This Commit adds the clock configuration for the second FlexSPI
in case one boots from the FlexSPI2.

Signed-off-by: Felix Schramek <felix.schramek@gmail.com>
2025-01-31 21:42:56 +01:00
Mahesh Mahadevan
85bdab00de soc: mimxrt1180: Add USB support
This was tested on the MIMXRT1180 EVK board

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2025-01-30 18:29:33 +01:00
Lucien Zhao
5d87295350 soc: nxp: imxrt: select HAS_MCUX_FLEXCOMM Kconfig
lpi2c driver on RT700 depend on HAS_MCUX_FLEXCOMM

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-01-28 09:47:32 +01:00
Lucien Zhao
1034316a85 soc: nxp: imxrt: imxrt7xx: fix bug pincfg setting missed
A problem was discovered during development: the
electrical characteristics of the pins were not
set according to the device tree settings.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-01-27 21:03:26 +01:00
Ruijia Wang
8c9b226900 mcux: soc: rt1180 unmask reset event when rtwdog is using
RT1180 takes reset event mask feature which should be unmasked when
watch dog is enabled.

Signed-off-by: Ruijia Wang <ruijia.wang@nxp.com>
2025-01-25 20:07:05 +01:00
Andrej Butok
66df94b618 boards: mimxrt1180: fix MCUBoot build
- Fixes building of MCUBoot for mimxrt1180-evk.
- Disables RT Boot header for MCUBoot applications.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2025-01-24 22:09:30 +01:00
Adrian Bieri
03fa6a0c33 mcux: drivers: xbara: drop HAS_MCUX_XBARA config
The HAS_MCUX_XBARA is replaced by the DT_HAS_NXP_MCUX_XBAR_ENABLED

Signed-off-by: Adrian Bieri <adrian.bieri@loepfe.com>
2025-01-23 19:25:54 +01:00
Andrej Butok
5449fbbe37 soc: imxrt: add mimxrt1189 flashing configuration
- Adds a flash runner configuration for mimxrt1189,
  used for sysbuild multi-image projects.
- Avoid unwanted multiple erases and resets.

Signed-off-by: Andrej Butok <andrey.butok@nxp.com>
2025-01-20 11:16:34 +01:00
Mahesh Mahadevan
9f31feb6cf soc: imxrt118x: Use the External Cache driver for CM33
The CM33 has a XCACHE controller to manage the External
cache. Remove unused Kconfigs as we can use Zephyr API's
to manage the CM33 cache,

Signed-off-by: Mahesh Mahadevan <mahesh.mahadevan@nxp.com>
2025-01-15 22:57:41 +01:00
Lucien Zhao
a6f2a0fa8a soc: nxp: imxrt: imxrt7xx: add rt7xx soc files
add rt7xx files related to soc
support basic clock enablement
add common/Kconfig.xspi_xip file

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-01-14 17:56:53 +01:00
Lucien Zhao
19550c1746 soc: nxp: imxrt: imxrt118x: add lpspi clock and trdc configuration
add lpspi clock enablement code

DMA3/4 access different domain is controlled by TRDC, release all
the domain access permission for DMA3/4, and add privilege and secure
information in dma access request signal by DAC module

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-01-13 10:08:36 +01:00
Daniel DeGrasse
a7ad63c1d0 soc: nxp: imxrt: add CONFIG_SECOND_CORE_MCUX_LAUNCHER
Add CONFIG_SECOND_CORE_MCUX_LAUNCHER. This Kconfig is only enabled when
using sysbuild targeting the Cortex-M4 core on the RT11xx series, and
results in loading a minimal application to the Cortex-M7 core that
boots the Cortex-M4 core. This makes developing on the M4 core simpler,
as the user can now simply target the core with sysbuild enabled and
flashing the application will work as expected.

Signed-off-by: Daniel DeGrasse <daniel@degrasse.com>
2025-01-07 20:34:26 +01:00
Lucien Zhao
a101a4cdb2 soc: nxp: imxrt: imxrt118x: Remove cm7 core condition for CPU_HAS_ICACHE
Although I/DCACHE aren't included under cm33 architecture,
NXP design and integrate Code Cache/Sys Cache for cm33 to
speed up the core execution efficiency.
For the convenience of developers, we believe that software
developers can directly use Code/Sys Cache as arm's I/D Cache.

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2025-01-07 18:24:20 +01:00
Derek Snell
ed7c8285f5 soc: nxp: imxrt5xx: enable Flexcomm12 clock for SPI
Enable clock when using as SPI.

Signed-off-by: Derek Snell <derek.snell@nxp.com>
2025-01-07 15:57:50 +01:00
Benedikt Schmidt
d7574e5f44 soc: add DWARF v5 sections to linker scripts
Add the DWARF v5 sections to the linker scripts of
imx, imxrt, acp_6_0 and xtensa_sample_controller.

Signed-off-by: Benedikt Schmidt <benedikt.schmidt@embedded-solutions.at>
2024-12-20 12:36:46 +01:00
Valerio Setti
bc3baf096a boards|soc: remove selection of ENTROPY_GENERATOR
Now that MbedTLS is capable of automatically enabling
CONFIG_ENTROPY_GENERATOR (when available), we can remove forced
enablements in boards|soc deconfig files.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-12-19 17:53:37 +01:00
Valerio Setti
39068cc70e mbedtls: select ENTROPY_GENERATOR when a driver is available
This is based on the introduction of a helper Kconfig symbol in
"subsys/random/Kconfig" which is named CSPRNG_AVAILABLE. When this is
enabled it means that there is a "zephyr,entropy" property defined in the
device-tree, therefore Mbed TLS can select ENTROPY_GENERATOR to allow
the platform specific driver to be included into the build.

This commit also changes other locations where CSPRNG_ENABLED was used
moving it to CSPRNG_AVAILABLE in order to solve dependency loop
build failures.

Signed-off-by: Valerio Setti <vsetti@baylibre.com>
2024-12-19 17:53:37 +01:00
Lucien Zhao
08b8b160a9 dts: arm: nxp: add two i3c instances for RT1180
add i3c instances
enable i3c clock under soc folder

Signed-off-by: Lucien Zhao <lucien.zhao@nxp.com>
2024-12-18 01:01:37 +01:00
Raymond Lei
0db1c07bf0 soc: nxp: imxrt11xx: select CONFIG_HAS_MCUX_ADC_ETC
On NXP RT1170 SOC, ADC ETC exists but it can not be enabled because
of dependency on HAS_MCUX_ADC_ETC.
Also, ADC ETC should only work with ADC together, there is no use
case to run it standalone.
Fixes:#81466

Signed-off-by: Raymond Lei <raymond.lei@nxp.com>
2024-12-07 02:03:45 +01:00