1# SPDX-License-Identifier: Apache-2.0
2
3zephyr_syscall_header(${ZEPHYR_BASE}/include/zephyr/drivers/gpio.h)
4
5zephyr_library()
6
7zephyr_library_sources_ifdef(CONFIG_GPIO_AXP192     gpio_axp192.c)
8zephyr_library_sources_ifdef(CONFIG_GPIO_TELINK_B91 gpio_b91.c)
9zephyr_library_sources_ifdef(CONFIG_GPIO_INFINEON_CAT1 gpio_ifx_cat1.c)
10zephyr_library_sources_ifdef(CONFIG_GPIO_CC13XX_CC26XX gpio_cc13xx_cc26xx.c)
11zephyr_library_sources_ifdef(CONFIG_GPIO_CC32XX     gpio_cc32xx.c)
12zephyr_library_sources_ifdef(CONFIG_GPIO_CMSDK_AHB  gpio_cmsdk_ahb.c)
13zephyr_library_sources_ifdef(CONFIG_GPIO_DW         gpio_dw.c)
14zephyr_library_sources_ifdef(CONFIG_GPIO_ESP32      gpio_esp32.c)
15zephyr_library_sources_ifdef(CONFIG_GPIO_SIFIVE     gpio_sifive.c)
16zephyr_library_sources_ifdef(CONFIG_GPIO_GECKO      gpio_gecko.c)
17zephyr_library_sources_ifdef(CONFIG_GPIO_IMX        gpio_imx.c)
18zephyr_library_sources_ifdef(CONFIG_GPIO_ITE_IT8XXX2 gpio_ite_it8xxx2.c)
19zephyr_library_sources_ifdef(CONFIG_GPIO_ITE_IT8XXX2_V2 gpio_ite_it8xxx2_v2.c)
20zephyr_library_sources_ifdef(CONFIG_GPIO_KSCAN_ITE_IT8XXX2 gpio_kscan_ite_it8xxx2.c)
21zephyr_library_sources_ifdef(CONFIG_GPIO_MCP23S17   gpio_mcp23s17.c)
22zephyr_library_sources_ifdef(CONFIG_GPIO_MCP23XXX   gpio_mcp23xxx.c)
23zephyr_library_sources_ifdef(CONFIG_GPIO_MCP23SXX   gpio_mcp23sxx.c)
24zephyr_library_sources_ifdef(CONFIG_GPIO_MCP230XX   gpio_mcp230xx.c)
25zephyr_library_sources_ifdef(CONFIG_GPIO_BD8LB600FS gpio_bd8lb600fs.c)
26zephyr_library_sources_ifdef(CONFIG_GPIO_MCUX       gpio_mcux.c)
27zephyr_library_sources_ifdef(CONFIG_GPIO_MCUX_IGPIO gpio_mcux_igpio.c)
28zephyr_library_sources_ifdef(CONFIG_GPIO_MCUX_LPC   gpio_mcux_lpc.c)
29zephyr_library_sources_ifdef(CONFIG_GPIO_MMIO32     gpio_mmio32.c)
30zephyr_library_sources_ifdef(CONFIG_GPIO_XEC        gpio_mchp_xec.c)
31zephyr_library_sources_ifdef(CONFIG_GPIO_NRFX       gpio_nrfx.c)
32zephyr_library_sources_ifdef(CONFIG_GPIO_PCA95XX    gpio_pca95xx.c)
33zephyr_library_sources_ifdef(CONFIG_GPIO_STM32      gpio_stm32.c)
34zephyr_library_sources_ifdef(CONFIG_GPIO_SAM0       gpio_sam0.c)
35zephyr_library_sources_ifdef(CONFIG_GPIO_SAM        gpio_sam.c)
36zephyr_library_sources_ifdef(CONFIG_GPIO_SAM4L      gpio_sam4l.c)
37zephyr_library_sources_ifdef(CONFIG_GPIO_SX1509B    gpio_sx1509b.c)
38zephyr_library_sources_ifdef(CONFIG_GPIO_INTEL      gpio_intel.c)
39zephyr_library_sources_ifdef(CONFIG_GPIO_STELLARIS  gpio_stellaris.c)
40zephyr_library_sources_ifdef(CONFIG_GPIO_RPI_PICO   gpio_rpi_pico.c)
41zephyr_library_sources_ifdef(CONFIG_GPIO_RV32M1     gpio_rv32m1.c)
42zephyr_library_sources_ifdef(CONFIG_GPIO_LMP90XXX   gpio_lmp90xxx.c)
43zephyr_library_sources_ifdef(CONFIG_GPIO_ADS114S0X  gpio_ads114s0x.c)
44zephyr_library_sources_ifdef(CONFIG_GPIO_LITEX      gpio_litex.c)
45zephyr_library_sources_ifdef(CONFIG_GPIO_LPC11U6X   gpio_lpc11u6x.c)
46zephyr_library_sources_ifdef(CONFIG_GPIO_XLNX_AXI   gpio_xlnx_axi.c)
47zephyr_library_sources_ifdef(CONFIG_GPIO_NPCX       gpio_npcx.c)
48zephyr_library_sources_ifdef(CONFIG_GPIO_EMUL       gpio_emul.c)
49zephyr_library_sources_ifdef(CONFIG_GPIO_PSOC6      gpio_psoc6.c)
50zephyr_library_sources_ifdef(CONFIG_GPIO_PCAL64XXA  gpio_pcal64xxa.c)
51zephyr_library_sources_ifdef(CONFIG_GPIO_EOS_S3     gpio_eos_s3.c)
52zephyr_library_sources_ifdef(CONFIG_GPIO_RCAR       gpio_rcar.c)
53zephyr_library_sources_ifdef(CONFIG_GPIO_CY8C95XX   gpio_cy8c95xx.c)
54zephyr_library_sources_ifdef(CONFIG_GPIO_SNPS_CREG  gpio_creg_gpio.c)
55zephyr_library_sources_ifdef(CONFIG_GPIO_STMPE1600  gpio_stmpe1600.c)
56zephyr_library_sources_ifdef(CONFIG_GPIO_XEC_V2     gpio_mchp_xec_v2.c)
57zephyr_library_sources_ifdef(CONFIG_GPIO_PCA953X    gpio_pca953x.c)
58zephyr_library_sources_ifdef(CONFIG_GPIO_PCF8574    gpio_pcf8574.c)
59zephyr_library_sources_ifdef(CONFIG_GPIO_FXL6408    gpio_fxl6408.c)
60zephyr_library_sources_ifdef(CONFIG_GPIO_ANDES_ATCGPIO100 gpio_andes_atcgpio100.c)
61zephyr_library_sources_ifdef(CONFIG_GPIO_NEORV32    gpio_neorv32.c)
62zephyr_library_sources_ifdef(CONFIG_GPIO_NCT38XX    gpio_nct38xx.c)
63zephyr_library_sources_ifdef(CONFIG_GPIO_NCT38XX    gpio_nct38xx_port.c)
64zephyr_library_sources_ifdef(CONFIG_GPIO_NCT38XX_ALERT  gpio_nct38xx_alert.c)
65zephyr_library_sources_ifdef(CONFIG_GPIO_TEST       gpio_test.c)
66zephyr_library_sources_ifdef(CONFIG_GPIO_GD32       gpio_gd32.c)
67zephyr_library_sources_ifdef(CONFIG_GPIO_XLNX_PS    gpio_xlnx_ps.c gpio_xlnx_ps_bank.c)
68zephyr_library_sources_ifdef(CONFIG_GPIO_SN74HC595  gpio_sn74hc595.c)
69zephyr_library_sources_ifdef(CONFIG_GPIO_MCHP_MSS       gpio_mchp_mss.c)
70zephyr_library_sources_ifdef(CONFIG_GPIO_SMARTBOND  gpio_smartbond.c)
71zephyr_library_sources_ifdef(CONFIG_GPIO_NXP_S32    gpio_nxp_s32.c)
72zephyr_library_sources_ifdef(CONFIG_GPIO_TCA6424A   gpio_tca6424a.c)
73zephyr_library_sources_ifdef(CONFIG_GPIO_SHELL      gpio_shell.c)
74zephyr_library_sources_ifdef(CONFIG_USERSPACE   gpio_handlers.c)
75zephyr_library_sources_ifdef(CONFIG_GPIO_XMC4XXX    gpio_xmc4xxx.c)
76zephyr_library_sources_ifdef(CONFIG_GPIO_NPM1300    gpio_npm1300.c)
77zephyr_library_sources_ifdef(CONFIG_GPIO_NPM6001    gpio_npm6001.c)
78zephyr_library_sources_ifdef(CONFIG_GPIO_RT1718S    gpio_rt1718s.c)
79zephyr_library_sources_ifdef(CONFIG_GPIO_RT1718S    gpio_rt1718s_port.c)
80zephyr_library_sources_ifdef(CONFIG_GPIO_NUMICRO    gpio_numicro.c)
81zephyr_library_sources_ifdef(CONFIG_GPIO_HOGS       gpio_hogs.c)
82zephyr_library_sources_ifdef(CONFIG_GPIO_NUMAKER    gpio_numaker.c)
83zephyr_library_sources_ifdef(CONFIG_GPIO_EFINIX_SAPPHIRE    gpio_efinix_sapphire.c)
84zephyr_library_sources_ifdef(CONFIG_GPIO_DAVINCI    gpio_davinci.c)
85zephyr_library_sources_ifdef(CONFIG_GPIO_SEDI    gpio_sedi.c)
86zephyr_library_sources_ifdef(CONFIG_GPIO_ALTERA_PIO gpio_altera_pio.c)
87
88if (CONFIG_GPIO_EMUL_SDL)
89  zephyr_library_sources(gpio_emul_sdl.c)
90  if (CONFIG_NATIVE_APPLICATION)
91    zephyr_library_sources(gpio_emul_sdl_bottom.c)
92  else()
93    target_sources(native_simulator INTERFACE gpio_emul_sdl_bottom.c)
94  endif()
95endif()
96
97if(CONFIG_GPIO_SC18IM704)
98  zephyr_library_include_directories(${ZEPHYR_BASE}/drivers)
99  zephyr_library_sources(gpio_sc18im704.c)
100endif()
101