* [PATCH] spi: fsl-dspi: Convert to use regmap framework's endianness method.
@ 2014-08-18 7:48 Xiubo Li
[not found] ` <1408348100-28819-1-git-send-email-Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Xiubo Li @ 2014-08-18 7:48 UTC (permalink / raw)
To: broonie-DgEjT+Ai2ygdnm+yROfE0A, b44548-KZfg59tc24xl57MIdRCFDg
Cc: devicetree-u79uwXL29TY76Z2rM5mHXA,
linux-spi-u79uwXL29TY76Z2rM5mHXA, Xiubo Li
Signed-off-by: Xiubo Li <Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
Cc: Chao Fu <b44548-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
---
This is depended on the following patches, which has been applied into
Regmap-Tree:
https://lkml.org/lkml/2014/7/15/6
https://lkml.org/lkml/2014/7/15/5
https://lkml.org/lkml/2014/7/15/7
Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt | 7 ++++++-
drivers/spi/spi-fsl-dspi.c | 3 ---
2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt b/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt
index 5376de4..cbbe16e 100644
--- a/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt
+++ b/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt
@@ -10,7 +10,12 @@ Required properties:
- pinctrl-names: must contain a "default" entry.
- spi-num-chipselects : the number of the chipselect signals.
- bus-num : the slave chip chipselect signal number.
-- big-endian : if DSPI modudle is big endian, the bool will be set in node.
+
+Optional property:
+- big-endian: If present the dspi device's registers are implemented
+ in big endian mode, otherwise in native mode(same with CPU), for more
+ detail please see: Documentation/devicetree/bindings/regmap/regmap.txt.
+
Example:
dspi0@4002c000 {
diff --git a/drivers/spi/spi-fsl-dspi.c b/drivers/spi/spi-fsl-dspi.c
index 5021ddf..ebc4d1f 100644
--- a/drivers/spi/spi-fsl-dspi.c
+++ b/drivers/spi/spi-fsl-dspi.c
@@ -493,9 +493,6 @@ static int dspi_probe(struct platform_device *pdev)
}
dspi_regmap_config.lock_arg = dspi;
- dspi_regmap_config.val_format_endian =
- of_property_read_bool(np, "big-endian")
- ? REGMAP_ENDIAN_BIG : REGMAP_ENDIAN_DEFAULT;
dspi->regmap = devm_regmap_init_mmio_clk(&pdev->dev, "dspi", base,
&dspi_regmap_config);
if (IS_ERR(dspi->regmap)) {
--
1.8.5
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 3+ messages in thread[parent not found: <1408348100-28819-1-git-send-email-Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org>]
* RE: [PATCH] spi: fsl-dspi: Convert to use regmap framework's endianness method. [not found] ` <1408348100-28819-1-git-send-email-Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org> @ 2014-08-18 8:06 ` Chao Fu 2014-08-18 14:43 ` Mark Brown 1 sibling, 0 replies; 3+ messages in thread From: Chao Fu @ 2014-08-18 8:06 UTC (permalink / raw) To: broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org > -----Original Message----- > From: Xiubo Li [mailto:Li.Xiubo@freescale.com] > Sent: 2014年8月18日 15:48 > To: broonie@kernel.org; Fu Chao-B44548 > Cc: devicetree@vger.kernel.org; linux-spi@vger.kernel.org; Xiubo Li- > B47053 > Subject: [PATCH] spi: fsl-dspi: Convert to use regmap framework's > endianness method. > > Signed-off-by: Xiubo Li <Li.Xiubo@freescale.com> > Cc: Chao Fu <b44548@freescale.com> > --- > Acked-by: Chao Fu <B44548@freescale.com> Thank you! > This is depended on the following patches, which has been applied into > Regmap-Tree: > https://lkml.org/lkml/2014/7/15/6 > https://lkml.org/lkml/2014/7/15/5 > https://lkml.org/lkml/2014/7/15/7 > > > > > Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt | 7 ++++++- > drivers/spi/spi-fsl-dspi.c | 3 --- > 2 files changed, 6 insertions(+), 4 deletions(-) > > diff --git a/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt > b/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt > index 5376de4..cbbe16e 100644 > --- a/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt > +++ b/Documentation/devicetree/bindings/spi/spi-fsl-dspi.txt > @@ -10,7 +10,12 @@ Required properties: > - pinctrl-names: must contain a "default" entry. > - spi-num-chipselects : the number of the chipselect signals. > - bus-num : the slave chip chipselect signal number. > -- big-endian : if DSPI modudle is big endian, the bool will be set in > node. > + > +Optional property: > +- big-endian: If present the dspi device's registers are implemented > + in big endian mode, otherwise in native mode(same with CPU), for more > + detail please see: Documentation/devicetree/bindings/regmap/regmap.txt. > + > Example: > > dspi0@4002c000 { > diff --git a/drivers/spi/spi-fsl-dspi.c b/drivers/spi/spi-fsl-dspi.c > index 5021ddf..ebc4d1f 100644 > --- a/drivers/spi/spi-fsl-dspi.c > +++ b/drivers/spi/spi-fsl-dspi.c > @@ -493,9 +493,6 @@ static int dspi_probe(struct platform_device *pdev) > } > > dspi_regmap_config.lock_arg = dspi; > - dspi_regmap_config.val_format_endian = > - of_property_read_bool(np, "big-endian") > - ? REGMAP_ENDIAN_BIG : REGMAP_ENDIAN_DEFAULT; > dspi->regmap = devm_regmap_init_mmio_clk(&pdev->dev, "dspi", base, > &dspi_regmap_config); > if (IS_ERR(dspi->regmap)) { > -- > 1.8.5 ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] spi: fsl-dspi: Convert to use regmap framework's endianness method. [not found] ` <1408348100-28819-1-git-send-email-Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org> 2014-08-18 8:06 ` Chao Fu @ 2014-08-18 14:43 ` Mark Brown 1 sibling, 0 replies; 3+ messages in thread From: Mark Brown @ 2014-08-18 14:43 UTC (permalink / raw) To: Xiubo Li Cc: b44548-KZfg59tc24xl57MIdRCFDg, devicetree-u79uwXL29TY76Z2rM5mHXA, linux-spi-u79uwXL29TY76Z2rM5mHXA [-- Attachment #1: Type: text/plain, Size: 216 bytes --] On Mon, Aug 18, 2014 at 03:48:20PM +0800, Xiubo Li wrote: > Signed-off-by: Xiubo Li <Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org> > Cc: Chao Fu <b44548-KZfg59tc24xl57MIdRCFDg@public.gmane.org> Applied, thanks. [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 819 bytes --] ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-08-18 14:43 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-18 7:48 [PATCH] spi: fsl-dspi: Convert to use regmap framework's endianness method Xiubo Li
[not found] ` <1408348100-28819-1-git-send-email-Li.Xiubo-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
2014-08-18 8:06 ` Chao Fu
2014-08-18 14:43 ` Mark Brown
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox