* [PATCH V2] iio: frequency: ad9523: Fix typo in ad9523_platform_data
@ 2019-03-26 13:40 Alexandru Ardelean
2019-03-30 16:04 ` Jonathan Cameron
0 siblings, 1 reply; 3+ messages in thread
From: Alexandru Ardelean @ 2019-03-26 13:40 UTC (permalink / raw)
To: linux-iio; +Cc: Lars-Peter Clausen, Alexandru Ardelean
From: Lars-Peter Clausen <lars@metafoo.de>
Replace diff_{m1,m2} with div_{m1,m2} since they are dividers and not a
differential settings.
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
---
Changelog v1->v2:
* added `frequency:` to prefix for consistency
drivers/iio/frequency/ad9523.c | 16 ++++++++--------
include/linux/iio/frequency/ad9523.h | 8 ++++----
2 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/drivers/iio/frequency/ad9523.c b/drivers/iio/frequency/ad9523.c
index 3f9be69499ec..9b9eee27176c 100644
--- a/drivers/iio/frequency/ad9523.c
+++ b/drivers/iio/frequency/ad9523.c
@@ -872,22 +872,22 @@ static int ad9523_setup(struct iio_dev *indio_dev)
return ret;
ret = ad9523_write(indio_dev, AD9523_PLL2_VCO_DIVIDER,
- AD9523_PLL2_VCO_DIV_M1(pdata->pll2_vco_diff_m1) |
- AD9523_PLL2_VCO_DIV_M2(pdata->pll2_vco_diff_m2) |
- AD_IFE(pll2_vco_diff_m1, 0,
+ AD9523_PLL2_VCO_DIV_M1(pdata->pll2_vco_div_m1) |
+ AD9523_PLL2_VCO_DIV_M2(pdata->pll2_vco_div_m2) |
+ AD_IFE(pll2_vco_div_m1, 0,
AD9523_PLL2_VCO_DIV_M1_PWR_DOWN_EN) |
- AD_IFE(pll2_vco_diff_m2, 0,
+ AD_IFE(pll2_vco_div_m2, 0,
AD9523_PLL2_VCO_DIV_M2_PWR_DOWN_EN));
if (ret < 0)
return ret;
- if (pdata->pll2_vco_diff_m1)
+ if (pdata->pll2_vco_div_m1)
st->vco_out_freq[AD9523_VCO1] =
- st->vco_freq / pdata->pll2_vco_diff_m1;
+ st->vco_freq / pdata->pll2_vco_div_m1;
- if (pdata->pll2_vco_diff_m2)
+ if (pdata->pll2_vco_div_m2)
st->vco_out_freq[AD9523_VCO2] =
- st->vco_freq / pdata->pll2_vco_diff_m2;
+ st->vco_freq / pdata->pll2_vco_div_m2;
st->vco_out_freq[AD9523_VCXO] = pdata->vcxo_freq;
diff --git a/include/linux/iio/frequency/ad9523.h b/include/linux/iio/frequency/ad9523.h
index 12ce3ee427fd..621b93c0bcf9 100644
--- a/include/linux/iio/frequency/ad9523.h
+++ b/include/linux/iio/frequency/ad9523.h
@@ -129,8 +129,8 @@ enum cpole1_capacitor {
* @pll2_ndiv_b_cnt: PLL2 Feedback N-divider, B Counter, range 0..63.
* @pll2_freq_doubler_en: PLL2 frequency doubler enable.
* @pll2_r2_div: PLL2 R2 divider, range 0..31.
- * @pll2_vco_diff_m1: VCO1 divider, range 3..5.
- * @pll2_vco_diff_m2: VCO2 divider, range 3..5.
+ * @pll2_vco_div_m1: VCO1 divider, range 3..5.
+ * @pll2_vco_div_m2: VCO2 divider, range 3..5.
* @rpole2: PLL2 loop filter Rpole resistor value.
* @rzero: PLL2 loop filter Rzero resistor value.
* @cpole1: PLL2 loop filter Cpole capacitor value.
@@ -176,8 +176,8 @@ struct ad9523_platform_data {
unsigned char pll2_ndiv_b_cnt;
bool pll2_freq_doubler_en;
unsigned char pll2_r2_div;
- unsigned char pll2_vco_diff_m1; /* 3..5 */
- unsigned char pll2_vco_diff_m2; /* 3..5 */
+ unsigned char pll2_vco_div_m1; /* 3..5 */
+ unsigned char pll2_vco_div_m2; /* 3..5 */
/* Loop Filter PLL2 */
enum rpole2_resistor rpole2;
--
2.17.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH V2] iio: frequency: ad9523: Fix typo in ad9523_platform_data
2019-03-26 13:40 [PATCH V2] iio: frequency: ad9523: Fix typo in ad9523_platform_data Alexandru Ardelean
@ 2019-03-30 16:04 ` Jonathan Cameron
2019-04-01 6:05 ` Ardelean, Alexandru
0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Cameron @ 2019-03-30 16:04 UTC (permalink / raw)
To: Alexandru Ardelean; +Cc: linux-iio, Lars-Peter Clausen
On Tue, 26 Mar 2019 15:40:03 +0200
Alexandru Ardelean <alexandru.ardelean@analog.com> wrote:
> From: Lars-Peter Clausen <lars@metafoo.de>
>
> Replace diff_{m1,m2} with div_{m1,m2} since they are dividers and not a
> differential settings.
>
> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Applied to the togreg branch of iio.git and pushed out as testing
for no particular reason.
Note that it would be helpful if, when you post a new version of a
patch despite (I think) no replies to the previous, that you also
reply to that thread to say there is a v2. Sometimes I run forwards
through my emails and would have applied that before seeing this.
Thanks,
Jonathan
> ---
>
> Changelog v1->v2:
> * added `frequency:` to prefix for consistency
>
> drivers/iio/frequency/ad9523.c | 16 ++++++++--------
> include/linux/iio/frequency/ad9523.h | 8 ++++----
> 2 files changed, 12 insertions(+), 12 deletions(-)
>
> diff --git a/drivers/iio/frequency/ad9523.c b/drivers/iio/frequency/ad9523.c
> index 3f9be69499ec..9b9eee27176c 100644
> --- a/drivers/iio/frequency/ad9523.c
> +++ b/drivers/iio/frequency/ad9523.c
> @@ -872,22 +872,22 @@ static int ad9523_setup(struct iio_dev *indio_dev)
> return ret;
>
> ret = ad9523_write(indio_dev, AD9523_PLL2_VCO_DIVIDER,
> - AD9523_PLL2_VCO_DIV_M1(pdata->pll2_vco_diff_m1) |
> - AD9523_PLL2_VCO_DIV_M2(pdata->pll2_vco_diff_m2) |
> - AD_IFE(pll2_vco_diff_m1, 0,
> + AD9523_PLL2_VCO_DIV_M1(pdata->pll2_vco_div_m1) |
> + AD9523_PLL2_VCO_DIV_M2(pdata->pll2_vco_div_m2) |
> + AD_IFE(pll2_vco_div_m1, 0,
> AD9523_PLL2_VCO_DIV_M1_PWR_DOWN_EN) |
> - AD_IFE(pll2_vco_diff_m2, 0,
> + AD_IFE(pll2_vco_div_m2, 0,
> AD9523_PLL2_VCO_DIV_M2_PWR_DOWN_EN));
> if (ret < 0)
> return ret;
>
> - if (pdata->pll2_vco_diff_m1)
> + if (pdata->pll2_vco_div_m1)
> st->vco_out_freq[AD9523_VCO1] =
> - st->vco_freq / pdata->pll2_vco_diff_m1;
> + st->vco_freq / pdata->pll2_vco_div_m1;
>
> - if (pdata->pll2_vco_diff_m2)
> + if (pdata->pll2_vco_div_m2)
> st->vco_out_freq[AD9523_VCO2] =
> - st->vco_freq / pdata->pll2_vco_diff_m2;
> + st->vco_freq / pdata->pll2_vco_div_m2;
>
> st->vco_out_freq[AD9523_VCXO] = pdata->vcxo_freq;
>
> diff --git a/include/linux/iio/frequency/ad9523.h b/include/linux/iio/frequency/ad9523.h
> index 12ce3ee427fd..621b93c0bcf9 100644
> --- a/include/linux/iio/frequency/ad9523.h
> +++ b/include/linux/iio/frequency/ad9523.h
> @@ -129,8 +129,8 @@ enum cpole1_capacitor {
> * @pll2_ndiv_b_cnt: PLL2 Feedback N-divider, B Counter, range 0..63.
> * @pll2_freq_doubler_en: PLL2 frequency doubler enable.
> * @pll2_r2_div: PLL2 R2 divider, range 0..31.
> - * @pll2_vco_diff_m1: VCO1 divider, range 3..5.
> - * @pll2_vco_diff_m2: VCO2 divider, range 3..5.
> + * @pll2_vco_div_m1: VCO1 divider, range 3..5.
> + * @pll2_vco_div_m2: VCO2 divider, range 3..5.
> * @rpole2: PLL2 loop filter Rpole resistor value.
> * @rzero: PLL2 loop filter Rzero resistor value.
> * @cpole1: PLL2 loop filter Cpole capacitor value.
> @@ -176,8 +176,8 @@ struct ad9523_platform_data {
> unsigned char pll2_ndiv_b_cnt;
> bool pll2_freq_doubler_en;
> unsigned char pll2_r2_div;
> - unsigned char pll2_vco_diff_m1; /* 3..5 */
> - unsigned char pll2_vco_diff_m2; /* 3..5 */
> + unsigned char pll2_vco_div_m1; /* 3..5 */
> + unsigned char pll2_vco_div_m2; /* 3..5 */
>
> /* Loop Filter PLL2 */
> enum rpole2_resistor rpole2;
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH V2] iio: frequency: ad9523: Fix typo in ad9523_platform_data
2019-03-30 16:04 ` Jonathan Cameron
@ 2019-04-01 6:05 ` Ardelean, Alexandru
0 siblings, 0 replies; 3+ messages in thread
From: Ardelean, Alexandru @ 2019-04-01 6:05 UTC (permalink / raw)
To: jic23@jic23.retrosnub.co.uk; +Cc: lars@metafoo.de, linux-iio@vger.kernel.org
On Sat, 2019-03-30 at 16:04 +0000, Jonathan Cameron wrote:
> [External]
>
>
> On Tue, 26 Mar 2019 15:40:03 +0200
> Alexandru Ardelean <alexandru.ardelean@analog.com> wrote:
>
> > From: Lars-Peter Clausen <lars@metafoo.de>
> >
> > Replace diff_{m1,m2} with div_{m1,m2} since they are dividers and not a
> > differential settings.
> >
> > Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
> > Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
>
> Applied to the togreg branch of iio.git and pushed out as testing
> for no particular reason.
>
> Note that it would be helpful if, when you post a new version of a
> patch despite (I think) no replies to the previous, that you also
> reply to that thread to say there is a v2. Sometimes I run forwards
> through my emails and would have applied that before seeing this.
>
Ack.
Will try to remember this.
Thanks
Alex
> Thanks,
>
> Jonathan
>
> > ---
> >
> > Changelog v1->v2:
> > * added `frequency:` to prefix for consistency
> >
> > drivers/iio/frequency/ad9523.c | 16 ++++++++--------
> > include/linux/iio/frequency/ad9523.h | 8 ++++----
> > 2 files changed, 12 insertions(+), 12 deletions(-)
> >
> > diff --git a/drivers/iio/frequency/ad9523.c
> > b/drivers/iio/frequency/ad9523.c
> > index 3f9be69499ec..9b9eee27176c 100644
> > --- a/drivers/iio/frequency/ad9523.c
> > +++ b/drivers/iio/frequency/ad9523.c
> > @@ -872,22 +872,22 @@ static int ad9523_setup(struct iio_dev
> > *indio_dev)
> > return ret;
> >
> > ret = ad9523_write(indio_dev, AD9523_PLL2_VCO_DIVIDER,
> > - AD9523_PLL2_VCO_DIV_M1(pdata->pll2_vco_diff_m1) |
> > - AD9523_PLL2_VCO_DIV_M2(pdata->pll2_vco_diff_m2) |
> > - AD_IFE(pll2_vco_diff_m1, 0,
> > + AD9523_PLL2_VCO_DIV_M1(pdata->pll2_vco_div_m1) |
> > + AD9523_PLL2_VCO_DIV_M2(pdata->pll2_vco_div_m2) |
> > + AD_IFE(pll2_vco_div_m1, 0,
> > AD9523_PLL2_VCO_DIV_M1_PWR_DOWN_EN) |
> > - AD_IFE(pll2_vco_diff_m2, 0,
> > + AD_IFE(pll2_vco_div_m2, 0,
> > AD9523_PLL2_VCO_DIV_M2_PWR_DOWN_EN));
> > if (ret < 0)
> > return ret;
> >
> > - if (pdata->pll2_vco_diff_m1)
> > + if (pdata->pll2_vco_div_m1)
> > st->vco_out_freq[AD9523_VCO1] =
> > - st->vco_freq / pdata->pll2_vco_diff_m1;
> > + st->vco_freq / pdata->pll2_vco_div_m1;
> >
> > - if (pdata->pll2_vco_diff_m2)
> > + if (pdata->pll2_vco_div_m2)
> > st->vco_out_freq[AD9523_VCO2] =
> > - st->vco_freq / pdata->pll2_vco_diff_m2;
> > + st->vco_freq / pdata->pll2_vco_div_m2;
> >
> > st->vco_out_freq[AD9523_VCXO] = pdata->vcxo_freq;
> >
> > diff --git a/include/linux/iio/frequency/ad9523.h
> > b/include/linux/iio/frequency/ad9523.h
> > index 12ce3ee427fd..621b93c0bcf9 100644
> > --- a/include/linux/iio/frequency/ad9523.h
> > +++ b/include/linux/iio/frequency/ad9523.h
> > @@ -129,8 +129,8 @@ enum cpole1_capacitor {
> > * @pll2_ndiv_b_cnt: PLL2 Feedback N-divider, B Counter, range 0..63.
> > * @pll2_freq_doubler_en: PLL2 frequency doubler enable.
> > * @pll2_r2_div: PLL2 R2 divider, range 0..31.
> > - * @pll2_vco_diff_m1: VCO1 divider, range 3..5.
> > - * @pll2_vco_diff_m2: VCO2 divider, range 3..5.
> > + * @pll2_vco_div_m1: VCO1 divider, range 3..5.
> > + * @pll2_vco_div_m2: VCO2 divider, range 3..5.
> > * @rpole2: PLL2 loop filter Rpole resistor value.
> > * @rzero: PLL2 loop filter Rzero resistor value.
> > * @cpole1: PLL2 loop filter Cpole capacitor value.
> > @@ -176,8 +176,8 @@ struct ad9523_platform_data {
> > unsigned char pll2_ndiv_b_cnt;
> > bool pll2_freq_doubler_en;
> > unsigned char pll2_r2_div;
> > - unsigned char pll2_vco_diff_m1; /* 3..5 */
> > - unsigned char pll2_vco_diff_m2; /* 3..5 */
> > + unsigned char pll2_vco_div_m1; /* 3..5 */
> > + unsigned char pll2_vco_div_m2; /* 3..5 */
> >
> > /* Loop Filter PLL2 */
> > enum rpole2_resistor rpole2;
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-04-01 6:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-03-26 13:40 [PATCH V2] iio: frequency: ad9523: Fix typo in ad9523_platform_data Alexandru Ardelean
2019-03-30 16:04 ` Jonathan Cameron
2019-04-01 6:05 ` Ardelean, Alexandru
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox