Skip to content

Commit 1ac9e16

Browse files
akhilr-nvWolfram Sang
authored andcommitted
i2c: tegra: Add Tegra264 support
Add support for Tegra264 SoC which supports 17 generic I2C controllers, two of which are in the AON (always-on) partition of the SoC. In addition to the features supported by Tegra194 it also supports a SW mutex register to allow sharing the same I2C instance across multiple firmware. Signed-off-by: Akhil R <akhilrajeev@nvidia.com> Signed-off-by: Kartik Rajput <kkartik@nvidia.com> Reviewed-by: Jon Hunter <jonathanh@nvidia.com> Acked-by: Thierry Reding <treding@nvidia.com> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
1 parent 6077cfd commit 1ac9e16

1 file changed

Lines changed: 33 additions & 0 deletions

File tree

drivers/i2c/busses/i2c-tegra.c

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1853,7 +1853,40 @@ static const struct tegra_i2c_hw_feature tegra256_i2c_hw = {
18531853
.has_mutex = true,
18541854
};
18551855

1856+
static const struct tegra_i2c_hw_feature tegra264_i2c_hw = {
1857+
.has_continue_xfer_support = true,
1858+
.has_per_pkt_xfer_complete_irq = true,
1859+
.clk_divisor_hs_mode = 1,
1860+
.clk_divisor_std_mode = 0x1d,
1861+
.clk_divisor_fast_mode = 0x15,
1862+
.clk_divisor_fast_plus_mode = 0x8,
1863+
.has_config_load_reg = true,
1864+
.has_multi_master_mode = true,
1865+
.has_slcg_override_reg = true,
1866+
.has_mst_fifo = true,
1867+
.has_mst_reset = true,
1868+
.quirks = &tegra194_i2c_quirks,
1869+
.supports_bus_clear = true,
1870+
.has_apb_dma = false,
1871+
.tlow_std_mode = 0x8,
1872+
.thigh_std_mode = 0x7,
1873+
.tlow_fast_mode = 0x2,
1874+
.thigh_fast_mode = 0x2,
1875+
.tlow_fastplus_mode = 0x2,
1876+
.thigh_fastplus_mode = 0x2,
1877+
.tlow_hs_mode = 0x4,
1878+
.thigh_hs_mode = 0x2,
1879+
.setup_hold_time_std_mode = 0x08080808,
1880+
.setup_hold_time_fast_mode = 0x02020202,
1881+
.setup_hold_time_fastplus_mode = 0x02020202,
1882+
.setup_hold_time_hs_mode = 0x090909,
1883+
.has_interface_timing_reg = true,
1884+
.enable_hs_mode_support = true,
1885+
.has_mutex = true,
1886+
};
1887+
18561888
static const struct of_device_id tegra_i2c_of_match[] = {
1889+
{ .compatible = "nvidia,tegra264-i2c", .data = &tegra264_i2c_hw, },
18571890
{ .compatible = "nvidia,tegra256-i2c", .data = &tegra256_i2c_hw, },
18581891
{ .compatible = "nvidia,tegra194-i2c", .data = &tegra194_i2c_hw, },
18591892
{ .compatible = "nvidia,tegra186-i2c", .data = &tegra186_i2c_hw, },

0 commit comments

Comments
 (0)