From: Mark Brown <broonie@kernel.org>
To: Chen-Yu Tsai <wens@csie.org>
Cc: Rob Herring <robh+dt@kernel.org>, Pawel Moll <pawel.moll@arm.com>,
Mark Rutland <mark.rutland@arm.com>,
Ian Campbell <ijc+devicetree@hellion.org.uk>,
Kumar Gala <galak@codeaurora.org>,
Maxime Ripard <maxime.ripard@free-electrons.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
devicetree <devicetree@vger.kernel.org>,
linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
linux-kernel <linux-kernel@vger.kernel.org>,
linux-sunxi <linux-sunxi@googlegroups.com>,
Hans de Goede <hdegoede@redhat.com>,
Shuge <shuge@allwinnertech.com>,
Meng Zhang <kevin.z.m.zh@gmail.com>
Subject: Re: [PATCH v3 0/8] ARM: sunxi: Add Reduced Serial Bus support
Date: Thu, 20 Aug 2015 10:02:11 -0700 [thread overview]
Message-ID: <20150820170211.GB12027@sirena.org.uk> (raw)
In-Reply-To: <CAGb2v66X-CMQiS1dNqhwamTsVbnf+7siSTV3xGwn-C91Zhw3uA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1800 bytes --]
On Thu, Aug 20, 2015 at 09:59:27AM +0800, Chen-Yu Tsai wrote:
> On Thu, Aug 20, 2015 at 12:32 AM, Mark Brown <broonie@kernel.org> wrote:
> > This is flagged as something that is specific to the Allwinner SoCs.
> > Why add generic regmap support rather than just implement the regmap
> > reg_read() and reg_write() in a regmap in the controller driver? Are
> > there expected to be other controller drivers from other vendors?
> I don't expect there to be any other controller drivers. And it seems
> at least some of the devices are dual interface (I2C/RSB). Though I
> don't see how its connected to the generic regmap support. Regmap
> is for device drivers connected to the RSB bus, not the bus controller
> itself.
The point here is that you can use regmap for a custom controller
without having to implement a bus, to repeat what I said:
| > Why add generic regmap support rather than just implement the regmap
| > reg_read() and reg_write() in a regmap in the controller driver? Are
> I could throw all the RSB-related stuff together, presumably under
> drivers/soc/sunxi/rsb, though that doesn't help the fact that common
> regmap code would be better than scattering regmap_* in various mfd
> drivers.
If there is only one controller driver you just have a single call into
that driver in the client device which gives you the same level of
shared code, having a wrapper layer in regmap that puts regmap_
functions around the equivalent controller specific functions isn't
really adding a huge amount.
It's a similar thing to the way we just reuse the platform bus for basic
buses rather than copying it to make new bus types, we don't need to
create lots of new boilerplate regmap types that are just really basic
wrappers. There are a lot of these custom buses that people have.
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
prev parent reply other threads:[~2015-08-20 17:02 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-19 4:20 Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 1/8] rsb: Add generic Reduced Serial Bus (RSB) controller binding documentation Chen-Yu Tsai
2015-08-20 15:08 ` Maxime Ripard
2015-08-20 15:58 ` Chen-Yu Tsai
2015-08-20 21:24 ` Maxime Ripard
2015-08-23 22:43 ` Rob Herring
2015-09-14 7:32 ` Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 2/8] rsb: sunxi: Add Allwinner Reduced Serial Bus (RSB) controller bindings Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 3/8] rsb: Linux driver framework for Reduced Serial Bus (RSB) Chen-Yu Tsai
2015-08-20 17:05 ` Mark Brown
2015-08-19 4:20 ` [PATCH v3 4/8] rsb: sunxi: Add driver for Allwinner Reduced Serial Bus controller Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 5/8] regmap: rsb: Add support for Reduced Serial Bus (RSB) based regmaps Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 6/8] ARM: dts: sun8i: Add Reduced Serial Bus controller device node to A23/A33 dtsi Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 7/8] ARM: dts: sun8i: ippo-q8h-v5: Enable Reduced Serial Bus controller Chen-Yu Tsai
2015-08-19 4:20 ` [PATCH v3 8/8] ARM: dts: sun8i: sinlinx-sina33: " Chen-Yu Tsai
2015-08-19 16:32 ` [PATCH v3 0/8] ARM: sunxi: Add Reduced Serial Bus support Mark Brown
2015-08-20 1:59 ` Chen-Yu Tsai
2015-08-20 17:02 ` Mark Brown [this message]
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=20150820170211.GB12027@sirena.org.uk \
--to=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=galak@codeaurora.org \
--cc=gregkh@linuxfoundation.org \
--cc=hdegoede@redhat.com \
--cc=ijc+devicetree@hellion.org.uk \
--cc=kevin.z.m.zh@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sunxi@googlegroups.com \
--cc=mark.rutland@arm.com \
--cc=maxime.ripard@free-electrons.com \
--cc=pawel.moll@arm.com \
--cc=robh+dt@kernel.org \
--cc=shuge@allwinnertech.com \
--cc=wens@csie.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®