drivers/iio/adc/ad7944.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Add AD7944_ namespace to T_QUIET_NS. This is the preferred style. This
way the bad style won't be copied when we add more T_ macros.
Signed-off-by: David Lechner <dlechner@baylibre.com>
---
drivers/iio/adc/ad7944.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/iio/adc/ad7944.c b/drivers/iio/adc/ad7944.c
index 0f36138a7144..a5aea4e9f1a7 100644
--- a/drivers/iio/adc/ad7944.c
+++ b/drivers/iio/adc/ad7944.c
@@ -80,7 +80,7 @@ struct ad7944_adc {
};
/* quite time before CNV rising edge */
-#define T_QUIET_NS 20
+#define AD7944_T_QUIET_NS 20
static const struct ad7944_timing_spec ad7944_timing_spec = {
.conv_ns = 420,
@@ -150,7 +150,7 @@ static int ad7944_3wire_cs_mode_init_msg(struct device *dev, struct ad7944_adc *
* CS is tied to CNV and we need a low to high transition to start the
* conversion, so place CNV low for t_QUIET to prepare for this.
*/
- xfers[0].delay.value = T_QUIET_NS;
+ xfers[0].delay.value = AD7944_T_QUIET_NS;
xfers[0].delay.unit = SPI_DELAY_UNIT_NSECS;
/*
---
base-commit: 96be67caa0f0420d4128cb67f07bbd7a6f49e03a
change-id: 20241009-iio-adc-ad7944-add-namespace-to-t_quiet_ns-a9ed69692718
Best regards,
--
David Lechner <dlechner@baylibre.com>
On Wed, 2024-10-09 at 16:26 -0500, David Lechner wrote:
> Add AD7944_ namespace to T_QUIET_NS. This is the preferred style. This
> way the bad style won't be copied when we add more T_ macros.
>
> Signed-off-by: David Lechner <dlechner@baylibre.com>
> ---
Reviewed-by: Nuno Sa <nuno.sa@analog.com>
> drivers/iio/adc/ad7944.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/iio/adc/ad7944.c b/drivers/iio/adc/ad7944.c
> index 0f36138a7144..a5aea4e9f1a7 100644
> --- a/drivers/iio/adc/ad7944.c
> +++ b/drivers/iio/adc/ad7944.c
> @@ -80,7 +80,7 @@ struct ad7944_adc {
> };
>
> /* quite time before CNV rising edge */
> -#define T_QUIET_NS 20
> +#define AD7944_T_QUIET_NS 20
>
> static const struct ad7944_timing_spec ad7944_timing_spec = {
> .conv_ns = 420,
> @@ -150,7 +150,7 @@ static int ad7944_3wire_cs_mode_init_msg(struct device
> *dev, struct ad7944_adc *
> * CS is tied to CNV and we need a low to high transition to start
> the
> * conversion, so place CNV low for t_QUIET to prepare for this.
> */
> - xfers[0].delay.value = T_QUIET_NS;
> + xfers[0].delay.value = AD7944_T_QUIET_NS;
> xfers[0].delay.unit = SPI_DELAY_UNIT_NSECS;
>
> /*
>
> ---
> base-commit: 96be67caa0f0420d4128cb67f07bbd7a6f49e03a
> change-id: 20241009-iio-adc-ad7944-add-namespace-to-t_quiet_ns-a9ed69692718
>
> Best regards,
On Thu, 10 Oct 2024 10:32:44 +0200
Nuno Sá <noname.nuno@gmail.com> wrote:
> On Wed, 2024-10-09 at 16:26 -0500, David Lechner wrote:
> > Add AD7944_ namespace to T_QUIET_NS. This is the preferred style. This
> > way the bad style won't be copied when we add more T_ macros.
> >
> > Signed-off-by: David Lechner <dlechner@baylibre.com>
> > ---
>
> Reviewed-by: Nuno Sa <nuno.sa@analog.com>
Applied to the togreg branch of iio.git.
Thanks,
Jonathan
>
> > drivers/iio/adc/ad7944.c | 4 ++--
> > 1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/iio/adc/ad7944.c b/drivers/iio/adc/ad7944.c
> > index 0f36138a7144..a5aea4e9f1a7 100644
> > --- a/drivers/iio/adc/ad7944.c
> > +++ b/drivers/iio/adc/ad7944.c
> > @@ -80,7 +80,7 @@ struct ad7944_adc {
> > };
> >
> > /* quite time before CNV rising edge */
> > -#define T_QUIET_NS 20
> > +#define AD7944_T_QUIET_NS 20
> >
> > static const struct ad7944_timing_spec ad7944_timing_spec = {
> > .conv_ns = 420,
> > @@ -150,7 +150,7 @@ static int ad7944_3wire_cs_mode_init_msg(struct device
> > *dev, struct ad7944_adc *
> > * CS is tied to CNV and we need a low to high transition to start
> > the
> > * conversion, so place CNV low for t_QUIET to prepare for this.
> > */
> > - xfers[0].delay.value = T_QUIET_NS;
> > + xfers[0].delay.value = AD7944_T_QUIET_NS;
> > xfers[0].delay.unit = SPI_DELAY_UNIT_NSECS;
> >
> > /*
> >
> > ---
> > base-commit: 96be67caa0f0420d4128cb67f07bbd7a6f49e03a
> > change-id: 20241009-iio-adc-ad7944-add-namespace-to-t_quiet_ns-a9ed69692718
> >
> > Best regards,
>
© 2016 - 2026 Red Hat, Inc.