aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/devicetree/bindings/sound/fsl,esai.txt5
-rw-r--r--sound/soc/fsl/fsl_esai.c5
2 files changed, 9 insertions, 1 deletions
diff --git a/Documentation/devicetree/bindings/sound/fsl,esai.txt b/Documentation/devicetree/bindings/sound/fsl,esai.txt
index d7b99fa637b5..aeb8c4a0b88d 100644
--- a/Documentation/devicetree/bindings/sound/fsl,esai.txt
+++ b/Documentation/devicetree/bindings/sound/fsl,esai.txt
@@ -34,6 +34,10 @@ Required properties:
34 that ESAI would work in the synchronous mode, which means all the settings 34 that ESAI would work in the synchronous mode, which means all the settings
35 for Receiving would be duplicated from Transmition related registers. 35 for Receiving would be duplicated from Transmition related registers.
36 36
37 - big-endian : If this property is absent, the native endian mode will
38 be in use as default, or the big endian mode will be in use for all the
39 device registers.
40
37Example: 41Example:
38 42
39esai: esai@02024000 { 43esai: esai@02024000 {
@@ -46,5 +50,6 @@ esai: esai@02024000 {
46 dma-names = "rx", "tx"; 50 dma-names = "rx", "tx";
47 fsl,fifo-depth = <128>; 51 fsl,fifo-depth = <128>;
48 fsl,esai-synchronous; 52 fsl,esai-synchronous;
53 big-endian;
49 status = "disabled"; 54 status = "disabled";
50}; 55};
diff --git a/sound/soc/fsl/fsl_esai.c b/sound/soc/fsl/fsl_esai.c
index f55341e52970..d8e13abd1bca 100644
--- a/sound/soc/fsl/fsl_esai.c
+++ b/sound/soc/fsl/fsl_esai.c
@@ -678,7 +678,7 @@ static bool fsl_esai_writeable_reg(struct device *dev, unsigned int reg)
678 } 678 }
679} 679}
680 680
681static const struct regmap_config fsl_esai_regmap_config = { 681static struct regmap_config fsl_esai_regmap_config = {
682 .reg_bits = 32, 682 .reg_bits = 32,
683 .reg_stride = 4, 683 .reg_stride = 4,
684 .val_bits = 32, 684 .val_bits = 32,
@@ -704,6 +704,9 @@ static int fsl_esai_probe(struct platform_device *pdev)
704 esai_priv->pdev = pdev; 704 esai_priv->pdev = pdev;
705 strcpy(esai_priv->name, np->name); 705 strcpy(esai_priv->name, np->name);
706 706
707 if (of_property_read_bool(np, "big-endian"))
708 fsl_esai_regmap_config.val_format_endian = REGMAP_ENDIAN_BIG;
709
707 /* Get the addresses and IRQ */ 710 /* Get the addresses and IRQ */
708 res = platform_get_resource(pdev, IORESOURCE_MEM, 0); 711 res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
709 regs = devm_ioremap_resource(&pdev->dev, res); 712 regs = devm_ioremap_resource(&pdev->dev, res);