Skip to content

Commit

Permalink
modules: hal_nordic: Add support for new TWIM instances
Browse files Browse the repository at this point in the history
Add Kconfig and symbols for twim: 20-22, 30, 121, 130-137 instances

(cherry picked from commit 5685af0)

Original-Signed-off-by: Adam Wojasinski <adam.wojasinski@nordicsemi.no>
GitOrigin-RevId: 5685af0
Change-Id: Id2eafa125bf8c976c682d609839db06ee1b7c8df
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/4962271
Reviewed-by: Fabio Baltieri <fabiobaltieri@google.com>
Tested-by: Fabio Baltieri <fabiobaltieri@google.com>
Tested-by: Al Semjonovs <asemjonovs@google.com>
Commit-Queue: Fabio Baltieri <fabiobaltieri@google.com>
Reviewed-by: Al Semjonovs <asemjonovs@google.com>
  • Loading branch information
Adam Wojasinski authored and Chromeos LUCI committed Oct 23, 2023
1 parent f953405 commit 5a708f6
Show file tree
Hide file tree
Showing 3 changed files with 143 additions and 0 deletions.
65 changes: 65 additions & 0 deletions modules/hal_nordic/nrfx/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,71 @@ config NRFX_TWIM3
depends on $(dt_nodelabel_has_compat,i2c3,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM20
bool "TWIM20 driver instance"
depends on $(dt_nodelabel_has_compat,i2c20,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM21
bool "TWIM21 driver instance"
depends on $(dt_nodelabel_has_compat,i2c21,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM22
bool "TWIM22 driver instance"
depends on $(dt_nodelabel_has_compat,i2c22,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM30
bool "TWIM30 driver instance"
depends on $(dt_nodelabel_has_compat,i2c30,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM120
bool "TWIM120 driver instance"
depends on $(dt_nodelabel_has_compat,i2c120,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM130
bool "TWIM130 driver instance"
depends on $(dt_nodelabel_has_compat,i2c130,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM131
bool "TWIM131 driver instance"
depends on $(dt_nodelabel_has_compat,i2c131,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM132
bool "TWIM132 driver instance"
depends on $(dt_nodelabel_has_compat,i2c132,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM133
bool "TWIM133 driver instance"
depends on $(dt_nodelabel_has_compat,i2c133,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM134
bool "TWIM134 driver instance"
depends on $(dt_nodelabel_has_compat,i2c134,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM135
bool "TWIM135 driver instance"
depends on $(dt_nodelabel_has_compat,i2c135,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM136
bool "TWIM136 driver instance"
depends on $(dt_nodelabel_has_compat,i2c136,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIM137
bool "TWIM137 driver instance"
depends on $(dt_nodelabel_has_compat,i2c137,$(DT_COMPAT_NORDIC_NRF_TWIM))
select NRFX_TWIM

config NRFX_TWIS
bool

Expand Down
39 changes: 39 additions & 0 deletions modules/hal_nordic/nrfx/nrfx_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -452,6 +452,45 @@
#ifdef CONFIG_NRFX_TWIM3
#define NRFX_TWIM3_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM20
#define NRFX_TWIM20_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM21
#define NRFX_TWIM21_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM22
#define NRFX_TWIM22_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM30
#define NRFX_TWIM30_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM120
#define NRFX_TWIM120_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM130
#define NRFX_TWIM130_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM131
#define NRFX_TWIM131_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM132
#define NRFX_TWIM132_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM133
#define NRFX_TWIM133_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM134
#define NRFX_TWIM134_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM135
#define NRFX_TWIM135_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM136
#define NRFX_TWIM136_ENABLED 1
#endif
#ifdef CONFIG_NRFX_TWIM137
#define NRFX_TWIM137_ENABLED 1
#endif

#ifdef CONFIG_NRFX_TWIS
#define NRFX_TWIS_ENABLED 1
Expand Down
39 changes: 39 additions & 0 deletions soc/arm/nordic_nrf/Kconfig.peripherals
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,45 @@ config HAS_HW_NRF_TWIM2
config HAS_HW_NRF_TWIM3
def_bool $(dt_nodelabel_enabled_with_compat,i2c3,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM20
def_bool $(dt_nodelabel_enabled_with_compat,i2c20,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM21
def_bool $(dt_nodelabel_enabled_with_compat,i2c21,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM22
def_bool $(dt_nodelabel_enabled_with_compat,i2c22,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM30
def_bool $(dt_nodelabel_enabled_with_compat,i2c30,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM120
def_bool $(dt_nodelabel_enabled_with_compat,i2c120,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM130
def_bool $(dt_nodelabel_enabled_with_compat,i2c130,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM131
def_bool $(dt_nodelabel_enabled_with_compat,i2c131,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM132
def_bool $(dt_nodelabel_enabled_with_compat,i2c132,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM133
def_bool $(dt_nodelabel_enabled_with_compat,i2c133,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM134
def_bool $(dt_nodelabel_enabled_with_compat,i2c134,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM135
def_bool $(dt_nodelabel_enabled_with_compat,i2c135,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM136
def_bool $(dt_nodelabel_enabled_with_compat,i2c136,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIM137
def_bool $(dt_nodelabel_enabled_with_compat,i2c137,$(DT_COMPAT_NORDIC_NRF_TWIM))

config HAS_HW_NRF_TWIS0
def_bool $(dt_nodelabel_enabled_with_compat,i2c0,$(DT_COMPAT_NORDIC_NRF_TWIS))

Expand Down

0 comments on commit 5a708f6

Please sign in to comment.