Skip to content

Commit

Permalink
drivers: ambiq: Add dependencies to avoid showing to non-ambiq platforms
Browse files Browse the repository at this point in the history
Fixed the Kconfig.ambiq under i2c and spi so that they don't litter.

Signed-off-by: Hao Luo <[email protected]>
  • Loading branch information
AlessandroLuo authored and nashif committed Jun 27, 2024
1 parent 79a2e24 commit d1eea36
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion drivers/i2c/Kconfig.ambiq
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# SPDX-License-Identifier: Apache-2.0
#

config I2C_AMBIQ
menuconfig I2C_AMBIQ
bool "AMBIQ I2C driver"
default y
depends on DT_HAS_AMBIQ_I2C_ENABLED
Expand All @@ -14,6 +14,8 @@ config I2C_AMBIQ
help
Enable driver for Ambiq I2C.

if I2C_AMBIQ

config I2C_AMBIQ_DMA
bool "AMBIQ APOLLO I2C DMA Support"
help
Expand All @@ -24,3 +26,5 @@ config I2C_DMA_TCB_BUFFER_SIZE
default 1024
help
DMA Transfer Control Buffer size in words

endif # I2C_AMBIQ
6 changes: 5 additions & 1 deletion drivers/spi/Kconfig.ambiq
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# SPDX-License-Identifier: Apache-2.0
#

config SPI_AMBIQ
menuconfig SPI_AMBIQ
bool "AMBIQ SPI driver"
default y
depends on DT_HAS_AMBIQ_SPI_ENABLED
Expand All @@ -15,6 +15,8 @@ config SPI_AMBIQ
help
Enable driver for Ambiq SPI.

if SPI_AMBIQ

config SPI_AMBIQ_DMA
bool "AMBIQ APOLLO SPI DMA Support"
depends on SPI_AMBIQ
Expand All @@ -28,6 +30,8 @@ config SPI_DMA_TCB_BUFFER_SIZE
help
DMA Transfer Control Buffer size in words

endif # SPI_AMBIQ

config MSPI_AMBIQ
bool "AMBIQ MSPI driver"
default y
Expand Down

0 comments on commit d1eea36

Please sign in to comment.