Skip to content
Permalink
Browse files

cleanup: include/: move i2c.h to drivers/i2c.h

move i2c.h to drivers/i2c.h and
create a shim for backward-compatibility.

No functional changes to the headers.
A warning in the shim can be controlled with CONFIG_COMPAT_INCLUDES.

Related to #16539

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
  • Loading branch information...
nashif committed Jun 25, 2019
1 parent f901e26 commit 8f692c7d38e61416d4fa1bcf32b04cae32ac29e0
Showing with 1,162 additions and 1,147 deletions.
  1. +1 −1 boards/x86/galileo/pinmux.c
  2. +1 −1 drivers/audio/tlv320dac310x.c
  3. +1 −1 drivers/crypto/crypto_ataes132a.c
  4. +1 −1 drivers/crypto/crypto_ataes132a_priv.h
  5. +1 −1 drivers/display/grove_lcd_rgb.c
  6. +1 −1 drivers/display/ssd1306.c
  7. +1 −1 drivers/ethernet/eth_sam_gmac.c
  8. +1 −1 drivers/gpio/gpio_pcal9535a.c
  9. +1 −1 drivers/gpio/gpio_pcal9535a.h
  10. +1 −1 drivers/gpio/gpio_sx1509b.c
  11. +1 −1 drivers/i2c/i2c-priv.h
  12. +1 −1 drivers/i2c/i2c_bitbang.c
  13. +1 −1 drivers/i2c/i2c_cc13xx_cc26xx.c
  14. +1 −1 drivers/i2c/i2c_cc32xx.c
  15. +1 −1 drivers/i2c/i2c_dw.c
  16. +1 −1 drivers/i2c/i2c_dw.h
  17. +1 −1 drivers/i2c/i2c_esp32.c
  18. +1 −1 drivers/i2c/i2c_gecko.c
  19. +1 −1 drivers/i2c/i2c_gpio.c
  20. +1 −1 drivers/i2c/i2c_handlers.c
  21. +1 −1 drivers/i2c/i2c_imx.c
  22. +1 −1 drivers/i2c/i2c_ll_stm32.c
  23. +1 −1 drivers/i2c/i2c_ll_stm32_v1.c
  24. +1 −1 drivers/i2c/i2c_ll_stm32_v2.c
  25. +1 −1 drivers/i2c/i2c_mchp_xec.c
  26. +1 −1 drivers/i2c/i2c_mcux.c
  27. +1 −1 drivers/i2c/i2c_mcux_lpi2c.c
  28. +1 −1 drivers/i2c/i2c_nios2.c
  29. +1 −1 drivers/i2c/i2c_nrfx_twi.c
  30. +1 −1 drivers/i2c/i2c_nrfx_twim.c
  31. +1 −1 drivers/i2c/i2c_qmsi.c
  32. +1 −1 drivers/i2c/i2c_qmsi_ss.c
  33. +1 −1 drivers/i2c/i2c_rv32m1_lpi2c.c
  34. +1 −1 drivers/i2c/i2c_sam0.c
  35. +1 −1 drivers/i2c/i2c_sam_twi.c
  36. +1 −1 drivers/i2c/i2c_sam_twihs.c
  37. +1 −1 drivers/i2c/i2c_sbcon.c
  38. +1 −1 drivers/i2c/i2c_sifive.c
  39. +1 −1 drivers/i2c/slave/eeprom_slave.c
  40. +1 −1 drivers/led/ht16k33.c
  41. +1 −1 drivers/led/lp3943.c
  42. +1 −1 drivers/led/lp5562.c
  43. +1 −1 drivers/led/pca9633.c
  44. +1 −1 drivers/pwm/pwm_pca9685.c
  45. +1 −1 drivers/pwm/pwm_pca9685.h
  46. +1 −1 drivers/sensor/adt7420/adt7420.c
  47. +1 −1 drivers/sensor/adt7420/adt7420_trigger.c
  48. +1 −1 drivers/sensor/adxl372/adxl372.c
  49. +1 −1 drivers/sensor/adxl372/adxl372.h
  50. +1 −1 drivers/sensor/ak8975/ak8975.c
  51. +1 −1 drivers/sensor/amg88xx/amg88xx.c
  52. +1 −1 drivers/sensor/amg88xx/amg88xx_trigger.c
  53. +1 −1 drivers/sensor/ams_iAQcore/iAQcore.c
  54. +1 −1 drivers/sensor/apds9960/apds9960.c
  55. +1 −1 drivers/sensor/apds9960/apds9960_trigger.c
  56. +1 −1 drivers/sensor/bma280/bma280.c
  57. +1 −1 drivers/sensor/bma280/bma280_trigger.c
  58. +1 −1 drivers/sensor/bmc150_magn/bmc150_magn.h
  59. +1 −1 drivers/sensor/bme280/bme280.c
  60. +1 −1 drivers/sensor/bme680/bme680.c
  61. +1 −1 drivers/sensor/bmg160/bmg160.h
  62. +1 −1 drivers/sensor/bmm150/bmm150.h
  63. +1 −1 drivers/sensor/ccs811/ccs811.c
  64. +1 −1 drivers/sensor/ens210/ens210.c
  65. +1 −1 drivers/sensor/fxas21002/fxas21002.h
  66. +1 −1 drivers/sensor/fxos8700/fxos8700.h
  67. +1 −1 drivers/sensor/hmc5883l/hmc5883l.c
  68. +1 −1 drivers/sensor/hmc5883l/hmc5883l_trigger.c
  69. +1 −1 drivers/sensor/hp206c/hp206c.c
  70. +1 −1 drivers/sensor/hts221/hts221.c
  71. +1 −1 drivers/sensor/hts221/hts221_trigger.c
  72. +1 −1 drivers/sensor/isl29035/isl29035.c
  73. +1 −1 drivers/sensor/isl29035/isl29035_trigger.c
  74. +1 −1 drivers/sensor/lis2dh/lis2dh.h
  75. +1 −1 drivers/sensor/lis2ds12/lis2ds12_i2c.c
  76. +1 −1 drivers/sensor/lis2ds12/lis2ds12_trigger.c
  77. +1 −1 drivers/sensor/lis2dw12/lis2dw12.c
  78. +1 −1 drivers/sensor/lis2dw12/lis2dw12_i2c.c
  79. +1 −1 drivers/sensor/lis2mdl/lis2mdl.h
  80. +1 −1 drivers/sensor/lis3mdl/lis3mdl.c
  81. +1 −1 drivers/sensor/lis3mdl/lis3mdl_trigger.c
  82. +1 −1 drivers/sensor/lps22hb/lps22hb.h
  83. +1 −1 drivers/sensor/lps25hb/lps25hb.h
  84. +1 −1 drivers/sensor/lsm303dlhc_magn/lsm303dlhc_magn.c
  85. +1 −1 drivers/sensor/lsm6ds0/lsm6ds0.h
  86. +1 −1 drivers/sensor/lsm6dsl/lsm6dsl_i2c.c
  87. +1 −1 drivers/sensor/lsm6dsl/lsm6dsl_shub.c
  88. +1 −1 drivers/sensor/lsm6dsl/lsm6dsl_trigger.c
  89. +1 −1 drivers/sensor/lsm9ds0_gyro/lsm9ds0_gyro.h
  90. +1 −1 drivers/sensor/lsm9ds0_gyro/lsm9ds0_gyro_trigger.c
  91. +1 −1 drivers/sensor/lsm9ds0_mfd/lsm9ds0_mfd.c
  92. +1 −1 drivers/sensor/max30101/max30101.h
  93. +1 −1 drivers/sensor/max44009/max44009.c
  94. +1 −1 drivers/sensor/mcp9808/mcp9808.c
  95. +1 −1 drivers/sensor/mcp9808/mcp9808_trigger.c
  96. +1 −1 drivers/sensor/mpu6050/mpu6050.c
  97. +1 −1 drivers/sensor/mpu6050/mpu6050_trigger.c
  98. +1 −1 drivers/sensor/ms5837/ms5837.h
  99. +1 −1 drivers/sensor/sht3xd/sht3xd.c
  100. +1 −1 drivers/sensor/sx9500/sx9500.c
  101. +1 −1 drivers/sensor/sx9500/sx9500_trigger.c
  102. +1 −1 drivers/sensor/th02/th02.c
  103. +1 −1 drivers/sensor/ti_hdc/ti_hdc.c
  104. +1 −1 drivers/sensor/tmp007/tmp007.c
  105. +1 −1 drivers/sensor/tmp112/tmp112.c
  106. +1 −1 drivers/sensor/vl53l0x/vl53l0x.c
  107. +1 −1 drivers/sensor/vl53l0x/vl53l0x_platform.c
  108. +1,040 −0 include/drivers/i2c.h
  109. +4 −1,029 include/i2c.h
  110. +1 −1 samples/boards/96b_argonkey/sensors/src/main.c
  111. +1 −1 samples/display/grove_display/src/main.c
  112. +1 −1 samples/drivers/current_sensing/src/main.c
  113. +1 −1 samples/drivers/i2c_fujitsu_fram/src/main.c
  114. +1 −1 samples/drivers/i2c_scanner/src/main.c
  115. +1 −1 samples/sensor/bmg160/src/main.c
  116. +1 −1 tests/boards/altera_max10/i2c_master/src/i2c_master.c
  117. +1 −1 tests/boards/intel_s1000_crb/src/i2c_test.c
  118. +1 −1 tests/drivers/i2c/i2c_api/src/test_i2c.c
  119. +1 −1 tests/drivers/i2c/i2c_slave_api/common/i2c_virtual.c
  120. +1 −1 tests/drivers/i2c/i2c_slave_api/src/main.c
