Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

boards: creating a pinmux library for pinmux source files #38608

Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions boards/arc/hsdk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,7 @@
#
# SPDX-License-Identifier: Apache-2.0
#

zephyr_sources_ifdef(CONFIG_PINMUX_HSDK pinmux.c)
if(CONFIG_PINMUX_HSDK)
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/adafruit_feather_m0_basic_proto/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just one comment: why do we need to name the library in this case? Is name relevant? The board pinmux.c files are not part of the pinmux driver/library, they are board related files that setup pinmux at system init.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that depends on how we want to solve this issue.

If creating a common library for pinmux functionality, then the best is to have a known name so that we can refer to the same library when appending files to it from different folders.

zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/adafruit_itsybitsy_m4_express/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/adafruit_trinket_m0/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/arduino_nano_33_iot/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/arduino_zero/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/atsamd20_xpro/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/atsamd21_xpro/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright (c) 2018 Bryan O'Donoghue
# SPDX-License-Identifier: Apache-2.0
if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/atsame54_xpro/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright (c) 2018 Bryan O'Donoghue
# SPDX-License-Identifier: Apache-2.0
if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/atsamr21_xpro/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Copyright (c) 2019 Benjamin Valentin
# SPDX-License-Identifier: Apache-2.0
if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
8 changes: 4 additions & 4 deletions boards/arm/cc3220sf_launchxl/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: Apache-2.0

zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

zephyr_library()
zephyr_library_sources(
pinmux.c
dbghdr.c
)
zephyr_library_sources(dbghdr.c)
8 changes: 4 additions & 4 deletions boards/arm/cc3235sf_launchxl/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: Apache-2.0

zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

zephyr_library()
zephyr_library_sources(
pinmux.c
dbghdr.c
)
zephyr_library_sources(dbghdr.c)
2 changes: 1 addition & 1 deletion boards/arm/colibri_imx7d_m4/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/frdm_k22f/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
#

if(CONFIG_PINMUX_MCUX)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/frdm_k64f/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_MCUX)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/frdm_k82f/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_MCUX)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/frdm_kl25z/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_MCUX)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/frdm_kw41z/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-License-Identifier: Apache-2.0

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/hexiwear_k64/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-License-Identifier: Apache-2.0

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/hexiwear_kw40z/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-License-Identifier: Apache-2.0

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/ip_k66f/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_MCUX)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/lpcxpresso54114/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
#

if(CONFIG_PINMUX_MCUX_LPC)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/lpcxpresso55s16/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
#

if(CONFIG_PINMUX_MCUX_LPC)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/lpcxpresso55s28/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
#

if(CONFIG_PINMUX_MCUX_LPC)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/lpcxpresso55s69/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#

if(CONFIG_PINMUX_MCUX_LPC)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()

Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mec1501modular_assy6885/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

if(DEFINED ENV{EVERGLADES_SPI_GEN})
Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mec15xxevb_assy6853/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

if(DEFINED ENV{EVERGLADES_SPI_GEN})
Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mec172xevb_assy6906/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

if(DEFINED ENV{MEC172X_SPI_GEN})
Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mec2016evb_assy6797/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimx8mm_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1010_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1015_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1020_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1024_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1050_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

if (CONFIG_DISPLAY)
Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1060_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

if (CONFIG_DISPLAY)
Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1064_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)

if (CONFIG_DISPLAY)
Expand Down
2 changes: 1 addition & 1 deletion boards/arm/mimxrt1170_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mimxrt685_evk/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/mm_feather/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
zephyr_sources_ifdef(CONFIG_BOOT_FLEXSPI_NOR flexspi_nor_config.c)
zephyr_sources_ifdef(CONFIG_DEVICE_CONFIGURATION_DATA mmfeather_sdram_ini_dcd.c)
2 changes: 1 addition & 1 deletion boards/arm/mm_swiftio/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
zephyr_sources_ifdef(CONFIG_BOOT_FLEXSPI_NOR flexspi_nor_config.c)
zephyr_sources_ifdef(CONFIG_DEVICE_CONFIGURATION_DATA mmswiftio_sdram_ini_dcd.c)
2 changes: 1 addition & 1 deletion boards/arm/mps2_an385/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# SPDX-License-Identifier: Apache-2.0

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
zephyr_library_include_directories(${ZEPHYR_BASE}/drivers)
2 changes: 1 addition & 1 deletion boards/arm/mps2_an521/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
zephyr_library_include_directories(${ZEPHYR_BASE}/drivers)

Expand Down
2 changes: 1 addition & 1 deletion boards/arm/pico_pi_m4/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
#
# SPDX-License-Identifier: Apache-2.0
#
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/sam4e_xpro/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/sam_e70_xplained/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/sam_v71_xult/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@
# SPDX-License-Identifier: Apache-2.0
#

zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
2 changes: 1 addition & 1 deletion boards/arm/seeeduino_xiao/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/serpente/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX_SAM0)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
2 changes: 1 addition & 1 deletion boards/arm/stm32g0316_disco/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

if(CONFIG_PINMUX)
zephyr_library()
zephyr_library_named(pinmux)
zephyr_library_sources(pinmux.c)
endif()
Loading