zephyr/drivers/i2c
Peter Bigot 5f481bb042 drivers: rearrange for standard use of extern "C" in private headers
Consistently place C++ use of extern "C" after all include directives,
within the negative branch of _ASMLANGUAGE if used.

Only updated in headers that already had support for drivers built with
a C++ compiler.

The spi_dw.h file defines macros to declare functions, then uses them
within a file that may have out-of-tree overrides.  In this case we
leave the including file extern "C" active for backward compatibility.

Background from issue #17997:

Declarations that use C linkage should be placed within extern "C"
so the language linkage is correct when the header is included by
a C++ compiler.

Similarly #include directives should be outside the extern "C" to
ensure the language-specific default linkage is applied to any
declarations provided by the included header.

See: https://en.cppreference.com/w/cpp/language/language_linkage
Signed-off-by: Peter Bigot <peter.bigot@nordicsemi.no>
2019-08-13 18:00:31 +02:00
..
slave dts: Make instance defines consistent 2019-07-30 17:10:31 -05:00
CMakeLists.txt drivers: add CC13xx / CC26xx I2C driver 2019-05-21 15:37:22 -04:00
i2c-priv.h drivers: rearrange for standard use of extern "C" in private headers 2019-08-13 18:00:31 +02:00
i2c_bitbang.c drivers: i2c_bitbang: Do not use CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC 2019-07-24 15:10:02 +02:00
i2c_bitbang.h drivers: i2c_bitbang: Do not use CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC 2019-07-24 15:10:02 +02:00
i2c_cc13xx_cc26xx.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_cc32xx.c drivers: i2c_cc32xx: Get clock frequency from DTS 2019-07-24 15:10:02 +02:00
i2c_dw.c cleanup: include/: move misc/util.h to sys/util.h 2019-06-27 22:55:49 -04:00
i2c_dw.h cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_dw_port_x.h dts: Convert from DT_<COMPAT>_<INSTANCE>_<PROP> to DT_INST... 2019-06-14 08:02:15 -05:00
i2c_dw_registers.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
i2c_esp32.c cleanup: include/: move misc/util.h to sys/util.h 2019-06-27 22:55:49 -04:00
i2c_gecko.c dts: Make instance defines consistent 2019-07-30 17:10:31 -05:00
i2c_gpio.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_handlers.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_imx.c cleanup: include/: move misc/util.h to sys/util.h 2019-06-27 22:55:49 -04:00
i2c_ll_stm32.c drivers/i2c: Add support of stm32mp1 2019-07-31 05:59:16 -04:00
i2c_ll_stm32.h drivers/i2c: stm32: (FIX) add mutex to lock bus 2019-01-16 21:33:49 -05:00
i2c_ll_stm32_v1.c drivers: i2c: Add STM32F10X slave support 2019-07-31 05:40:19 -04:00
i2c_ll_stm32_v2.c i2c_ll_stm32_v2: Set slave_attached to false on slave unregister 2019-07-23 10:53:22 +02:00
i2c_mchp_xec.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_mcux.c cleanup: include/: move misc/util.h to sys/util.h 2019-06-27 22:55:49 -04:00
i2c_mcux_lpi2c.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_nios2.c cleanup: include/: move misc/util.h to sys/util.h 2019-06-27 22:55:49 -04:00
i2c_nrfx_twi.c drivers: i2c_nrfx_twi: Make use of NRFX_TWI_FLAG_SUSPEND 2019-07-29 13:10:30 +02:00
i2c_nrfx_twim.c drivers: nrf: Fix PM for TWI and TWIM in case of multi instance 2019-07-15 12:05:19 +02:00
i2c_qmsi.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_qmsi_ss.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_rv32m1_lpi2c.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_sam0.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
i2c_sam_twi.c cleanup: include/: move misc/__assert.h to sys/__assert.h 2019-06-27 22:55:49 -04:00
i2c_sam_twihs.c cleanup: include/: move misc/__assert.h to sys/__assert.h 2019-06-27 22:55:49 -04:00
i2c_sbcon.c dts: Make instance defines consistent 2019-07-30 17:10:31 -05:00
i2c_sifive.c cleanup: include/: move i2c.h to drivers/i2c.h 2019-06-27 22:55:49 -04:00
Kconfig docs: fix misspelling across the tree 2019-06-19 15:34:13 -05:00
Kconfig.cc13xx_cc26xx drivers: add CC13xx / CC26xx I2C driver 2019-05-21 15:37:22 -04:00
Kconfig.dw drivers/i2c/i2c_dw.c: rewrite for PCI(e) support 2019-05-21 08:23:22 -04:00
Kconfig.esp32 drivers/i2c: kconfig: Clean up I2C Kconfigs a bit 2018-08-02 19:12:52 +02:00
Kconfig.gpio drivers/i2c: kconfig: Clean up I2C Kconfigs a bit 2018-08-02 19:12:52 +02:00
Kconfig.nrfx drivers: nrfx: Add Kconfig checks for mutually exclusive peripherals 2019-03-05 13:38:18 -05:00
Kconfig.qmsi drivers: i2c: Select HAS_DTS_I2C in designware and qmsi drivers 2018-09-27 05:54:54 +05:30
Kconfig.sam0 drivers: i2c: Add SAM0 I2C driver 2019-05-07 08:42:24 -04:00
Kconfig.sbcon drivers/i2c: Add missing HAS_DTS_I2C to sbcon 2019-06-18 11:22:23 -04:00
Kconfig.sifive riscv: freedom: rename RISCV32 to RISCV 2019-08-08 00:29:24 -04:00
Kconfig.stm32 drivers/i2c: Add support of stm32mp1 2019-07-31 05:59:16 -04:00
Kconfig.xec drivers: i2c: mchp: Add I2C driver for MEC family 2019-05-08 15:02:26 -07:00