i2c: vt8500: Add support for Wondermedia I2C master-mode
Subsystems (2)
PATCH 1/1 i2c: vt8500: Add support for Wondermedia I2C master-mode
This patch adds support for the I2C controller found on Wondermedia SoCs.
Due to the lack of pinmux support, GPIO pin alternate functions are configured by machine's compatible property, as are pullups.
Signed-off-by Tony Prisk <[email protected]>
--- .../devicetree/bindings/i2c/i2c-vt8500.txt | 24 + drivers/i2c/busses/Kconfig | 7 + drivers/i2c/busses/Makefile | 1 + drivers/i2c/busses/i2c-wmt.c | 636 ++++++++++++++++++++ 4 files changed, 668 insertions(+) create mode 100644 Documentation/devicetree/bindings/i2c/i2c-vt8500.txt create mode 100644 drivers/i2c/busses/i2c-wmt.c
Documentation/devicetree/bindings/i2c/i2c-vt8500.txt new file +24 -0
@@ -0,0 +1,24 @@ +* Wondermedia I2C Controller + +Required properties : + + - compatible : should be "wm,wm8505-i2c" + - reg : Offset and length of the register set for the device + - interrupts : <IRQ> where IRQ is the interrupt number + - clocks : phandle to the I2C clock source + +Optional properties : + + - clock-frequency : desired I2C bus clock frequency in Hz. + Valid values are 100000 and 400000. + Default to 100000 if not specified, or invalid value. + +Example : + + i2c_0: i2c at d8280000 { + compatible = "wm,wm8505-i2c"; + reg = <0xd8280000 0x1000>; + interrupts = <19>; + clocks = <&clki2c0>; + clock-frequency = <400000>; + };
drivers/i2c/busses/Kconfig +7 -0
@@ -700,6 +700,13 @@ config I2C_VERSATILE This driver can also be built as a module. If so, the module will be called i2c-versatile. +config I2C_WMT + tristate "Wondermedia I2C Controller support" + depends on ARCH_VT8500 + help + If you say yes to this option, support will be included for the + I2C controllers found in Wondermedia SoCs. + config I2C_OCTEON tristate "Cavium OCTEON I2C bus support" depends on CPU_CAVIUM_OCTEON
drivers/i2c/busses/Makefile +1 -0
@@ -69,6 +69,7 @@ obj-$(CONFIG_I2C_SIRF) += i2c-sirf.o obj-$(CONFIG_I2C_STU300) += i2c-stu300.o obj-$(CONFIG_I2C_TEGRA) += i2c-tegra.o obj-$(CONFIG_I2C_VERSATILE) += i2c-versatile.o +obj-$(CONFIG_I2C_WMT) += i2c-wmt.o obj-$(CONFIG_I2C_OCTEON) += i2c-octeon.o obj-$(CONFIG_I2C_XILINX) += i2c-xiic.o obj-$(CONFIG_I2C_XLR) += i2c-xlr.o
drivers/i2c/busses/i2c-wmt.c new file +636 -0
636 lines not on this page · raw message
Signature · 1 line
1.7.9.5