Kconfig 4.8 KB
Newer Older
1
# SPDX-License-Identifier: GPL-2.0-only
L
Linus Torvalds 已提交
2
#
3
# I2C subsystem configuration
L
Linus Torvalds 已提交
4 5
#

6 7 8
menu "I2C support"

config I2C
L
Linus Torvalds 已提交
9
	tristate "I2C support"
10
	select RT_MUTEXES
11
	select IRQ_DOMAIN
12
	help
13
	  I2C (pronounce: I-squared-C) is a slow serial bus protocol used in
L
Linus Torvalds 已提交
14 15 16 17 18 19 20 21 22 23 24 25 26 27
	  many micro controller applications and developed by Philips.  SMBus,
	  or System Management Bus is a subset of the I2C protocol.  More
	  information is contained in the directory <file:Documentation/i2c/>,
	  especially in the file called "summary" there.

	  Both I2C and SMBus are supported here. You will need this for
	  hardware sensors support, and also for Video For Linux support.

	  If you want I2C support, you should say Y here and also to the
	  specific driver for your bus adapter(s) below.

	  This I2C support can also be built as a module.  If so, the module
	  will be called i2c-core.

L
Lan Tianyu 已提交
28 29 30
config ACPI_I2C_OPREGION
	bool "ACPI I2C Operation region support"
	depends on I2C=y && ACPI
31 32
	default y
	help
L
Lan Tianyu 已提交
33 34 35
	  Say Y here if you want to enable ACPI I2C operation region support.
	  Operation Regions allow firmware (BIOS) code to access I2C slave devices,
	  such as smart batteries through an I2C host controller driver.
36

J
Jan Engelhardt 已提交
37 38
if I2C

39
config I2C_BOARDINFO
40
	bool
41 42
	default y

43
config I2C_COMPAT
44
	bool "Enable compatibility bits for old user-space"
45 46 47 48 49 50
	default y
	help
	  Say Y here if you intend to run lm-sensors 3.1.1 or older, or any
	  other user-space package which expects i2c adapters to be class
	  devices. If you don't know, say Y.

L
Linus Torvalds 已提交
51 52 53 54 55 56
config I2C_CHARDEV
	tristate "I2C device interface"
	help
	  Say Y here to use i2c-* device files, usually found in the /dev
	  directory on your system.  They make it possible to have user-space
	  programs use the I2C bus.  Information on how to do this is
57
	  contained in the file <file:Documentation/i2c/dev-interface.rst>.
L
Linus Torvalds 已提交
58 59 60 61

	  This support is also available as a module.  If so, the module 
	  will be called i2c-dev.

62 63 64 65 66 67 68 69 70 71
config I2C_MUX
	tristate "I2C bus multiplexing support"
	help
	  Say Y here if you want the I2C core to support the ability to
	  handle multiplexed I2C bus topologies, by presenting each
	  multiplexed segment as a I2C adapter.

	  This support is also available as a module.  If so, the module
	  will be called i2c-mux.

72
source "drivers/i2c/muxes/Kconfig"
73

74 75 76 77 78 79 80 81 82 83 84 85 86 87
config I2C_HELPER_AUTO
	bool "Autoselect pertinent helper modules"
	default y
	help
	  Some I2C bus drivers require so-called "I2C algorithm" modules
	  to work. These are basically software-only abstractions of generic
	  I2C interfaces. This option will autoselect them so that you don't
	  have to care.

	  Unselect this only if you need to enable additional helper
	  modules, for example for use with external I2C bus drivers.

	  In doubt, say Y.

88
config I2C_SMBUS
89
	tristate "SMBus-specific protocols" if !I2C_HELPER_AUTO
90 91
	help
	  Say Y here if you want support for SMBus extensions to the I2C
92 93
	  specification. At the moment, two extensions are supported:
	  the SMBus Alert protocol and the SMBus Host Notify protocol.
94 95 96 97

	  This support is also available as a module.  If so, the module
	  will be called i2c-smbus.

98 99
source "drivers/i2c/algos/Kconfig"
source "drivers/i2c/busses/Kconfig"
L
Linus Torvalds 已提交
100

P
Peter Huewe 已提交
101 102
config I2C_STUB
	tristate "I2C/SMBus Test Stub"
103
	depends on m
P
Peter Huewe 已提交
104 105 106 107 108 109
	default 'n'
	help
	  This module may be useful to developers of SMBus client drivers,
	  especially for certain kinds of sensor chips.

	  If you do build this module, be sure to read the notes and warnings
110
	  in <file:Documentation/i2c/i2c-stub.rst>.
P
Peter Huewe 已提交
111 112 113

	  If you don't know what to do here, definitely say N.

114 115
config I2C_SLAVE
	bool "I2C slave support"
116 117 118 119
	help
	  This enables Linux to act as an I2C slave device. Note that your I2C
	  bus master driver also needs to support this functionality. Please
	  read Documentation/i2c/slave-interface.rst for further details.
120 121 122 123 124

if I2C_SLAVE

config I2C_SLAVE_EEPROM
	tristate "I2C eeprom slave driver"
125 126 127
	help
	  This backend makes Linux behave like an I2C EEPROM. Please read
	  Documentation/i2c/slave-eeprom-backend.rst for further details.
128 129 130

endif

L
Linus Torvalds 已提交
131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147
config I2C_DEBUG_CORE
	bool "I2C Core debugging messages"
	help
	  Say Y here if you want the I2C core to produce a bunch of debug
	  messages to the system log.  Select this if you are having a
	  problem with I2C support and want to see more of what is going on.

config I2C_DEBUG_ALGO
	bool "I2C Algorithm debugging messages"
	help
	  Say Y here if you want the I2C algorithm drivers to produce a bunch
	  of debug messages to the system log.  Select this if you are having
	  a problem with I2C support and want to see more of what is going
	  on.

config I2C_DEBUG_BUS
	bool "I2C Bus debugging messages"
P
Peter Huewe 已提交
148
	depends on HAS_IOMEM
L
Linus Torvalds 已提交
149 150 151 152 153 154
	help
	  Say Y here if you want the I2C bus drivers to produce a bunch of
	  debug messages to the system log.  Select this if you are having
	  a problem with I2C support and want to see more of what is going
	  on.

J
Jan Engelhardt 已提交
155
endif # I2C
156 157

endmenu