All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Eugen Hristev <eugen.hristev@microchip.com>
Cc: <nicolas.ferre@microchip.com>,
	<alexandre.belloni@free-electrons.com>,
	<linux-iio@vger.kernel.org>, <lars@metafoo.de>,
	<linux-arm-kernel@lists.infradead.org>,
	<devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<ludovic.desroches@microchip.com>
Subject: Re: [PATCH v2 5/5] iio: adc: at91-sama5d2_adc: use max sample rate
Date: Sun, 15 Oct 2017 11:28:47 +0100	[thread overview]
Message-ID: <20171015112847.5c035e7a@archlinux> (raw)
In-Reply-To: <1507703732-29175-6-git-send-email-eugen.hristev@microchip.com>

On Wed, 11 Oct 2017 09:35:32 +0300
Eugen Hristev <eugen.hristev@microchip.com> wrote:

> Change driver settings to use maximum sample rate clock.
> This is useful to achieve best possible sampling rate
> if we use DMA.
> 
> Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>

I would normally expect this to have some bearing on the 
noise levels on the measured signals.  All I can find
is a reference to the track time being 15*a single
clock cycle.  We could change this so that it is appropriate
for the currently samping frequency rather than leaving it
as a fixed value.

Jonathan

> ---
>  drivers/iio/adc/at91-sama5d2_adc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/adc/at91-sama5d2_adc.c b/drivers/iio/adc/at91-sama5d2_adc.c
> index 7e51ecb..b76f88f 100644
> --- a/drivers/iio/adc/at91-sama5d2_adc.c
> +++ b/drivers/iio/adc/at91-sama5d2_adc.c
> @@ -934,7 +934,7 @@ static void at91_adc_hw_init(struct at91_adc_state *st)
>  	at91_adc_writel(st, AT91_SAMA5D2_MR,
>  			AT91_SAMA5D2_MR_TRANSFER(2) | AT91_SAMA5D2_MR_ANACH);
>  
> -	at91_adc_setup_samp_freq(st, st->soc_info.min_sample_rate);
> +	at91_adc_setup_samp_freq(st, st->soc_info.max_sample_rate);
>  }
>  
>  static ssize_t at91_adc_get_fifo_state(struct device *dev,

WARNING: multiple messages have this Message-ID (diff)
From: Jonathan Cameron <jic23-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Eugen Hristev <eugen.hristev-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org>
Cc: nicolas.ferre-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org,
	alexandre.belloni-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org,
	linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	ludovic.desroches-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org
Subject: Re: [PATCH v2 5/5] iio: adc: at91-sama5d2_adc: use max sample rate
Date: Sun, 15 Oct 2017 11:28:47 +0100	[thread overview]
Message-ID: <20171015112847.5c035e7a@archlinux> (raw)
In-Reply-To: <1507703732-29175-6-git-send-email-eugen.hristev-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org>

On Wed, 11 Oct 2017 09:35:32 +0300
Eugen Hristev <eugen.hristev-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org> wrote:

> Change driver settings to use maximum sample rate clock.
> This is useful to achieve best possible sampling rate
> if we use DMA.
> 
> Signed-off-by: Eugen Hristev <eugen.hristev-UWL1GkI3JZL3oGB3hsPCZA@public.gmane.org>

I would normally expect this to have some bearing on the 
noise levels on the measured signals.  All I can find
is a reference to the track time being 15*a single
clock cycle.  We could change this so that it is appropriate
for the currently samping frequency rather than leaving it
as a fixed value.

Jonathan

> ---
>  drivers/iio/adc/at91-sama5d2_adc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/adc/at91-sama5d2_adc.c b/drivers/iio/adc/at91-sama5d2_adc.c
> index 7e51ecb..b76f88f 100644
> --- a/drivers/iio/adc/at91-sama5d2_adc.c
> +++ b/drivers/iio/adc/at91-sama5d2_adc.c
> @@ -934,7 +934,7 @@ static void at91_adc_hw_init(struct at91_adc_state *st)
>  	at91_adc_writel(st, AT91_SAMA5D2_MR,
>  			AT91_SAMA5D2_MR_TRANSFER(2) | AT91_SAMA5D2_MR_ANACH);
>  
> -	at91_adc_setup_samp_freq(st, st->soc_info.min_sample_rate);
> +	at91_adc_setup_samp_freq(st, st->soc_info.max_sample_rate);
>  }
>  
>  static ssize_t at91_adc_get_fifo_state(struct device *dev,

WARNING: multiple messages have this Message-ID (diff)
From: jic23@kernel.org (Jonathan Cameron)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 5/5] iio: adc: at91-sama5d2_adc: use max sample rate
Date: Sun, 15 Oct 2017 11:28:47 +0100	[thread overview]
Message-ID: <20171015112847.5c035e7a@archlinux> (raw)
In-Reply-To: <1507703732-29175-6-git-send-email-eugen.hristev@microchip.com>

