]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - drivers/i2c/Kconfig
0591ade5b10a71f52825e4877caa08603b7425a8
[karo-tx-uboot.git] / drivers / i2c / Kconfig
1 menuconfig SYS_I2C
2         bool "I2C device support"
3
4 if SYS_I2C
5
6 config HARD_I2C
7         bool
8
9 config SYS_I2C_MXC
10         bool "Freescale i.MX I2C controller"
11         select HARD_I2C
12         select I2C_QUIRK_REG if FSL_LSCH3 || SOC_LS102XA
13
14 config DM_I2C
15         bool "Enable Driver Model for I2C drivers"
16         depends on DM
17         help
18           Enable driver model for I2C. The I2C uclass interface: probe, read,
19           write and speed, is implemented with the bus drivers operations,
20           which provide methods for bus setting and data transfer. Each chip
21           device (bus child) info is kept as parent platdata. The interface
22           is defined in include/i2c.h. When i2c bus driver supports the i2c
23           uclass, but the device drivers not, then DM_I2C_COMPAT config can
24           be used as compatibility layer.
25
26 config DM_I2C_COMPAT
27         bool "Enable I2C compatibility layer"
28         depends on DM_I2C
29         help
30           Enable old-style I2C functions for compatibility with existing code.
31           This option can be enabled as a temporary measure to avoid needing
32           to convert all code for a board in a single commit. It should not
33           be enabled for any board in an official release.
34
35 config DM_I2C_GPIO
36         bool "Enable Driver Model for software emulated I2C bus driver"
37         depends on DM_I2C && DM_GPIO
38         help
39           Enable the i2c bus driver emulation by using the GPIOs. The bus GPIO
40           configuration is given by the device tree. Kernel-style device tree
41           bindings are supported.
42           Binding info: doc/device-tree-bindings/i2c/i2c-gpio.txt
43
44 config SYS_I2C_SANDBOX
45         bool "Sandbox I2C driver"
46         depends on SANDBOX && DM_I2C
47         help
48           Enable I2C support for sandbox. This is an emulation of a real I2C
49           bus. Devices can be attached to the bus using the device tree
50           which specifies the driver to use. As an example, see this device
51           tree fragment from sandbox.dts. It shows that the I2C bus has a
52           single EEPROM at address 0x2c (7-bit address) which is emulated by
53           the driver for "sandbox,i2c-eeprom", which is in
54           drivers/misc/i2c_eeprom_emul.c.
55
56           i2c@0 {
57                 #address-cells = <1>;
58                 #size-cells = <0>;
59                 reg = <0>;
60                 compatible = "sandbox,i2c";
61                 clock-frequency = <400000>;
62                 eeprom@2c {
63                         reg = <0x2c>;
64                         compatible = "i2c-eeprom";
65                         emul {
66                                 compatible = "sandbox,i2c-eeprom";
67                                 sandbox,filename = "i2c.bin";
68                                 sandbox,size = <128>;
69                         };
70                 };
71         };
72
73
74 config SYS_I2C_UNIPHIER
75         bool "UniPhier I2C driver"
76         depends on ARCH_UNIPHIER && DM_I2C
77         default y
78         help
79           Support for UniPhier I2C controller driver.  This I2C controller
80           is used on PH1-LD4, PH1-sLD8 or older UniPhier SoCs.
81
82 config SYS_I2C_UNIPHIER_F
83         bool "UniPhier FIFO-builtin I2C driver"
84         depends on ARCH_UNIPHIER && DM_I2C
85         default y
86         help
87           Support for UniPhier FIFO-builtin I2C controller driver.
88           This I2C controller is used on PH1-Pro4 or newer UniPhier SoCs.
89
90 source "drivers/i2c/muxes/Kconfig"
91
92 endif