[PATCH v2 2/7] i2c: qcom-cci: Add msm8953 compatible

Luca Weiss posted 7 patches 3 months, 2 weeks ago
[PATCH v2 2/7] i2c: qcom-cci: Add msm8953 compatible
Posted by Luca Weiss 3 months, 2 weeks ago
Add a config for the v1.2.5 CCI found on msm8953 which has different
values in .params compared to others already supported in the driver.

Reviewed-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Signed-off-by: Luca Weiss <luca@lucaweiss.eu>
---
 drivers/i2c/busses/i2c-qcom-cci.c | 46 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
index e631d79baf14..884055df1560 100644
--- a/drivers/i2c/busses/i2c-qcom-cci.c
+++ b/drivers/i2c/busses/i2c-qcom-cci.c
@@ -783,8 +783,54 @@ static const struct cci_data cci_v2_data = {
 	},
 };
 
+static const struct cci_data cci_msm8953_data = {
+	.num_masters = 2,
+	.queue_size = { 64, 16 },
+	.quirks = {
+		.max_write_len = 11,
+		.max_read_len = 12,
+	},
+	.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
+	},
+	.params[I2C_MODE_FAST_PLUS] = {
+		.thigh = 16,
+		.tlow = 22,
+		.tsu_sto = 17,
+		.tsu_sta = 18,
+		.thd_dat = 16,
+		.thd_sta = 15,
+		.tbuf = 19,
+		.scl_stretch_en = 1,
+		.trdhld = 3,
+		.tsp = 3
+	},
+};
+
 static const struct of_device_id cci_dt_match[] = {
 	{ .compatible = "qcom,msm8226-cci", .data = &cci_v1_data},
+	{ .compatible = "qcom,msm8953-cci", .data = &cci_msm8953_data},
 	{ .compatible = "qcom,msm8974-cci", .data = &cci_v1_5_data},
 	{ .compatible = "qcom,msm8996-cci", .data = &cci_v2_data},
 

-- 
2.51.2
Re: [PATCH v2 2/7] i2c: qcom-cci: Add msm8953 compatible
Posted by Dmitry Baryshkov 2 months ago
On Tue, Oct 28, 2025 at 05:40:47PM +0100, Luca Weiss wrote:
> Add a config for the v1.2.5 CCI found on msm8953 which has different
> values in .params compared to others already supported in the driver.
> 
> Reviewed-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
> Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> Signed-off-by: Luca Weiss <luca@lucaweiss.eu>
> ---
>  drivers/i2c/busses/i2c-qcom-cci.c | 46 +++++++++++++++++++++++++++++++++++++++
>  1 file changed, 46 insertions(+)
> 

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>


-- 
With best wishes
Dmitry
Re: [PATCH v2 2/7] i2c: qcom-cci: Add msm8953 compatible
Posted by Luca Weiss 2 months ago
Hi,

Ping for someone to pick up this patch please!

Regards 
Luca


Luca Weiss <luca@lucaweiss.eu> schreef op 29 oktober 2025 01:40:47 GMT+09:00:
>Add a config for the v1.2.5 CCI found on msm8953 which has different
>values in .params compared to others already supported in the driver.
>
>Reviewed-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
>Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
>Signed-off-by: Luca Weiss <luca@lucaweiss.eu>
>---
> drivers/i2c/busses/i2c-qcom-cci.c | 46 +++++++++++++++++++++++++++++++++++++++
> 1 file changed, 46 insertions(+)
>
>diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
>index e631d79baf14..884055df1560 100644
>--- a/drivers/i2c/busses/i2c-qcom-cci.c
>+++ b/drivers/i2c/busses/i2c-qcom-cci.c
>@@ -783,8 +783,54 @@ static const struct cci_data cci_v2_data = {
> 	},
> };
> 
>+static const struct cci_data cci_msm8953_data = {
>+	.num_masters = 2,
>+	.queue_size = { 64, 16 },
>+	.quirks = {
>+		.max_write_len = 11,
>+		.max_read_len = 12,
>+	},
>+	.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
>+	},
>+	.params[I2C_MODE_FAST_PLUS] = {
>+		.thigh = 16,
>+		.tlow = 22,
>+		.tsu_sto = 17,
>+		.tsu_sta = 18,
>+		.thd_dat = 16,
>+		.thd_sta = 15,
>+		.tbuf = 19,
>+		.scl_stretch_en = 1,
>+		.trdhld = 3,
>+		.tsp = 3
>+	},
>+};
>+
> static const struct of_device_id cci_dt_match[] = {
> 	{ .compatible = "qcom,msm8226-cci", .data = &cci_v1_data},
>+	{ .compatible = "qcom,msm8953-cci", .data = &cci_msm8953_data},
> 	{ .compatible = "qcom,msm8974-cci", .data = &cci_v1_5_data},
> 	{ .compatible = "qcom,msm8996-cci", .data = &cci_v2_data},
> 
>
Re: [PATCH v2 2/7] i2c: qcom-cci: Add msm8953 compatible
Posted by Wolfram Sang 2 months ago
> Ping for someone to pick up this patch please!

It was accidently set to "Handled elsewhere" so it slipped through the
cracks. I am sorry about that.

Applied to for-next, thanks!

Re: [PATCH v2 2/7] i2c: qcom-cci: Add msm8953 compatible
Posted by Luca Weiss 3 months, 1 week ago
On 28-10-2025 17:40, Luca Weiss wrote:
> Add a config for the v1.2.5 CCI found on msm8953 which has different
> values in .params compared to others already supported in the driver.
> 
> Reviewed-by: Loic Poulain <loic.poulain@oss.qualcomm.com>
> Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> Signed-off-by: Luca Weiss <luca@lucaweiss.eu>

Hi Andi,

Could you please also pick up this patch? Since Wolfram has added
Acked-by I assume he's not going to pick it up?

Regards
Luca

> ---
>   drivers/i2c/busses/i2c-qcom-cci.c | 46 +++++++++++++++++++++++++++++++++++++++
>   1 file changed, 46 insertions(+)
> 
> diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
> index e631d79baf14..884055df1560 100644
> --- a/drivers/i2c/busses/i2c-qcom-cci.c
> +++ b/drivers/i2c/busses/i2c-qcom-cci.c
> @@ -783,8 +783,54 @@ static const struct cci_data cci_v2_data = {
>   	},
>   };
>   
> +static const struct cci_data cci_msm8953_data = {
> +	.num_masters = 2,
> +	.queue_size = { 64, 16 },
> +	.quirks = {
> +		.max_write_len = 11,
> +		.max_read_len = 12,
> +	},
> +	.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
> +	},
> +	.params[I2C_MODE_FAST_PLUS] = {
> +		.thigh = 16,
> +		.tlow = 22,
> +		.tsu_sto = 17,
> +		.tsu_sta = 18,
> +		.thd_dat = 16,
> +		.thd_sta = 15,
> +		.tbuf = 19,
> +		.scl_stretch_en = 1,
> +		.trdhld = 3,
> +		.tsp = 3
> +	},
> +};
> +
>   static const struct of_device_id cci_dt_match[] = {
>   	{ .compatible = "qcom,msm8226-cci", .data = &cci_v1_data},
> +	{ .compatible = "qcom,msm8953-cci", .data = &cci_msm8953_data},
>   	{ .compatible = "qcom,msm8974-cci", .data = &cci_v1_5_data},
>   	{ .compatible = "qcom,msm8996-cci", .data = &cci_v2_data},
>   
>