2023-10-30 14:14:36

by Andy Shevchenko

[permalink] [raw]
Subject: [PATCH v1 1/1] pinctrl: tangier: Enable 910 Ohm bias

Family 7 (I2C) supports special bias value, i.e. 910 Ohm.

Enable it for configuring pin.

Signed-off-by: Andy Shevchenko <[email protected]>
---
drivers/pinctrl/intel/pinctrl-tangier.c | 6 ++++++
1 file changed, 6 insertions(+)

diff --git a/drivers/pinctrl/intel/pinctrl-tangier.c b/drivers/pinctrl/intel/pinctrl-tangier.c
index 40dd60c9e526..007bca1cf224 100644
--- a/drivers/pinctrl/intel/pinctrl-tangier.c
+++ b/drivers/pinctrl/intel/pinctrl-tangier.c
@@ -382,6 +382,9 @@ static int tng_config_set_pin(struct tng_pinctrl *tp, unsigned int pin,
case 2000:
term = BUFCFG_PUPD_VAL_2K;
break;
+ case 910:
+ term = BUFCFG_PUPD_VAL_910;
+ break;
default:
return -EINVAL;
}
@@ -405,6 +408,9 @@ static int tng_config_set_pin(struct tng_pinctrl *tp, unsigned int pin,
case 2000:
term = BUFCFG_PUPD_VAL_2K;
break;
+ case 910:
+ term = BUFCFG_PUPD_VAL_910;
+ break;
default:
return -EINVAL;
}
--
2.40.0.1.gaa8946217a0b


2023-10-30 21:35:56

by Raag Jadav

[permalink] [raw]
Subject: Re: [PATCH v1 1/1] pinctrl: tangier: Enable 910 Ohm bias

On Mon, Oct 30, 2023 at 04:14:04PM +0200, Andy Shevchenko wrote:
> Family 7 (I2C) supports special bias value, i.e. 910 Ohm.
>
> Enable it for configuring pin.
>
> Signed-off-by: Andy Shevchenko <[email protected]>
> ---
> drivers/pinctrl/intel/pinctrl-tangier.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/drivers/pinctrl/intel/pinctrl-tangier.c b/drivers/pinctrl/intel/pinctrl-tangier.c
> index 40dd60c9e526..007bca1cf224 100644
> --- a/drivers/pinctrl/intel/pinctrl-tangier.c
> +++ b/drivers/pinctrl/intel/pinctrl-tangier.c
> @@ -382,6 +382,9 @@ static int tng_config_set_pin(struct tng_pinctrl *tp, unsigned int pin,
> case 2000:
> term = BUFCFG_PUPD_VAL_2K;
> break;
> + case 910:
> + term = BUFCFG_PUPD_VAL_910;
> + break;
> default:
> return -EINVAL;
> }
> @@ -405,6 +408,9 @@ static int tng_config_set_pin(struct tng_pinctrl *tp, unsigned int pin,
> case 2000:
> term = BUFCFG_PUPD_VAL_2K;
> break;
> + case 910:
> + term = BUFCFG_PUPD_VAL_910;
> + break;
> default:
> return -EINVAL;
> }

Ah, I failed to notice this was already preset in the getter.

Looks good,
Raag

2023-10-31 13:59:44

by Raag Jadav

[permalink] [raw]
Subject: Re: [PATCH v1 1/1] pinctrl: tangier: Enable 910 Ohm bias

On Mon, Oct 30, 2023 at 11:35:42PM +0200, Raag Jadav wrote:
> On Mon, Oct 30, 2023 at 04:14:04PM +0200, Andy Shevchenko wrote:
> > Family 7 (I2C) supports special bias value, i.e. 910 Ohm.
> >
> > Enable it for configuring pin.
> >
> > Signed-off-by: Andy Shevchenko <[email protected]>
> > ---
> > drivers/pinctrl/intel/pinctrl-tangier.c | 6 ++++++
> > 1 file changed, 6 insertions(+)
> >
> > diff --git a/drivers/pinctrl/intel/pinctrl-tangier.c b/drivers/pinctrl/intel/pinctrl-tangier.c
> > index 40dd60c9e526..007bca1cf224 100644
> > --- a/drivers/pinctrl/intel/pinctrl-tangier.c
> > +++ b/drivers/pinctrl/intel/pinctrl-tangier.c
> > @@ -382,6 +382,9 @@ static int tng_config_set_pin(struct tng_pinctrl *tp, unsigned int pin,
> > case 2000:
> > term = BUFCFG_PUPD_VAL_2K;
> > break;
> > + case 910:
> > + term = BUFCFG_PUPD_VAL_910;
> > + break;
> > default:
> > return -EINVAL;
> > }
> > @@ -405,6 +408,9 @@ static int tng_config_set_pin(struct tng_pinctrl *tp, unsigned int pin,
> > case 2000:
> > term = BUFCFG_PUPD_VAL_2K;
> > break;
> > + case 910:
> > + term = BUFCFG_PUPD_VAL_910;
> > + break;
> > default:
> > return -EINVAL;
> > }
>
> Ah, I failed to notice this was already present in the getter.
>
> Looks good,

Reviewed-by: Raag Jadav <[email protected]>

2023-11-01 06:34:24

by Mika Westerberg

[permalink] [raw]
Subject: Re: [PATCH v1 1/1] pinctrl: tangier: Enable 910 Ohm bias

On Mon, Oct 30, 2023 at 04:14:04PM +0200, Andy Shevchenko wrote:
> Family 7 (I2C) supports special bias value, i.e. 910 Ohm.
>
> Enable it for configuring pin.
>
> Signed-off-by: Andy Shevchenko <[email protected]>

Acked-by: Mika Westerberg <[email protected]>

2023-11-02 07:32:15

by Linus Walleij

[permalink] [raw]
Subject: Re: [PATCH v1 1/1] pinctrl: tangier: Enable 910 Ohm bias

On Mon, Oct 30, 2023 at 3:14 PM Andy Shevchenko
<[email protected]> wrote:

> Family 7 (I2C) supports special bias value, i.e. 910 Ohm.
>
> Enable it for configuring pin.
>
> Signed-off-by: Andy Shevchenko <[email protected]>

Neat,
Reviewed-by: Linus Walleij <[email protected]>

Yours,
Linus Walleij