From: Mark Brown <broonie@kernel.org>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
Aidan MacDonald <aidanmacdonald.0x0@gmail.com>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
"Rafael J. Wysocki" <rafael@kernel.org>
Subject: Re: [PATCH v1 5/5] regmap: mmio: Introduce IO accessors that can talk to IO port
Date: Mon, 8 Aug 2022 17:04:58 +0100 [thread overview]
Message-ID: <YvE0KroZDQuPVd+V@sirena.org.uk> (raw)
In-Reply-To: <CAHp75VeA8tA-m_gHu5iuhriSfm_qo1PRnUWe7kQ68CCm+UCgHA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1736 bytes --]
On Mon, Aug 08, 2022 at 04:40:26PM +0200, Andy Shevchenko wrote:
> On Mon, Aug 8, 2022 at 3:31 PM Mark Brown <broonie@kernel.org> wrote:
> > On Fri, Aug 05, 2022 at 11:53:21PM +0300, Andy Shevchenko wrote:
> > > Currently regmap MMIO is inconsistent with IO accessors. I.e.
> > > the Big Endian counterparts are using ioreadXXbe() / iowriteXXbe()
> > > which are not clean implementations of readXXbe(). Besides that
> > > some users may use regmap MMIO for IO ports, and this can be done
> > > by assigning ioreadXX()/iowriteXX() and their Big Endian counterparts
> > > to the regmap context.
> > Have you validated that nothing is relying on whatever the problem is
> > with using the io versions?
> I have cross-checked 1) the architectures that are BE and have IO port
> capability, and 2) the drivers that are using regmap MMIO with a
> big-endian setting. I found no driver is mapping IO ports and uses
> regmap MMIO at the same time. The architecture wise the x86 and ia64
> are not in question, I think. And alpha is more academical nowadays.
> Did I miss anything?
> That said, I'm 99.999% sure there is no problem with that.
The issue is the potential that something that is currently using the
ioport accessors might be relying on whatever it is that they do that
causes a problem.
> > > That said, reimplement current Big Endian MMIO accessors by replacing
> > > ioread()/iowrite() with respective read()/write() and swab() calls.
> > > While at it, add IO port support with a corresponding flag added.
> > This should be a separate patch.
> OK! Then we remove some code and (re-)add it later. Do we need this churn?
> Another way is to add IO port accessors and then fix the MMIO.
Add and then fix seems sensible,
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2022-08-08 16:05 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-05 20:53 [PATCH v1 1/5] regmap: mmio: Don't unprepare attached clock Andy Shevchenko
2022-08-05 20:53 ` [PATCH v1 2/5] regmap: mmio: Drop unneeded and duplicative checks around CLK calls Andy Shevchenko
2022-08-08 13:02 ` Mark Brown
2022-08-08 13:43 ` Andy Shevchenko
2022-08-05 20:53 ` [PATCH v1 3/5] regmap: mmio: Remove mmio_relaxed member from context Andy Shevchenko
2022-08-05 20:53 ` [PATCH v1 4/5] regmap: mmio: Get rid of broken 64-bit IO Andy Shevchenko
2022-08-05 20:53 ` [PATCH v1 5/5] regmap: mmio: Introduce IO accessors that can talk to IO port Andy Shevchenko
2022-08-05 21:22 ` Andy Shevchenko
2022-08-08 13:18 ` Mark Brown
2022-08-08 14:40 ` Andy Shevchenko
2022-08-08 16:04 ` Mark Brown [this message]
2022-08-08 18:39 ` Andy Shevchenko
2022-08-08 13:07 ` [PATCH v1 1/5] regmap: mmio: Don't unprepare attached clock Mark Brown
2022-08-08 13:41 ` Andy Shevchenko
2022-08-08 13:48 ` Mark Brown
2022-08-08 14:42 ` Andy Shevchenko
2022-08-08 15:52 ` Mark Brown
2022-08-08 18:23 ` Andy Shevchenko
2022-08-08 19:01 ` Mark Brown
2022-08-15 17:42 ` (subset) " Mark Brown
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=YvE0KroZDQuPVd+V@sirena.org.uk \
--to=broonie@kernel.org \
--cc=aidanmacdonald.0x0@gmail.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=andy.shevchenko@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rafael@kernel.org \
/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®