i2c: Add Tegra BPMP I2C proxy driver
v2 cover i2c: Add Tegra BPMP I2C proxy driver
From: Thierry Reding <[email protected]>
Hi Wolfram,
This series of patches depends on two branches in the Tegra tree, so I think the easiest would be if you Acked-by'd this so that I can manage the dependencies in the Tegra tree. The DT binding has already been reviewed and I've tested the driver in my development tree for a while and it's working great.
Thierry
Shardar Shariff Md (1):
i2c: Add Tegra BPMP I2C proxy driver
Stephen Warren (1):
dt-bindings: Add Tegra186 BPMP I2C binding
.../bindings/i2c/nvidia,tegra186-bpmp-i2c.txt | 42 +++ drivers/i2c/busses/Kconfig | 13 + drivers/i2c/busses/Makefile | 1 + drivers/i2c/busses/i2c-tegra-bpmp.c | 365 +++++++++++++++++++++ 4 files changed, 421 insertions(+) create mode 100644 Documentation/devicetree/bindings/i2c/nvidia,tegra186-bpmp-i2c.txt create mode 100644 drivers/i2c/busses/i2c-tegra-bpmp.c
Signature · 1 line
2.10.2
PATCH v2 1/2 dt-bindings: Add Tegra186 BPMP I2C binding
From: Stephen Warren <[email protected]>
In Tegra186, the BPMP (Boot and Power Management Processor) owns certain HW devices, such as the I2C controller for the power management I2C bus. Software running on other CPUs must perform IPC to the BPMP in order to execute transactions on that I2C bus. This binding describes an I2C bus that is accessed in such a fashion.
--- .../bindings/i2c/nvidia,tegra186-bpmp-i2c.txt | 42 ++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 Documentation/devicetree/bindings/i2c/nvidia,tegra186-bpmp-i2c.txt
Documentation/devicetree/bindings/i2c/nvidia,tegra186-bpmp-i2c.txt new file +42 -0
@@ -0,0 +1,42 @@ +NVIDIA Tegra186 BPMP I2C controller + +In Tegra186, the BPMP (Boot and Power Management Processor) owns certain HW +devices, such as the I2C controller for the power management I2C bus. Software +running on other CPUs must perform IPC to the BPMP in order to execute +transactions on that I2C bus. This binding describes an I2C bus that is +accessed in such a fashion. + +The BPMP I2C node must be located directly inside the main BPMP node. See +../firmware/nvidia,tegra186-bpmp.txt for details of the BPMP binding. + +This node represents an I2C controller. See ../i2c/i2c.txt for details of the +core I2C binding. + +Required properties: +- compatible: + Array of strings. + One of: + - "nvidia,tegra186-bpmp-i2c". +- #address-cells: Address cells for I2C device address. + Single-cell integer. + Must be <1>. +- #size-cells: + Single-cell integer. + Must be <0>. +- nvidia,bpmp-bus-id: + Single-cell integer. + Indicates the I2C bus number this DT node represent, as defined by the + BPMP firmware. + +Example: + +bpmp { + ... + + i2c { + compatible = "nvidia,tegra186-bpmp-i2c"; + #address-cells = <1>; + #size-cells = <0>; + nvidia,bpmp-bus-id = <5>; + }; +};
Signature · 1 line
2.10.2
PATCH v2 2/2 i2c: Add Tegra BPMP I2C proxy driver
In reply to Thierry RedingFrom: Shardar Shariff Md <[email protected]>
Add Tegra BPMP I2C driver. The BPMP is the boot and power management processor embedded in Tegra SoCs. In newer SoC versions, access to one of the I2C busses goes via the BPMP, requiring a different "proxy" I2C driver that accesses the bus via the real I2C driver embedded in the BPMP firmware.
--- drivers/i2c/busses/Kconfig | 13 ++ drivers/i2c/busses/Makefile | 1 + drivers/i2c/busses/i2c-tegra-bpmp.c | 365 ++++++++++++++++++++++++++++++++++++ 3 files changed, 379 insertions(+) create mode 100644 drivers/i2c/busses/i2c-tegra-bpmp.c
drivers/i2c/busses/Kconfig +13 -0
@@ -909,6 +909,19 @@ config I2C_TEGRA If you say yes to this option, support will be included for the I2C controller embedded in NVIDIA Tegra SOCs +config I2C_TEGRA_BPMP + tristate "NVIDIA Tegra BPMP I2C controller" + depends on TEGRA_BPMP + select I2C_ALGO_BUSCLEAR + select I2C_ALGOBIT + help + If you say yes to this option, support will be included for the I2C + controller embedded in NVIDIA Tegra SoCs accessed via the BPMP. + + This I2C driver is a 'virtual' I2C driver. The real driver is part + of the BPMP firmware, and this driver merely communicates with that + real driver. + config I2C_UNIPHIER tristate "UniPhier FIFO-less I2C controller" depends on ARCH_UNIPHIER || COMPILE_TEST
drivers/i2c/busses/Makefile +1 -0
@@ -87,6 +87,7 @@ obj-$(CONFIG_I2C_ST) += i2c-st.o obj-$(CONFIG_I2C_STU300) += i2c-stu300.o obj-$(CONFIG_I2C_SUN6I_P2WI) += i2c-sun6i-p2wi.o obj-$(CONFIG_I2C_TEGRA) += i2c-tegra.o +obj-$(CONFIG_I2C_TEGRA_BPMP) += i2c-tegra-bpmp.o obj-$(CONFIG_I2C_UNIPHIER) += i2c-uniphier.o obj-$(CONFIG_I2C_UNIPHIER_F) += i2c-uniphier-f.o obj-$(CONFIG_I2C_VERSATILE) += i2c-versatile.o
drivers/i2c/busses/i2c-tegra-bpmp.c new file +365 -0
365 lines not on this page · raw message
Signature · 1 line
2.10.2