@@ -12,7 +12,7 @@
#include <init.h>

#include <pinmux.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <drivers/gpio.h>
#include <pwm.h>

@@ -9,7 +9,7 @@
#include <misc/util.h>

#include <device.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <drivers/gpio.h>

#include <audio/codec.h>
@@ -8,7 +8,7 @@
#include <kernel.h>
#include <string.h>
#include <device.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <assert.h>
#include <crypto/cipher.h>

@@ -8,7 +8,7 @@
#ifndef ZEPHYR_DRIVERS_CRYPTO_CRYPTO_ATAES132A_PRIV_H_
#define ZEPHYR_DRIVERS_CRYPTO_CRYPTO_ATAES132A_PRIV_H_

#include <i2c.h>
#include <drivers/i2c.h>
#include <kernel.h>
#include <misc/util.h>

@@ -9,7 +9,7 @@
#include <init.h>
#include <stdbool.h>

#include <i2c.h>
#include <drivers/i2c.h>
#include <display/grove_lcd.h>
#include <misc/util.h>

@@ -12,7 +12,7 @@ LOG_MODULE_REGISTER(ssd1306);
#include <device.h>
#include <init.h>
#include <drivers/gpio.h>
#include <i2c.h>
#include <drivers/i2c.h>

#include "ssd1306_regs.h"
#include <display/cfb.h>
@@ -34,7 +34,7 @@ LOG_MODULE_REGISTER(LOG_MODULE_NAME);
#include <net/net_if.h>
#include <net/ethernet.h>
#include <ethernet/eth_stats.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <soc.h>
#include "phy_sam_gmac.h"
#include "eth_sam_gmac_priv.h"
@@ -15,7 +15,7 @@
#include <init.h>
#include <misc/util.h>
#include <drivers/gpio.h>
#include <i2c.h>
#include <drivers/i2c.h>

