From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Mark Brown <broonie@kernel.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Regmap and register ranges
Date: Fri, 17 May 2013 14:52:46 -0700 [thread overview]
Message-ID: <20130517215246.GA24730@core.coreip.homeip.net> (raw)
In-Reply-To: <20130517205025.GQ1627@sirena.org.uk>
On Fri, May 17, 2013 at 09:50:25PM +0100, Mark Brown wrote:
> On Fri, May 17, 2013 at 09:24:30AM -0700, Dmitry Torokhov wrote:
>
> > I am looking at regmap and I wonder if I am missing something with the
> > way it checks if a window crosses another range boundary or if a
> > selector is in some other window as it seem to be always tripping on
> > itself. Should we skip the current range as we iterate through them
> > and do sanity checks?
>
> > The setup: a device with 0x0000 - 0xffff potential register range, paged
> > in chunks of 256 registers with page selector register repeated at 0xff.
>
> The general idea is that the pages should be mapped in to virtual
> addresses rather than real ones so in your example you might add a
> prefix so all the registers are numbered 0x10000 to 0x1ffff. The
> physical registers and the ones inside the paged range aren't supposed
> to overlap.
The issue I have with doing an arbitrary offset is that then data
exposed in debugfs does not match the data from device's specification.
>
> We should probably either do sanity checks for this at init time or come
> up with a sensible way to support this in case someone does decide to do
> it, though this is the first time anyone noticed.
Does this mean you'll be open to patches allowing this scenario?
Thanks.
--
Dmitry
next parent reply other threads:[~2013-05-17 21:53 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1657392.sx3qBqNYrh@dtor-d630.eng.vmware.com>
[not found] ` <20130517205025.GQ1627@sirena.org.uk>
2013-05-17 21:52 ` Dmitry Torokhov [this message]
2013-05-18 11:23 ` 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=20130517215246.GA24730@core.coreip.homeip.net \
--to=dmitry.torokhov@gmail.com \
--cc=broonie@kernel.org \
--cc=linux-kernel@vger.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
Powered by JetHome