0001 # SPDX-License-Identifier: GPL-2.0-only
0002 #
0003 # I2C subsystem configuration
0004 #
0005
0006 menu "I2C support"
0007
0008 config I2C
0009 tristate "I2C support"
0010 select RT_MUTEXES
0011 select IRQ_DOMAIN
0012 help
0013 I2C (pronounce: I-squared-C) is a slow serial bus protocol used in
0014 many micro controller applications and developed by Philips. SMBus,
0015 or System Management Bus is a subset of the I2C protocol. More
0016 information is contained in the directory <file:Documentation/i2c/>,
0017 especially in the file called "summary" there.
0018
0019 Both I2C and SMBus are supported here. You will need this for
0020 hardware sensors support, and also for Video For Linux support.
0021
0022 If you want I2C support, you should say Y here and also to the
0023 specific driver for your bus adapter(s) below.
0024
0025 This I2C support can also be built as a module. If so, the module
0026 will be called i2c-core.
0027
0028 config ACPI_I2C_OPREGION
0029 bool "ACPI I2C Operation region support"
0030 depends on I2C=y && ACPI
0031 default y
0032 help
0033 Say Y here if you want to enable ACPI I2C operation region support.
0034 Operation Regions allow firmware (BIOS) code to access I2C slave devices,
0035 such as smart batteries through an I2C host controller driver.
0036
0037 if I2C
0038
0039 config I2C_BOARDINFO
0040 bool
0041 default y
0042
0043 config I2C_COMPAT
0044 bool "Enable compatibility bits for old user-space"
0045 default y
0046 help
0047 Say Y here if you intend to run lm-sensors 3.1.1 or older, or any
0048 other user-space package which expects i2c adapters to be class
0049 devices. If you don't know, say Y.
0050
0051 config I2C_CHARDEV
0052 tristate "I2C device interface"
0053 help
0054 Say Y here to use i2c-* device files, usually found in the /dev
0055 directory on your system. They make it possible to have user-space
0056 programs use the I2C bus. Information on how to do this is
0057 contained in the file <file:Documentation/i2c/dev-interface.rst>.
0058
0059 This support is also available as a module. If so, the module
0060 will be called i2c-dev.
0061
0062 config I2C_MUX
0063 tristate "I2C bus multiplexing support"
0064 help
0065 Say Y here if you want the I2C core to support the ability to
0066 handle multiplexed I2C bus topologies, by presenting each
0067 multiplexed segment as a I2C adapter.
0068
0069 This support is also available as a module. If so, the module
0070 will be called i2c-mux.
0071
0072 source "drivers/i2c/muxes/Kconfig"
0073
0074 config I2C_HELPER_AUTO
0075 bool "Autoselect pertinent helper modules"
0076 default y
0077 help
0078 Some I2C bus drivers require so-called "I2C algorithm" modules
0079 to work. These are basically software-only abstractions of generic
0080 I2C interfaces. This option will autoselect them so that you don't
0081 have to care.
0082
0083 Unselect this only if you need to enable additional helper
0084 modules, for example for use with external I2C bus drivers.
0085
0086 In doubt, say Y.
0087
0088 config I2C_SMBUS
0089 tristate "SMBus-specific protocols" if !I2C_HELPER_AUTO
0090 help
0091 Say Y here if you want support for SMBus extensions to the I2C
0092 specification. At the moment, two extensions are supported:
0093 the SMBus Alert protocol and the SMBus Host Notify protocol.
0094
0095 This support is also available as a module. If so, the module
0096 will be called i2c-smbus.
0097
0098 source "drivers/i2c/algos/Kconfig"
0099 source "drivers/i2c/busses/Kconfig"
0100
0101 config I2C_STUB
0102 tristate "I2C/SMBus Test Stub"
0103 depends on m
0104 help
0105 This module may be useful to developers of SMBus client drivers,
0106 especially for certain kinds of sensor chips.
0107
0108 If you do build this module, be sure to read the notes and warnings
0109 in <file:Documentation/i2c/i2c-stub.rst>.
0110
0111 If you don't know what to do here, definitely say N.
0112
0113 config I2C_SLAVE
0114 bool "I2C slave support"
0115 help
0116 This enables Linux to act as an I2C slave device. Note that your I2C
0117 bus master driver also needs to support this functionality. Please
0118 read Documentation/i2c/slave-interface.rst for further details.
0119
0120 if I2C_SLAVE
0121
0122 config I2C_SLAVE_EEPROM
0123 tristate "I2C eeprom slave driver"
0124 help
0125 This backend makes Linux behave like an I2C EEPROM. Please read
0126 Documentation/i2c/slave-eeprom-backend.rst for further details.
0127
0128 config I2C_SLAVE_TESTUNIT
0129 tristate "I2C eeprom testunit driver"
0130 help
0131 This backend can be used to trigger test cases for I2C bus masters
0132 which require a remote device with certain capabilities, e.g.
0133 multi-master, SMBus Host Notify, etc. Please read
0134 Documentation/i2c/slave-testunit-backend.rst for further details.
0135
0136 endif
0137
0138 config I2C_DEBUG_CORE
0139 bool "I2C Core debugging messages"
0140 help
0141 Say Y here if you want the I2C core to produce a bunch of debug
0142 messages to the system log. Select this if you are having a
0143 problem with I2C support and want to see more of what is going on.
0144
0145 config I2C_DEBUG_ALGO
0146 bool "I2C Algorithm debugging messages"
0147 help
0148 Say Y here if you want the I2C algorithm drivers to produce a bunch
0149 of debug messages to the system log. Select this if you are having
0150 a problem with I2C support and want to see more of what is going
0151 on.
0152
0153 config I2C_DEBUG_BUS
0154 bool "I2C Bus debugging messages"
0155 depends on HAS_IOMEM
0156 help
0157 Say Y here if you want the I2C bus drivers to produce a bunch of
0158 debug messages to the system log. Select this if you are having
0159 a problem with I2C support and want to see more of what is going
0160 on.
0161
0162 endif # I2C
0163
0164 endmenu