mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andy Shevchenko <andy@kernel.org>
To: Angelo Dureghello <adureghello@baylibre.com>
Cc: Nuno Sa <nuno.sa@analog.com>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Michael Hennerich <Michael.Hennerich@analog.com>,
	Jonathan Cameron <jic23@kernel.org>,
	David Lechner <dlechner@baylibre.com>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
	Jonathan Cameron <Jonathan.Cameron@huawei.com>
Subject: Re: [PATCH v2 1/2] iio: dac: adi-axi-dac: fix bus read
Date: Wed, 9 Apr 2025 19:49:25 +0300	[thread overview]
Message-ID: <Z_alFXGBhFxk-h0e@smile.fi.intel.com> (raw)
In-Reply-To: <20250409-ad3552r-fix-bus-read-v2-1-34d3b21e8ca0@baylibre.com>

On Wed, Apr 09, 2025 at 11:16:54AM +0200, Angelo Dureghello wrote:
> From: Angelo Dureghello <adureghello@baylibre.com>
> 
> Fix bus read function.
> 
> Testing the driver, on a random basis, wrong reads was detected, mainly
> by a wrong DAC chip ID read at first boot.
> Before reading the expected value from the AXI regmap, need always to
> wait for busy flag to be cleared.

...

> +	ret = regmap_read_poll_timeout(st->regmap,
> +				AXI_DAC_UI_STATUS_REG, ival,
> +				FIELD_GET(AXI_DAC_UI_STATUS_IF_BUSY, ival) == 0,
> +				10, 100 * KILO);

It's timeout, we have special constants for that, I believe you wanted to have
USEC_PER_MSEC here.

> +	if (ret)
> +		return ret;

-- 
With Best Regards,
Andy Shevchenko



  reply	other threads:[~2025-04-09 16:49 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-09  9:16 [PATCH v2 0/2] iio: dac: adi-axi-dac: fix for wrong " Angelo Dureghello
2025-04-09  9:16 ` [PATCH v2 1/2] iio: dac: adi-axi-dac: fix " Angelo Dureghello
2025-04-09 16:49   ` Andy Shevchenko [this message]
2025-04-12 13:00     ` Jonathan Cameron
2025-04-12 18:03       ` Andy Shevchenko
2025-04-09  9:16 ` [PATCH v2 2/2] iio: dac: adi-axi-dac: use unique bus free check Angelo Dureghello
2025-04-09 16:51   ` Andy Shevchenko
2025-04-29 14:32     ` Angelo Dureghello
2025-04-29 22:05       ` Andy Shevchenko
2025-04-30 14:15         ` Angelo Dureghello
2025-04-09 13:57 ` [PATCH v2 0/2] iio: dac: adi-axi-dac: fix for wrong bus read Nuno Sá
2025-04-22  8:41   ` Angelo Dureghello
2025-05-05 11:33   ` Angelo Dureghello
2025-05-05 12:38     ` Jonathan Cameron
2025-05-19 19:03       ` Angelo Dureghello

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=Z_alFXGBhFxk-h0e@smile.fi.intel.com \
    --to=andy@kernel.org \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=Michael.Hennerich@analog.com \
    --cc=adureghello@baylibre.com \
    --cc=dlechner@baylibre.com \
    --cc=jic23@kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nuno.sa@analog.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®