From: b29396@freescale.com (Dong Aisheng)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 1/7] mfd: add syscon driver based on regmap
Date: Wed, 29 Aug 2012 10:00:50 +0800 [thread overview]
Message-ID: <20120829020049.GA29464@shlinux2.ap.freescale.net> (raw)
In-Reply-To: <503D4C08.8040605@wwwdotorg.org>
On Wed, Aug 29, 2012 at 06:54:00AM +0800, Stephen Warren wrote:
> On 08/28/2012 02:09 AM, Dong Aisheng wrote:
> > From: Dong Aisheng <dong.aisheng@linaro.org>
> >
> > Add regmap based syscon driver.
> > This is usually used for access misc bits in registers which does not belong
> > to a specific module, for example, IMX IOMUXC GPR and ANATOP.
> > With this driver, client can use generic regmap API to access registers
> > which are registered into syscon.
>
> > diff --git a/Documentation/devicetree/bindings/mfd/syscon.txt b/Documentation/devicetree/bindings/mfd/syscon.txt
>
> > +* System Controller Registers R/W driver
>
> I think the binding document could use some information about what a
> "syscon" actually is, especially since the compatible value is something
> generic like "syscon" rather than something with a vendor-specific
> prefix.
Yes, we'd better have it.
> How about:
>
> A system controller node represents a register region containing a set
> of miscellaneous registers. The registers are not cohesive enough to
> represent as any specific type of device. The typical use-case is for
> some other node's driver, or platform-specific code, to acquire a
> reference to the syscon node (e.g. by phandle, node path, or search
> using a specific compatible value), interrogate the node (or associated
> OS driver) to determine the location of the registers, and access the
> registers directly.
>
It looks very good to me.
Thanks for the help.
> > +Required properties:
> > +- compatible: Should contain "syscon".
> > +- reg: the register range can be access from syscon
> > +
> > +Examples:
> > +gpr: iomuxc-gpr at 020e0000 {
> > + compatible = "fsl,imx6q-iomuxc-gpr", "syscon";
> > + reg = <0x020e0000 0x38>;
> > +};
>
> > diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
>
> > +config MFD_SYSCON
> > + bool "System Controller Register R/W Based on Regmap"
> > + select REGMAP_MMIO
> > + help
> > + Select this option to enable accessing system control registers
> > + via regmap.
>
> I think the indentation is off there.
>
You're right.
Will fix it.
> > +static int __devinit syscon_probe(struct platform_device *pdev)
> ...
> > + regcache_cache_only(syscon->regmap, false);
>
> Isn't that the default?
>
Correct, will remove.
> Aside from that, I don't have any particular comments on this series, so
> please consider it,
>
> Acked-by: Stephen Warren <swarren@wwwdotorg.org>
>
Thanks a lot.
Regards
Dong Aisheng
WARNING: multiple messages have this Message-ID (diff)
From: Dong Aisheng <b29396@freescale.com>
To: Stephen Warren <swarren@wwwdotorg.org>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"linus.walleij@stericsson.com" <linus.walleij@stericsson.com>,
"s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
"shawn.guo@linaro.org" <shawn.guo@linaro.org>,
"kernel@pengutronix.de" <kernel@pengutronix.de>,
"grant.likely@secretlab.ca" <grant.likely@secretlab.ca>,
"rob.herring@calxeda.com" <rob.herring@calxeda.com>,
"sameo@linux.intel.com" <sameo@linux.intel.com>,
"lrg@ti.com" <lrg@ti.com>,
"broonie@opensource.wolfsonmicro.com"
<broonie@opensource.wolfsonmicro.com>,
Zhao Richard-B20223 <B20223@freescale.com>,
"devicetree-discuss@lists.ozlabs.org"
<devicetree-discuss@lists.ozlabs.org>
Subject: Re: [PATCH v3 1/7] mfd: add syscon driver based on regmap
Date: Wed, 29 Aug 2012 10:00:50 +0800 [thread overview]
Message-ID: <20120829020049.GA29464@shlinux2.ap.freescale.net> (raw)
In-Reply-To: <503D4C08.8040605@wwwdotorg.org>
On Wed, Aug 29, 2012 at 06:54:00AM +0800, Stephen Warren wrote:
> On 08/28/2012 02:09 AM, Dong Aisheng wrote:
> > From: Dong Aisheng <dong.aisheng@linaro.org>
> >
> > Add regmap based syscon driver.
> > This is usually used for access misc bits in registers which does not belong
> > to a specific module, for example, IMX IOMUXC GPR and ANATOP.
> > With this driver, client can use generic regmap API to access registers
> > which are registered into syscon.
>
> > diff --git a/Documentation/devicetree/bindings/mfd/syscon.txt b/Documentation/devicetree/bindings/mfd/syscon.txt
>
> > +* System Controller Registers R/W driver
>
> I think the binding document could use some information about what a
> "syscon" actually is, especially since the compatible value is something
> generic like "syscon" rather than something with a vendor-specific
> prefix.
Yes, we'd better have it.
> How about:
>
> A system controller node represents a register region containing a set
> of miscellaneous registers. The registers are not cohesive enough to
> represent as any specific type of device. The typical use-case is for
> some other node's driver, or platform-specific code, to acquire a
> reference to the syscon node (e.g. by phandle, node path, or search
> using a specific compatible value), interrogate the node (or associated
> OS driver) to determine the location of the registers, and access the
> registers directly.
>
It looks very good to me.
Thanks for the help.
> > +Required properties:
> > +- compatible: Should contain "syscon".
> > +- reg: the register range can be access from syscon
> > +
> > +Examples:
> > +gpr: iomuxc-gpr@020e0000 {
> > + compatible = "fsl,imx6q-iomuxc-gpr", "syscon";
> > + reg = <0x020e0000 0x38>;
> > +};
>
> > diff --git a/drivers/mfd/Kconfig b/drivers/mfd/Kconfig
>
> > +config MFD_SYSCON
> > + bool "System Controller Register R/W Based on Regmap"
> > + select REGMAP_MMIO
> > + help
> > + Select this option to enable accessing system control registers
> > + via regmap.
>
> I think the indentation is off there.
>
You're right.
Will fix it.
> > +static int __devinit syscon_probe(struct platform_device *pdev)
> ...
> > + regcache_cache_only(syscon->regmap, false);
>
> Isn't that the default?
>
Correct, will remove.
> Aside from that, I don't have any particular comments on this series, so
> please consider it,
>
> Acked-by: Stephen Warren <swarren@wwwdotorg.org>
>
Thanks a lot.
Regards
Dong Aisheng
next prev parent reply other threads:[~2012-08-29 2:00 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-28 9:09 [PATCH v3 0/7] add syscon driver based on regmap for general registers access Dong Aisheng
2012-08-28 9:09 ` Dong Aisheng
2012-08-28 9:09 ` Dong Aisheng
2012-08-28 9:09 ` [PATCH v3 1/7] mfd: add syscon driver based on regmap Dong Aisheng
2012-08-28 9:09 ` Dong Aisheng
2012-08-28 9:09 ` Dong Aisheng
2012-08-28 22:54 ` Stephen Warren
2012-08-28 22:54 ` Stephen Warren
2012-08-28 22:54 ` Stephen Warren
2012-08-29 2:00 ` Dong Aisheng [this message]
2012-08-29 2:00 ` Dong Aisheng
2012-08-28 9:10 ` [PATCH v3 2/7] ARM: imx6q: add iomuxc gpr support into syscon Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` [PATCH v3 3/7] ARM: imx6q: add anatop " Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` [PATCH v3 4/7] regulator: anatop-regulator: convert to use syscon to access anatop register Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` [PATCH v3 5/7] ARM: imx6q: convert to use syscon to access anatop registers Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` [PATCH v3 6/7] ARM: dts: imx6q: add simple-bus compatible string for anatop Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` [PATCH v3 7/7] mfd: anatop-mfd: remove anatop driver Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
2012-08-28 9:10 ` Dong Aisheng
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=20120829020049.GA29464@shlinux2.ap.freescale.net \
--to=b29396@freescale.com \
--cc=linux-arm-kernel@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.