]> git.kernelconcepts.de Git - karo-tx-uboot.git/blob - drivers/i2c/Kconfig
fced6ebf9432ecf868d4b3d338231bc7cd4682f8
[karo-tx-uboot.git] / drivers / i2c / Kconfig
1 #
2 # I2C subsystem configuration
3 #
4
5 menu "I2C device support"
6
7 config HARD_I2C
8         bool
9
10 config SYS_I2C
11         bool
12
13 config DM_I2C
14         bool "Enable Driver Model for I2C drivers"
15         depends on DM
16         help
17           Enable driver model for I2C. The I2C uclass interface: probe, read,
18           write and speed, is implemented with the bus drivers operations,
19           which provide methods for bus setting and data transfer. Each chip
20           device (bus child) info is kept as parent platdata. The interface
21           is defined in include/i2c.h. When i2c bus driver supports the i2c
22           uclass, but the device drivers not, then DM_I2C_COMPAT config can
23           be used as compatibility layer.
24
25 config DM_I2C_COMPAT
26         bool "Enable I2C compatibility layer"
27         depends on DM_I2C
28         help
29           Enable old-style I2C functions for compatibility with existing code.
30           This option can be enabled as a temporary measure to avoid needing
31           to convert all code for a board in a single commit. It should not
32           be enabled for any board in an official release.
33
34 config I2C_CROS_EC_TUNNEL
35         tristate "Chrome OS EC tunnel I2C bus"
36         depends on CROS_EC
37         help
38           This provides an I2C bus that will tunnel i2c commands through to
39           the other side of the Chrome OS EC to the I2C bus connected there.
40           This will work whatever the interface used to talk to the EC (SPI,
41           I2C or LPC). Some Chromebooks use this when the hardware design
42           does not allow direct access to the main PMIC from the AP.
43
44 config I2C_CROS_EC_LDO
45         bool "Provide access to LDOs on the Chrome OS EC"
46         depends on CROS_EC
47         ---help---
48         On many Chromebooks the main PMIC is inaccessible to the AP. This is
49         often dealt with by using an I2C pass-through interface provided by
50         the EC. On some unfortunate models (e.g. Spring) the pass-through
51         is not available, and an LDO message is available instead. This
52         option enables a driver which provides very basic access to those
53         regulators, via the EC. We implement this as an I2C bus which
54         emulates just the TPS65090 messages we know about. This is done to
55         avoid duplicating the logic in the TPS65090 regulator driver for
56         enabling/disabling an LDO.
57
58 config DM_I2C_GPIO
59         bool "Enable Driver Model for software emulated I2C bus driver"
60         depends on DM_I2C && DM_GPIO
61         help
62           Enable the i2c bus driver emulation by using the GPIOs. The bus GPIO
63           configuration is given by the device tree. Kernel-style device tree
64           bindings are supported.
65           Binding info: doc/device-tree-bindings/i2c/i2c-gpio.txt
66
67 config SYS_I2C_MXC
68         bool "Freescale i.MX I2C controller"
69         select HARD_I2C
70         select I2C_QUIRK_REG if FSL_LSCH3 || SOC_LS102XA
71
72 config I2C_QUIRK_REG
73         bool
74
75 config SYS_I2C_SANDBOX
76         bool "Sandbox I2C driver"
77         depends on SANDBOX && DM_I2C
78         help
79           Enable I2C support for sandbox. This is an emulation of a real I2C
80           bus. Devices can be attached to the bus using the device tree
81           which specifies the driver to use. As an example, see this device
82           tree fragment from sandbox.dts. It shows that the I2C bus has a
83           single EEPROM at address 0x2c (7-bit address) which is emulated by
84           the driver for "sandbox,i2c-eeprom", which is in
85           drivers/misc/i2c_eeprom_emul.c.
86
87           i2c@0 {
88                 #address-cells = <1>;
89                 #size-cells = <0>;
90                 reg = <0>;
91                 compatible = "sandbox,i2c";
92                 clock-frequency = <400000>;
93                 eeprom@2c {
94                         reg = <0x2c>;
95                         compatible = "i2c-eeprom";
96                         emul {
97                                 compatible = "sandbox,i2c-eeprom";
98                                 sandbox,filename = "i2c.bin";
99                                 sandbox,size = <128>;
100                         };
101                 };
102         };
103
104
105 config SYS_I2C_UNIPHIER
106         bool "UniPhier I2C driver"
107         depends on ARCH_UNIPHIER && DM_I2C
108         default y
109         help
110           Support for UniPhier I2C controller driver.  This I2C controller
111           is used on PH1-LD4, PH1-sLD8 or older UniPhier SoCs.
112
113 config SYS_I2C_UNIPHIER_F
114         bool "UniPhier FIFO-builtin I2C driver"
115         depends on ARCH_UNIPHIER && DM_I2C
116         default y
117         help
118           Support for UniPhier FIFO-builtin I2C controller driver.
119           This I2C controller is used on PH1-Pro4 or newer UniPhier SoCs.
120
121 source "drivers/i2c/muxes/Kconfig"
122
123 endmenu