#include "gpio_pcal9535a.h"

@@ -14,7 +14,7 @@
#include <kernel.h>

#include <drivers/gpio.h>
#include <i2c.h>
#include <drivers/i2c.h>

#ifdef __cplusplus
extern "C" {
@@ -10,7 +10,7 @@
#include <device.h>
#include <init.h>
#include <drivers/gpio.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <misc/byteorder.h>
#include <misc/util.h>

@@ -11,7 +11,7 @@
extern "C" {
#endif

#include <i2c.h>
#include <drivers/i2c.h>
#include <dt-bindings/i2c/i2c.h>
#include <logging/log.h>

@@ -19,7 +19,7 @@

#include <errno.h>
#include <kernel.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include "i2c_bitbang.h"

/*
@@ -5,7 +5,7 @@
*/

#include <kernel.h>
#include <i2c.h>
#include <drivers/i2c.h>

#define LOG_LEVEL CONFIG_I2C_LOG_LEVEL
#include <logging/log.h>
@@ -8,7 +8,7 @@

#include <kernel.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <soc.h>

/* Driverlib includes */
@@ -10,7 +10,7 @@
#include <stdlib.h>
#include <stdbool.h>

#include <i2c.h>
#include <drivers/i2c.h>
#include <kernel.h>
#include <init.h>
#include <arch/cpu.h>
@@ -8,7 +8,7 @@
#ifndef ZEPHYR_DRIVERS_I2C_I2C_DW_H_
#define ZEPHYR_DRIVERS_I2C_I2C_DW_H_

#include <i2c.h>
#include <drivers/i2c.h>
#include <stdbool.h>

#if DT_INST_0_SNPS_DESIGNWARE_I2C_PCIE || \
@@ -14,7 +14,7 @@
#include <errno.h>
#include <drivers/gpio.h>
#include <gpio/gpio_esp32.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <misc/util.h>
#include <string.h>

@@ -5,7 +5,7 @@
*/

#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <misc/util.h>
#include <em_cmu.h>
#include <em_i2c.h>
@@ -23,7 +23,7 @@
#include <device.h>
#include <errno.h>
#include <drivers/gpio.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include "i2c_bitbang.h"

/* Driver config */
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

#include <i2c.h>
#include <drivers/i2c.h>
#include <string.h>
#include <syscall_handler.h>

@@ -5,7 +5,7 @@
*/

#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <soc.h>
#include <i2c_imx.h>
#include <misc/util.h>
@@ -11,7 +11,7 @@
#include <kernel.h>
#include <soc.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include "i2c_ll_stm32.h"

#define LOG_LEVEL CONFIG_I2C_LOG_LEVEL
@@ -14,7 +14,7 @@
#include <kernel.h>
#include <soc.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include "i2c_ll_stm32.h"

#define LOG_LEVEL CONFIG_I2C_LOG_LEVEL
@@ -14,7 +14,7 @@
#include <kernel.h>
#include <soc.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include "i2c_ll_stm32.h"

#define LOG_LEVEL CONFIG_I2C_LOG_LEVEL
@@ -8,7 +8,7 @@
#include <kernel.h>
#include <soc.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>

#define SPEED_100KHZ_BUS 0
#define SPEED_400KHZ_BUS 1
@@ -5,7 +5,7 @@
*/

#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <soc.h>
#include <fsl_i2c.h>
#include <fsl_clock.h>
@@ -6,7 +6,7 @@
*/

#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <drivers/clock_control.h>
#include <fsl_lpi2c.h>

@@ -5,7 +5,7 @@
*/

#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <soc.h>
#include <misc/util.h>
#include <altera_common.h>
@@ -5,7 +5,7 @@
*/


#include <i2c.h>
#include <drivers/i2c.h>
#include <dt-bindings/i2c/i2c.h>
#include <nrfx_twi.h>

@@ -5,7 +5,7 @@
*/


#include <i2c.h>
#include <drivers/i2c.h>
#include <dt-bindings/i2c/i2c.h>
#include <nrfx_twim.h>

@@ -7,7 +7,7 @@
#include <errno.h>

#include <device.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <drivers/interrupt_controller/ioapic.h>
#include <power/power.h>

@@ -6,7 +6,7 @@

#include <errno.h>
#include <device.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <soc.h>

#include "qm_ss_i2c.h"
@@ -8,7 +8,7 @@
* SPDX-License-Identifier: Apache-2.0
*/

#include <i2c.h>
#include <drivers/i2c.h>
#include <drivers/clock_control.h>
#include <fsl_lpi2c.h>
#include <logging/log.h>
@@ -9,7 +9,7 @@
#include <device.h>
#include <init.h>
#include <soc.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <drivers/dma.h>

#include <logging/log.h>
@@ -19,7 +19,7 @@
#include <device.h>
#include <init.h>
#include <soc.h>
#include <i2c.h>
#include <drivers/i2c.h>

#define LOG_LEVEL CONFIG_I2C_LOG_LEVEL
#include <logging/log.h>
@@ -17,7 +17,7 @@
#include <device.h>
#include <init.h>
#include <soc.h>
#include <i2c.h>
#include <drivers/i2c.h>

#define LOG_LEVEL CONFIG_I2C_LOG_LEVEL
#include <logging/log.h>
@@ -14,7 +14,7 @@

#include <device.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include "i2c_bitbang.h"

/* SBCon hardware registers layout */
@@ -9,7 +9,7 @@
LOG_MODULE_REGISTER(i2c_sifive);

#include <device.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <sys/sys_io.h>

#include "i2c-priv.h"
@@ -7,7 +7,7 @@
#include <misc/util.h>
#include <kernel.h>
#include <errno.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <string.h>
#include <drivers/i2c/slave/eeprom.h>

@@ -10,7 +10,7 @@
*/

#include <drivers/gpio.h>
#include <i2c.h>
#include <drivers/i2c.h>
#include <kernel.h>
#include <led.h>
#include <misc/byteorder.h>
@@ -17,7 +17,7 @@
* values for a LED will affect other LEDs also.
*/

#include <i2c.h>
#include <drivers/i2c.h>
#include <led.h>
#include <misc/util.h>
#include <zephyr.h>
@@ -28,7 +28,7 @@
* communication between the host MCU and the driver.
*/

#include <i2c.h>
#include <drivers/i2c.h>
#include <led.h>
#include <device.h>
#include <zephyr.h>
@@ -9,7 +9,7 @@
* @brief LED driver for the PCA9633 I2C LED driver (7-bit slave address 0x62)
*/

#include <i2c.h>
#include <drivers/i2c.h>
#include <led.h>
#include <misc/util.h>
#include <zephyr.h>
@@ -12,7 +12,7 @@

#include <kernel.h>

#include <i2c.h>
#include <drivers/i2c.h>
#include <pwm.h>

#include "pwm_pca9685.h"

0 comments on commit 8f692c7

Please sign in to comment.
You can’t perform that action at this time.