From: "andriy.shevchenko@intel.com" <andriy.shevchenko@intel.com>
To: "Miclaus, Antoniu" <Antoniu.Miclaus@analog.com>
Cc: Jonathan Cameron <jic23@kernel.org>,
Andy Shevchenko <andy.shevchenko@gmail.com>,
SeungJu Cheon <suunj1331@gmail.com>,
"lars@metafoo.de" <lars@metafoo.de>,
David Lechner <dlechner@baylibre.com>,
"andy@kernel.org" <andy@kernel.org>,
"linux-iio@vger.kernel.org" <linux-iio@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"Hennerich, Michael" <Michael.Hennerich@analog.com>,
"Sa, Nuno" <Nuno.Sa@analog.com>
Subject: Re: [PATCH v2] iio:frequency:adf4377: Fix duplicated soft reset mask
Date: Fri, 23 Jan 2026 13:06:43 +0200 [thread overview]
Message-ID: <aXNWQ-ocutEQoPJz@smile.fi.intel.com> (raw)
In-Reply-To: <CY4PR03MB3399B1BF1A562DD3FBDF43179B94A@CY4PR03MB3399.namprd03.prod.outlook.com>
On Fri, Jan 23, 2026 at 10:08:54AM +0000, Miclaus, Antoniu wrote:
> > From: Jonathan Cameron <jic23@kernel.org>
> > Sent: Friday, January 23, 2026 11:44 AM
> > On Sun, 11 Jan 2026 12:09:25 +0000
> > Jonathan Cameron <jic23@kernel.org> wrote:
> > > On Wed, 31 Dec 2025 13:19:46 +0200
> > > Andy Shevchenko <andy.shevchenko@gmail.com> wrote:
> > > > On Tue, Dec 30, 2025 at 3:21 PM SeungJu Cheon
> > <suunj1331@gmail.com> wrote:
...
> > > > May I ask how you tested this? Logically from the code it sounds
> > > > correct, but I haven't read the datasheet yet, so I can't tell if this
> > > > is the expected value to read or not.
> > > >
> > > >
> > > > > return regmap_read_poll_timeout(st->regmap, 0x0, read_val,
> > > > > - !(read_val & (ADF4377_0000_SOFT_RESET_R_MSK
> > |
> > > > > + !(read_val & (ADF4377_0000_SOFT_RESET_MSK |
> > > > > ADF4377_0000_SOFT_RESET_R_MSK)), 200, 200 *
> > 100);
> > > >
> > > > Okay, I opened the datasheet, and the below is what I read there. The
> > > > code first sets the SOFT_RESET_R and SOFT_RESET bits to "1", and waits
> > > > for them to be cleared. But the Table 43 does not mention that
> > > > SOFT_RESET_R is auto cleaned, and actually I don't see with a brief
> > > > look what the "repeat of" term means.
> > > >
> > > > And for normal operation they needs to be 0ed as per:
> > > > "SOFT_RESET, SOFT_RESET_R, RST_SYS, and ADC_ST_CNV are the only
> > > > remaining RW bit fields not mentioned yet, and must also be set to
> > > > their POR state (see Table 34)."
> > > >
> > > > With that said, I would wait for AD people to clarify the programming
> > > > workflow here.
> > >
> > > Small kernel development process thing as well. Please don't send a v2 in
> > reply to a v1.
> > > It can become very confusing if we end up with a larger number of versions.
> > > Much better to just post a new thread for each version, and include
> > > a link back to the lore archive of the previous version in your cover letter.
> > >
> > > Also from a practical point of view, it ends up pages up in people's inboxes
> > and
> > > so is is less likely to get reviewed!
> > >
> > ADI folk. This is waiting for one of you to take a look at the questions Andy
> > raised.
>
> Yep, it's a straightforward copy-paste typo - SOFT_RESET_R_MSK is OR'd with
> itself, so we're only checking BIT(7). Since we set both bits before polling,
> we should be waiting for both to clear.
Can you clarify more on this, please? Datasheet is unclear about the second bit
to be self-cleared.
And are you going to fix documentation (Datasheet)?
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2026-01-23 11:06 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-30 12:36 [PATCH] iio:frequency:adf4377: Fix duplicated soft reset mask SeungJu Cheon
2025-12-30 12:57 ` Andy Shevchenko
2025-12-30 13:21 ` [PATCH v2] " SeungJu Cheon
2025-12-31 11:19 ` Andy Shevchenko
2026-01-11 12:09 ` Jonathan Cameron
2026-01-23 9:44 ` Jonathan Cameron
2026-01-23 10:08 ` Miclaus, Antoniu
2026-01-23 11:06 ` andriy.shevchenko [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-01-23 11:56 SeungJu Cheon
2026-01-23 14:35 ` Andy Shevchenko
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=aXNWQ-ocutEQoPJz@smile.fi.intel.com \
--to=andriy.shevchenko@intel.com \
--cc=Antoniu.Miclaus@analog.com \
--cc=Michael.Hennerich@analog.com \
--cc=Nuno.Sa@analog.com \
--cc=andy.shevchenko@gmail.com \
--cc=andy@kernel.org \
--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=suunj1331@gmail.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