Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torvalds/linux.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatti Lehtimäki <matti.lehtimaki@gmail.com>2022-05-22 19:27:58 +0300
committerWolfram Sang <wsa@kernel.org>2022-06-15 22:55:21 +0300
commit4c0ad47b8da5898115fc17c5bb0e538348531a39 (patch)
treee25a8a0d8de2ec843b9fa02ef75fb2e886fe00d1 /drivers/i2c/busses/i2c-qcom-cci.c
parent3fe012f482b2beaefe158c2288afce5f5919301b (diff)
i2c: qcom-cci: add msm8974 compatible
MSM8974 CCI is the same as MSM8916 except it has two masters. Signed-off-by: Matti Lehtimäki <matti.lehtimaki@gmail.com> Signed-off-by: Luca Weiss <luca@z3ntu.xyz> Reviewed-by: Loic Poulain <loic.poulain@linaro.org> Signed-off-by: Wolfram Sang <wsa@kernel.org>
Diffstat (limited to 'drivers/i2c/busses/i2c-qcom-cci.c')
-rw-r--r--drivers/i2c/busses/i2c-qcom-cci.c35
1 files changed, 35 insertions, 0 deletions
diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
index 774ca30fbab6..ea48e6a9cfca 100644
--- a/drivers/i2c/busses/i2c-qcom-cci.c
+++ b/drivers/i2c/busses/i2c-qcom-cci.c
@@ -726,6 +726,40 @@ static const struct cci_data cci_v1_data = {
},
};
+static const struct cci_data cci_v1_5_data = {
+ .num_masters = 2,
+ .queue_size = { 64, 16 },
+ .quirks = {
+ .max_write_len = 10,
+ .max_read_len = 12,
+ },
+ .cci_clk_rate = 19200000,
+ .params[I2C_MODE_STANDARD] = {
+ .thigh = 78,
+ .tlow = 114,
+ .tsu_sto = 28,
+ .tsu_sta = 28,
+ .thd_dat = 10,
+ .thd_sta = 77,
+ .tbuf = 118,
+ .scl_stretch_en = 0,
+ .trdhld = 6,
+ .tsp = 1
+ },
+ .params[I2C_MODE_FAST] = {
+ .thigh = 20,
+ .tlow = 28,
+ .tsu_sto = 21,
+ .tsu_sta = 21,
+ .thd_dat = 13,
+ .thd_sta = 18,
+ .tbuf = 32,
+ .scl_stretch_en = 0,
+ .trdhld = 6,
+ .tsp = 3
+ },
+};
+
static const struct cci_data cci_v2_data = {
.num_masters = 2,
.queue_size = { 64, 16 },
@@ -774,6 +808,7 @@ static const struct cci_data cci_v2_data = {
static const struct of_device_id cci_dt_match[] = {
{ .compatible = "qcom,msm8916-cci", .data = &cci_v1_data},
+ { .compatible = "qcom,msm8974-cci", .data = &cci_v1_5_data},
{ .compatible = "qcom,msm8996-cci", .data = &cci_v2_data},
{ .compatible = "qcom,sdm845-cci", .data = &cci_v2_data},
{ .compatible = "qcom,sm8250-cci", .data = &cci_v2_data},