On Wed, 11 Oct 2017 09:35:32 +0300
Eugen Hristev <eugen.hristev@microchip.com> wrote:

> Change driver settings to use maximum sample rate clock.
> This is useful to achieve best possible sampling rate
> if we use DMA.
> 
> Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>

I would normally expect this to have some bearing on the 
noise levels on the measured signals.  All I can find
is a reference to the track time being 15*a single
clock cycle.  We could change this so that it is appropriate
for the currently samping frequency rather than leaving it
as a fixed value.

Jonathan

> ---
>  drivers/iio/adc/at91-sama5d2_adc.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/adc/at91-sama5d2_adc.c b/drivers/iio/adc/at91-sama5d2_adc.c
> index 7e51ecb..b76f88f 100644
> --- a/drivers/iio/adc/at91-sama5d2_adc.c
> +++ b/drivers/iio/adc/at91-sama5d2_adc.c
> @@ -934,7 +934,7 @@ static void at91_adc_hw_init(struct at91_adc_state *st)
>  	at91_adc_writel(st, AT91_SAMA5D2_MR,
>  			AT91_SAMA5D2_MR_TRANSFER(2) | AT91_SAMA5D2_MR_ANACH);
>  
> -	at91_adc_setup_samp_freq(st, st->soc_info.min_sample_rate);
> +	at91_adc_setup_samp_freq(st, st->soc_info.max_sample_rate);
>  }
>  
>  static ssize_t at91_adc_get_fifo_state(struct device *dev,

  reply	other threads:[~2017-10-15 10:28 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-11  6:35 [PATCH v2 0/5] iio: adc: at91-sama5d2_adc: add DMA support Eugen Hristev
2017-10-11  6:35 ` Eugen Hristev
2017-10-11  6:35 ` Eugen Hristev
2017-10-11  6:35 ` [PATCH v2 1/5] dt-bindings: iio: at91-sama5d2_adc: add optional dma property Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-13 21:51   ` Rob Herring
2017-10-13 21:51     ` Rob Herring
2017-10-19 11:14     ` Alexandre Belloni
2017-10-19 11:14       ` Alexandre Belloni
2017-10-19 21:58       ` Rob Herring
2017-10-19 21:58         ` Rob Herring
2017-10-19 21:58         ` Rob Herring
2017-10-19 21:58         ` Rob Herring
2017-11-07  8:49         ` Eugen Hristev
2017-11-07  8:49           ` Eugen Hristev
2017-11-07  8:49           ` Eugen Hristev
2017-11-07  8:49           ` Eugen Hristev
2017-11-07  9:02           ` Ludovic Desroches
2017-11-07  9:02             ` Ludovic Desroches
2017-11-07  9:02             ` Ludovic Desroches
2017-10-11  6:35 ` [PATCH v2 2/5] ARM: dts: at91: sama5d2: added dma property for ADC device Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35 ` [PATCH v2 3/5] iio: adc: at91-sama5d2_adc: add support for DMA Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-15 10:16   ` Jonathan Cameron
2017-10-15 10:16     ` Jonathan Cameron
2017-10-15 10:16     ` Jonathan Cameron
2017-10-11  6:35 ` [PATCH v2 4/5] iio: adc: at91-sama5d2_adc: ack DRDY irq in direct mode Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35 ` [PATCH v2 5/5] iio: adc: at91-sama5d2_adc: use max sample rate Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-11  6:35   ` Eugen Hristev
2017-10-15 10:28   ` Jonathan Cameron [this message]
2017-10-15 10:28     ` Jonathan Cameron
2017-10-15 10:28     ` Jonathan Cameron
2017-10-18  8:49     ` Eugen Hristev
2017-10-18  8:49       ` Eugen Hristev
2017-10-18  8:49       ` Eugen Hristev

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171015112847.5c035e7a@archlinux \
    --to=jic23@kernel.org \
    --cc=alexandre.belloni@free-electrons.com \
    --cc=devicetree@vger.kernel.org \
    --cc=eugen.hristev@microchip.com \
    --cc=lars@metafoo.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ludovic.desroches@microchip.com \
    --cc=nicolas.ferre@microchip.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.