Skip to contentSkip to conversation

ASoC drivers for the Freescale MPC8610 SoC

PATCH New Timur Tabi 8 participants 23 messages Jan 10, 2008 – Jan 18, 2008

Subsystems (6)
lore
Share & tools
lore

Timur Tabi

author
#0 lore raw

cover ASoC drivers for the Freescale MPC8610 SoC

These patches add ALSA SoC device drivers for the Freescale MPC8610 SoC and the MPC8610-HPCD reference board.

The first patch updates some files in arch/powerpc and booting-without-of.txt.

The second patch adds the new audio driver files to sound/soc.

Both must be applied in order to avoid a build break.

author
#1 lore raw

PATCH v3 1/1 Update MPC8610 HPCD to support audio drivers

Update the MPC8610 HPCD files to support the audio driver. Update booting-without-of.txt with information on the SSI device.

---

Updated the DTS based comments on the list.

This patch applies on top of
git://git.kernel.org/pub/scm/linux/kernel/git/perex/alsa.git.

 Documentation/powerpc/booting-without-of.txt |   41 ++++++
 arch/powerpc/boot/dts/mpc8610_hpcd.dts       |  113 +++++++++++++++++-
 arch/powerpc/configs/mpc8610_hpcd_defconfig  |  171 +++++++++++++++++++++++++-
 arch/powerpc/platforms/86xx/mpc8610_hpcd.c   |   15 +++
 4 files changed, 336 insertions(+), 4 deletions(-)
Documentation/powerpc/booting-without-of.txt +41 -0
index e9a3cb1..8ddcf0b 100644
@@ -53,6 +53,7 @@ Table of Contents
       j) CFI or JEDEC memory-mapped NOR flash
       k) Global Utilities Block
       l) Xilinx IP cores
+      p) Freescale Synchronous Serial Interface
 
   VII - Specifying interrupt information for devices
     1) interrupts property
@@ -2514,6 +2515,46 @@ platforms are moved over to use the flattened-device-tree model.
       Requred properties:
        - current-speed : Baud rate of uartlite
 
+    p) Freescale Synchronous Serial Interface
+
+       The SSI is a serial device that communicates with audio codecs.  It can
+       be programmed in AC97, I2S, left-justified, or right-justified modes.
+
+       Required properties:
+       - compatible	  : compatible list, containing "fsl,ssi"
+       - cell-index	  : the SSI, <0> = SSI1, <1> = SSI2, and so on
+       - reg		  : offset and length of the register set for the device
+       - interrupts	  : <a b> where a is the interrupt number and b is a
+                            field that represents an encoding of the sense and
+			    level information for the interrupt.  This should be
+			    encoded based on the information in section 2)
+			    depending on the type of interrupt controller you
+			    have.
+       - interrupt-parent : the phandle for the interrupt controller that
+                            services interrupts for this device.
+       - fsl,mode	  : the operating mode for the SSI interface
+			    "i2s-slave" - I2S mode, SSI is clock slave
+			    "i2s-master" - I2S mode, SSI is clock master
+			    "lj-slave" - left-justified mode, SSI is clock slave
+			    "lj-master" - l.j. mode, SSI is clock master
+			    "rj-slave" - right-justified mode, SSI is clock slave
+			    "rj-master" - r.j., SSI is clock master
+			    "ac97-slave" - AC97 mode, SSI is clock slave
+			    "ac97-master" - AC97 mode, SSI is clock master
+
+       Optional properties:
+       - codec-handle	  : phandle to a 'codec' node that defines an audio
+			    codec connected to this SSI.  This node is typically
+			    a child of an I2C or other control node.
+
+       Child 'codec' node required properties:
+       - compatible	  : compatible list, contains the name of the codec
+
+       Child 'codec' node optional properties:
+       - clock-frequency  : The frequency of the input clock, which typically
+                            comes from an on-board dedicated oscillator.
+
+
    More devices will be defined as this spec matures.
 
 VII - Specifying interrupt information for devices
arch/powerpc/boot/dts/mpc8610_hpcd.dts +112 -1

137 lines not on this page · raw message

arch/powerpc/configs/mpc8610_hpcd_defconfig +168 -3

189 lines not on this page · raw message

arch/powerpc/platforms/86xx/mpc8610_hpcd.c +15 -0
index 6390895..36d8f14 100644
@@ -34,9 +34,24 @@
 
 #include <asm/mpic.h>
 
+#include <linux/of_platform.h>
 #include <sysdev/fsl_pci.h>
 #include <sysdev/fsl_soc.h>
 
+static struct of_device_id __initdata mpc8610_ids[] = {
+	{ .compatible = "fsl,mpc8610-immr", },
+	{}
+};
+
+static int __init mpc8610_declare_of_platform_devices(void)
+{
+	/* Without this call, the SSI device driver won't get probed. */
+	of_platform_bus_probe(NULL, mpc8610_ids, NULL);
+
+	return 0;
+}
+machine_device_initcall(mpc86xx_hpcd, mpc8610_declare_of_platform_devices);
+
 void __init
 mpc86xx_hpcd_init_irq(void)
 {
Signature · 1 line
1.5.2.4
author
#2 lore raw

PATCH v2 1/1 Add ASoC drivers for the Freescale MPC8610 SoC

Add the ASoC drivers for the Freescale MPC8610 SoC and the MPC8610 HPCD reference board.

---
 sound/soc/Kconfig            |    1 +
 sound/soc/Makefile           |    2 +-
 sound/soc/fsl/Kconfig        |   20 +
 sound/soc/fsl/Makefile       |    6 +
 sound/soc/fsl/fsl_dma.c      |  839 ++++++++++++++++++++++++++++++++++++++++++
 sound/soc/fsl/fsl_dma.h      |  149 ++++++++
 sound/soc/fsl/fsl_ssi.c      |  644 ++++++++++++++++++++++++++++++++
 sound/soc/fsl/fsl_ssi.h      |  224 +++++++++++
 sound/soc/fsl/mpc8610_hpcd.c |  631 +++++++++++++++++++++++++++++++
 9 files changed, 2515 insertions(+), 1 deletions(-)
 create mode 100644 sound/soc/fsl/Kconfig
 create mode 100644 sound/soc/fsl/Makefile
 create mode 100644 sound/soc/fsl/fsl_dma.c
 create mode 100644 sound/soc/fsl/fsl_dma.h
 create mode 100644 sound/soc/fsl/fsl_ssi.c
 create mode 100644 sound/soc/fsl/fsl_ssi.h
 create mode 100644 sound/soc/fsl/mpc8610_hpcd.c
sound/soc/Kconfig +1 -0
index 97b2552..2765852 100644
@@ -28,6 +28,7 @@ source "sound/soc/at91/Kconfig"
 source "sound/soc/pxa/Kconfig"
 source "sound/soc/s3c24xx/Kconfig"
 source "sound/soc/sh/Kconfig"
+source "sound/soc/fsl/Kconfig"
 
 # Supported codecs
 source "sound/soc/codecs/Kconfig"
sound/soc/Makefile +1 -1
index 3041403..4869c9a 100644
@@ -1,4 +1,4 @@
 snd-soc-core-objs := soc-core.o soc-dapm.o
 
 obj-$(CONFIG_SND_SOC)	+= snd-soc-core.o
-obj-$(CONFIG_SND_SOC)	+= codecs/ at91/ pxa/ s3c24xx/ sh/
+obj-$(CONFIG_SND_SOC)	+= codecs/ at91/ pxa/ s3c24xx/ sh/ fsl/
sound/soc/fsl/Kconfig new file +20 -0
new file mode 100644
index 0000000..257101f
@@ -0,0 +1,20 @@
+menu "ALSA SoC audio for Freescale SOCs"
+
+config SND_SOC_MPC8610
+	bool "ALSA SoC support for the MPC8610 SOC"
+	depends on SND_SOC && MPC8610_HPCD
+	default y if MPC8610
+	help
+	  Say Y if you want to add support for codecs attached to the SSI
+          device on an MPC8610.
+
+config SND_SOC_MPC8610_HPCD
+	bool "ALSA SoC support for the Freescale MPC8610 HPCD board"
+	depends on SND_SOC_MPC8610
+	select SND_SOC_CS4270
+	select SND_SOC_CS4270_VD33_ERRATA
+	default y if MPC8610_HPCD
+	help
+	  Say Y if you want to enable audio on the Freescale MPC8610 HPCD.
+
+endmenu
sound/soc/fsl/Makefile new file +6 -0
new file mode 100644
index 0000000..62f680a
@@ -0,0 +1,6 @@
+# MPC8610 HPCD Machine Support
+obj-$(CONFIG_SND_SOC_MPC8610_HPCD) += mpc8610_hpcd.o
+
+# MPC8610 Platform Support
+obj-$(CONFIG_SND_SOC_MPC8610) += fsl_ssi.o fsl_dma.o
+
sound/soc/fsl/fsl_dma.c new file +839 -0

839 lines not on this page · raw message

sound/soc/fsl/fsl_dma.h new file +149 -0

149 lines not on this page · raw message

sound/soc/fsl/fsl_ssi.c new file +644 -0

644 lines not on this page · raw message

sound/soc/fsl/fsl_ssi.h new file +224 -0

224 lines not on this page · raw message

sound/soc/fsl/mpc8610_hpcd.c new file +631 -0

631 lines not on this page · raw message

Signature · 1 line
1.5.2.4
#3 lore raw

Re: [PATCH v2] [ALSA] Add ASoC drivers for the Freescale MPC8610 SoC

Quoted 4 lines · Timur Tabi

Add the ASoC drivers for the Freescale MPC8610 SoC and the MPC8610 HPCD reference board.

This is a very big patch, but I'm going to keep my nose out of the ALSA stuff. I've got no problem against it being merged, but I do have a concern about access to shared registers (see below)

Quoted 25 lines
sound/soc/fsl/mpc8610_hpcd.c new file +20 -0
new file mode 100644
index 0000000..f26c4b2
+/**
+ * mpc8610_hpcd_probe: OF probe function for the fabric driver
+ *
+ * This function gets called when an SSI node is found in the device tree.
+ *
+ * Although this is a fabric driver, the SSI node is the "master" node with
+ * respect to audio hardware connections.  Therefore, we create a new ASoC
+ * device for each new SSI node that has a codec attached.
+ *
+ * FIXME: Currently, we only support one DMA controller, so if there are
+ * multiple SSI nodes with codecs, only the first will be supported.
+ *
+ * FIXME: Even if we did support multiple DMA controllers, we have no
+ * mechanism for assigning DMA controllers and channels to the individual
+ * SSI devices.  We also probably aren't compatible with the generic Elo DMA
+ * device driver.
+ */
+static int mpc8610_hpcd_probe(struct of_device *ofdev,
+       const struct of_device_id *match)
+{

<snip>

sound/soc/fsl/mpc8610_hpcd.c line 385

Quoted 7 lines
sound/soc/fsl/mpc8610_hpcd.c new file +7 -0
+       /* Map the global utilities registers. */
+       guts_np = of_find_compatible_node(NULL, NULL, "fsl,mpc8610-guts");
+       if (!guts_np) {
+               dev_err(&ofdev->dev, "could not obtain address of GUTS\n");
+               ret = -EINVAL;
+               goto error;
+       }

This...

sound/soc/fsl/mpc8610_hpcd.c line 402

Quoted 9 lines
sound/soc/fsl/mpc8610_hpcd.c new file +9 -0
+       /* Find the DMA channels to use.  For now, we always use the first DMA
+          controller. */
+       for_each_compatible_node(dma_np, NULL, "fsl,mpc8610-dma") {
+               iprop = of_get_property(dma_np, "cell-index", NULL);
+               if (iprop && (*iprop == 0)) {
+                       of_node_put(dma_np);
+                       break;
+               }
+       }

and this...

Does the driver access the DMA and GUTS registers directly? If so, what do you have to protect against race conditions of other drivers accessing them also.

Cheers,
g.

Signature · 2 lines
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
author
#4 lore raw

Re: [PATCH v2] [ALSA] Add ASoC drivers for the Freescale MPC8610 SoC

Quoted 3 lines · Grant Likely

Does the driver access the DMA and GUTS registers directly? If so, what do you have to protect against race conditions of other drivers accessing them also.

I don't have any more protection than any other driver that accesses SOC registers directly. Last I heard, Zhang's DMA driver was in limbo, and that driver would be the best place to arbitrate DMA register access. I was planning on adding arbitration support to that driver after both drivers were applied.

As for the GUTS driver, well, I just program a few registers at startup, and I don't think any other driver touches them.

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
#5 lore raw

Re: [PATCH v2] [ALSA] Add ASoC drivers for the Freescale MPC8610 SoC

Quoted 10 lines · Timur Tabi
Quoted 3 lines · Grant Likely

Does the driver access the DMA and GUTS registers directly? If so, what do you have to protect against race conditions of other drivers accessing them also.

I don't have any more protection than any other driver that accesses SOC registers directly. Last I heard, Zhang's DMA driver was in limbo, and that driver would be the best place to arbitrate DMA register access. I was planning on adding arbitration support to that driver after both drivers were applied.

That sounds appropriate

Quoted 3 lines

As for the GUTS driver, well, I just program a few registers at startup, and I don't think any other driver touches them.

Okay; at some point in the future they'll need to be accessed from a common routine too.

g.

Signature · 2 lines
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
author
#6 lore raw

Re: [PATCH v2] [ALSA] Add ASoC drivers for the Freescale MPC8610 SoC

Quoted 5 lines · Grant Likely
Quoted 2 lines

As for the GUTS driver, well, I just program a few registers at startup, and I don't think any other driver touches them.

Okay; at some point in the future they'll need to be accessed from a common routine too.

I'll add that to my to-do list.

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
#7 lore raw

Re: [PATCH v2] [ALSA] Add ASoC drivers for the Freescale MPC8610 SoC

In reply to Timur Tabi
Quoted 10 lines · Timur Tabi
Quoted 3 lines · Grant Likely

Does the driver access the DMA and GUTS registers directly? If so, what do you have to protect against race conditions of other drivers accessing them also.

I don't have any more protection than any other driver that accesses SOC registers directly. Last I heard, Zhang's DMA driver was in limbo, and that driver would be the best place to arbitrate DMA register access. I was planning on adding arbitration support to that driver after both drivers were applied.

Having been in a similar situation myself (needing to share resources between DMA, ethernet and function offload), I recommend creating a separate small library that all those drivers use, instead of making some sort of dependency between drivers in completely different parts of the kernel.

-Olof

author
#8 lore raw

Re: [PATCH v2] [ALSA] Add ASoC drivers for the Freescale MPC8610 SoC

Quoted 5 lines · Olof Johansson

Having been in a similar situation myself (needing to share resources between DMA, ethernet and function offload), I recommend creating a separate small library that all those drivers use, instead of making some sort of dependency between drivers in completely different parts of the kernel.

Well, the DMA driver should be in soon. Actually, it should be in now, because I saw a blurb in this month's Linux Journal about it. As soon as I find it :-), I'll post a new patch that adds arbitration.

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
Acked-by on v3 1/1
#9 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

In reply to Timur Tabi
Quoted 4 lines · Timur Tabi

Update the MPC8610 HPCD files to support the audio driver. Update booting-without-of.txt with information on the SSI device.

<snip>

Quoted 28 lines
arch/powerpc/boot/dts/mpc8610_hpcd.dts +20 -0
index 966edf1..4c91890 100644
@@ -103,6 +111,109 @@
                        reg = <e0000 1000>;
                        fsl,has-rstcr;
                };
+
+               i2s@16000 {
+                       compatible = "fsl,mpc8610-ssi";
+                       cell-index = <0>;
+                       reg = <16000 100>;
+                       interrupt-parent = <&mpic>;
+                       interrupts = <3e 2>;
+                       fsl,mode = "i2s-slave";
+                       codec-handle = <&cs4270>;
+               };
+
+               ssi@16100 {
+                       compatible = "fsl,mpc8610-ssi";
+                       cell-index = <1>;
+                       reg = <16100 100>;
+                       interrupt-parent = <&mpic>;
+                       interrupts = <3f 2>;
+               };
+
+                dma@21300 {

arch/powerpc/boot/dts/mpc8610_hpcd.dts line 143

Quoted 10 lines
arch/powerpc/boot/dts/mpc8610_hpcd.dts +10 -0
+                        #address-cells = <1>;
+                        #size-cells = <1>;
+                        compatible = "fsl,mpc8610-dma", "fsl,eloplus-dma";
+                        cell-index = <0>;
+                        reg = <21300 4>; /* DMA general status register */
+                        ranges = <0 21100 200>;
+
+                        dma-channel@0 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,eloplus-dma-channel";

Nit: you probably don't need the compatible property for these channel nodes since they are 100% dependent on the parent for describing the behaviour.

Otherwise;

Quoted 305 lines
arch/powerpc/boot/dts/mpc8610_hpcd.dts +73 -0
+                               cell-index = <0>;
+                               reg = <0 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <14 2>;
+                        };
+                        dma-channel@1 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,eloplus-dma-channel";
+                               cell-index = <1>;
+                               reg = <80 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <15 2>;
+                        };
+                        dma-channel@2 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,eloplus-dma-channel";
+                               cell-index = <2>;
+                               reg = <100 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <16 2>;
+                        };
+                        dma-channel@3 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,eloplus-dma-channel";
+                               cell-index = <3>;
+                               reg = <180 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <17 2>;
+                        };
+                };
+
+                dma@c300 {
+                        #address-cells = <1>;
+                        #size-cells = <1>;
+                        compatible = "fsl,mpc8610-dma", "fsl,mpc8540-dma";
+                        cell-index = <1>;
+                        reg = <c300 4>; /* DMA general status register */
+                        ranges = <0 c100 200>;
+
+                        dma-channel@0 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,mpc8540-dma-channel";
+                               cell-index = <0>;
+                               reg = <0 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <3c 2>;
+                        };
+                        dma-channel@1 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,mpc8540-dma-channel";
+                               cell-index = <1>;
+                               reg = <80 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <3d 2>;
+                        };
+                        dma-channel@2 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,mpc8540-dma-channel";
+                               cell-index = <2>;
+                               reg = <100 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <3e 2>;
+                        };
+                        dma-channel@3 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,mpc8540-dma-channel";
+                               cell-index = <3>;
+                               reg = <180 80>;
+                               interrupt-parent = <&mpic>;
+                               interrupts = <3f 2>;
+                        };
+                };
+
        };
 
        pci@e0008000 {
arch/powerpc/configs/mpc8610_hpcd_defconfig +168 -3
index 9614d24..2500ef4 100644
@@ -696,7 +696,7 @@ CONFIG_SERIAL_8250_RSA=y
 CONFIG_SERIAL_CORE=y
 CONFIG_SERIAL_CORE_CONSOLE=y
 # CONFIG_SERIAL_JSM is not set
-CONFIG_SERIAL_OF_PLATFORM=y
+# CONFIG_SERIAL_OF_PLATFORM is not set
 CONFIG_UNIX98_PTYS=y
 # CONFIG_LEGACY_PTYS is not set
 # CONFIG_IPMI_HANDLER is not set
@@ -708,7 +708,60 @@ CONFIG_UNIX98_PTYS=y
 # CONFIG_RAW_DRIVER is not set
 # CONFIG_TCG_TPM is not set
 CONFIG_DEVPORT=y
-# CONFIG_I2C is not set
+CONFIG_I2C=y
+CONFIG_I2C_BOARDINFO=y
+# CONFIG_I2C_CHARDEV is not set
+
+#
+# I2C Algorithms
+#
+# CONFIG_I2C_ALGOBIT is not set
+# CONFIG_I2C_ALGOPCF is not set
+# CONFIG_I2C_ALGOPCA is not set
+
+#
+# I2C Hardware Bus support
+#
+# CONFIG_I2C_ALI1535 is not set
+# CONFIG_I2C_ALI1563 is not set
+# CONFIG_I2C_ALI15X3 is not set
+# CONFIG_I2C_AMD756 is not set
+# CONFIG_I2C_AMD8111 is not set
+# CONFIG_I2C_I801 is not set
+# CONFIG_I2C_I810 is not set
+# CONFIG_I2C_PIIX4 is not set
+CONFIG_I2C_MPC=y
+# CONFIG_I2C_NFORCE2 is not set
+# CONFIG_I2C_OCORES is not set
+# CONFIG_I2C_PARPORT_LIGHT is not set
+# CONFIG_I2C_PROSAVAGE is not set
+# CONFIG_I2C_SAVAGE4 is not set
+# CONFIG_I2C_SIMTEC is not set
+# CONFIG_I2C_SIS5595 is not set
+# CONFIG_I2C_SIS630 is not set
+# CONFIG_I2C_SIS96X is not set
+# CONFIG_I2C_TAOS_EVM is not set
+# CONFIG_I2C_VIA is not set
+# CONFIG_I2C_VIAPRO is not set
+# CONFIG_I2C_VOODOO3 is not set
+
+#
+# Miscellaneous I2C Chip support
+#
+# CONFIG_SENSORS_DS1337 is not set
+# CONFIG_SENSORS_DS1374 is not set
+# CONFIG_DS1682 is not set
+# CONFIG_SENSORS_EEPROM is not set
+# CONFIG_SENSORS_PCF8574 is not set
+# CONFIG_SENSORS_PCA9539 is not set
+# CONFIG_SENSORS_PCF8591 is not set
+# CONFIG_SENSORS_M41T00 is not set
+# CONFIG_SENSORS_MAX6875 is not set
+# CONFIG_SENSORS_TSL2550 is not set
+# CONFIG_I2C_DEBUG_CORE is not set
+# CONFIG_I2C_DEBUG_ALGO is not set
+# CONFIG_I2C_DEBUG_BUS is not set
+# CONFIG_I2C_DEBUG_CHIP is not set
 
 #
 # SPI support
@@ -763,7 +816,119 @@ CONFIG_DUMMY_CONSOLE=y
 #
 # Sound
 #
-# CONFIG_SOUND is not set
+CONFIG_SOUND=y
+
+#
+# Advanced Linux Sound Architecture
+#
+CONFIG_SND=y
+CONFIG_SND_TIMER=y
+CONFIG_SND_PCM=y
+# CONFIG_SND_SEQUENCER is not set
+CONFIG_SND_OSSEMUL=y
+CONFIG_SND_MIXER_OSS=y
+CONFIG_SND_PCM_OSS=y
+# CONFIG_SND_PCM_OSS_PLUGINS is not set
+# CONFIG_SND_DYNAMIC_MINORS is not set
+# CONFIG_SND_SUPPORT_OLD_API is not set
+CONFIG_SND_VERBOSE_PROCFS=y
+# CONFIG_SND_VERBOSE_PRINTK is not set
+# CONFIG_SND_DEBUG is not set
+
+#
+# Generic devices
+#
+# CONFIG_SND_DUMMY is not set
+# CONFIG_SND_MTPAV is not set
+# CONFIG_SND_SERIAL_U16550 is not set
+# CONFIG_SND_MPU401 is not set
+
+#
+# PCI devices
+#
+# CONFIG_SND_AD1889 is not set
+# CONFIG_SND_ALS300 is not set
+# CONFIG_SND_ALS4000 is not set
+# CONFIG_SND_ALI5451 is not set
+# CONFIG_SND_ATIIXP is not set
+# CONFIG_SND_ATIIXP_MODEM is not set
+# CONFIG_SND_AU8810 is not set
+# CONFIG_SND_AU8820 is not set
+# CONFIG_SND_AU8830 is not set
+# CONFIG_SND_AZT3328 is not set
+# CONFIG_SND_BT87X is not set
+# CONFIG_SND_CA0106 is not set
+# CONFIG_SND_CMIPCI is not set
+# CONFIG_SND_CS4281 is not set
+# CONFIG_SND_CS46XX is not set
+# CONFIG_SND_CS5530 is not set
+# CONFIG_SND_DARLA20 is not set
+# CONFIG_SND_GINA20 is not set
+# CONFIG_SND_LAYLA20 is not set
+# CONFIG_SND_DARLA24 is not set
+# CONFIG_SND_GINA24 is not set
+# CONFIG_SND_LAYLA24 is not set
+# CONFIG_SND_MONA is not set
+# CONFIG_SND_MIA is not set
+# CONFIG_SND_ECHO3G is not set
+# CONFIG_SND_INDIGO is not set
+# CONFIG_SND_INDIGOIO is not set
+# CONFIG_SND_INDIGODJ is not set
+# CONFIG_SND_EMU10K1 is not set
+# CONFIG_SND_EMU10K1X is not set
+# CONFIG_SND_ENS1370 is not set
+# CONFIG_SND_ENS1371 is not set
+# CONFIG_SND_ES1938 is not set
+# CONFIG_SND_ES1968 is not set
+# CONFIG_SND_FM801 is not set
+# CONFIG_SND_HDA_INTEL is not set
+# CONFIG_SND_HDSP is not set
+# CONFIG_SND_HDSPM is not set
+# CONFIG_SND_ICE1712 is not set
+# CONFIG_SND_ICE1724 is not set
+# CONFIG_SND_INTEL8X0 is not set
+# CONFIG_SND_INTEL8X0M is not set
+# CONFIG_SND_KORG1212 is not set
+# CONFIG_SND_MAESTRO3 is not set
+# CONFIG_SND_MIXART is not set
+# CONFIG_SND_NM256 is not set
+# CONFIG_SND_PCXHR is not set
+# CONFIG_SND_RIPTIDE is not set
+# CONFIG_SND_RME32 is not set
+# CONFIG_SND_RME96 is not set
+# CONFIG_SND_RME9652 is not set
+# CONFIG_SND_SONICVIBES is not set
+# CONFIG_SND_TRIDENT is not set
+# CONFIG_SND_VIA82XX is not set
+# CONFIG_SND_VIA82XX_MODEM is not set
+# CONFIG_SND_VX222 is not set
+# CONFIG_SND_YMFPCI is not set
+
+#
+# ALSA PowerMac devices
+#
+
+#
+# ALSA PowerPC devices
+#
+
+#
+# System on Chip audio support
+#
+CONFIG_SND_SOC=y
+
+#
+# SoC Audio support for SuperH
+#
+
+#
+# ALSA SoC audio for Freescale SOCs
+#
+CONFIG_SND_SOC_MPC8610=y
+CONFIG_SND_SOC_MPC8610_HPCD=y
+CONFIG_SND_SOC_CS4270=y
+CONFIG_SND_SOC_CS4270_VD33_ERRATA=y
+
 CONFIG_HID_SUPPORT=y
 CONFIG_HID=y
 # CONFIG_HID_DEBUG is not set
arch/powerpc/platforms/86xx/mpc8610_hpcd.c +15 -1
index 6390895..36d8f14 100644
@@ -34,9 +34,24 @@
 
 #include <asm/mpic.h>
 
+#include <linux/of_platform.h>
 #include <sysdev/fsl_pci.h>
 #include <sysdev/fsl_soc.h>
 
+static struct of_device_id __initdata mpc8610_ids[] = {
+       { .compatible = "fsl,mpc8610-immr", },
+       {}
+};
+
+static int __init mpc8610_declare_of_platform_devices(void)
+{
+       /* Without this call, the SSI device driver won't get probed. */
+       of_platform_bus_probe(NULL, mpc8610_ids, NULL);
+
+       return 0;
+}
+machine_device_initcall(mpc86xx_hpcd, mpc8610_declare_of_platform_devices);
+
 void __init
 mpc86xx_hpcd_init_irq(void)
 {
--

1.5.2.4

Signature · 2 lines
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
#10 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

Quoted 12 lines · Grant Likely

arch/powerpc/boot/dts/mpc8610_hpcd.dts line 143

Quoted 11 lines
arch/powerpc/boot/dts/mpc8610_hpcd.dts +11 -0
+                dma@21300 {
+                        #address-cells = <1>;
+                        #size-cells = <1>;
+                        compatible = "fsl,mpc8610-dma", "fsl,eloplus-dma";
+                        cell-index = <0>;
+                        reg = <21300 4>; /* DMA general status register */
+                        ranges = <0 21100 200>;
+
+                        dma-channel@0 {
+                               compatible = "fsl,mpc8610-dma-channel",
+                                       "fsl,eloplus-dma-channel";
Quoted 3 lines

Nit: you probably don't need the compatible property for these channel nodes since they are 100% dependent on the parent for describing the behaviour.

The compatible property in the child nodes gives the driver the option of matching the channel rather than the whole thing.

-Scott

author
#11 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

In reply to Grant Likely
Quoted 3 lines · Grant Likely

Otherwise;

Takashi,

This latest version of my Freescale MPC8610 audio patch has been approved by Liam and Grant Likely. Would you please include this code in 2.6.25?

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
#12 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

At Fri, 11 Jan 2008 10:39:50 -0600,

Quoted 11 lines · Timur Tabi
Quoted 3 lines · Grant Likely

Otherwise;

Takashi,

This latest version of my Freescale MPC8610 audio patch has been approved by Liam and Grant Likely. Would you please include this code in 2.6.25?

I can merge the ALSA part from myself, but the change in ppc subtree is difficult because I have no access to alsa.git tree.

Is it OK that the first patch goes to ppc tree?

Takashi

author
#13 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

Quoted 2 lines · Takashi Iwai

I can merge the ALSA part from myself, but the change in ppc subtree is difficult because I have no access to alsa.git tree.

What is the relationship between the alsa.git repo and the Hg repo? Why do we have two repos anyway?

Quoted 1 line

Is it OK that the first patch goes to ppc tree?

Yes, either part can be applied independent of the other. If you want to apply just the second part, I can find someone on the PPC to apply the first.

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
#14 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

At Fri, 11 Jan 2008 11:07:37 -0600,

Quoted 8 lines · Timur Tabi
Quoted 2 lines · Takashi Iwai

I can merge the ALSA part from myself, but the change in ppc subtree is difficult because I have no access to alsa.git tree.

What is the relationship between the alsa.git repo and the Hg repo? Why do we have two repos anyway?

alsa.git exists just for pushing to Linus. The developers except for Jaroslav has no access to it.

OTOH, HG tree is the main repository for ALSA development, and this is open for developers. The changes in ALSA HG repo are automatically transfered to alsa.git.

The problem is that HG repo doesn't contain the whole kernel tree but only the ALSA subtree to reduce the repo size.

Quoted 4 lines
Quoted 1 line

Is it OK that the first patch goes to ppc tree?

Yes, either part can be applied independent of the other. If you want to apply just the second part, I can find someone on the PPC to apply the first.

That'd be helpful. Then I'll apply your second part and leave the first part to ppc guys.

thanks,

Takashi

author
#15 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

Quoted 2 lines · Takashi Iwai

The problem is that HG repo doesn't contain the whole kernel tree but only the ALSA subtree to reduce the repo size.

So is it okay if I use the git repo to base my work? I use git for all other Linux development, so it would be awkward for me to use HG just for ALSA work.

Quoted 2 lines

That'd be helpful. Then I'll apply your second part and leave the first part to ppc guys.

Kumar Gala is going to apply the first part. It'll be in his "for-2.6.25" branch. Can I assume that you'll push the second part to alsa.git and then to Linus when the 2.6.25 window opens?

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
#16 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

At Fri, 11 Jan 2008 11:16:40 -0600,

Quoted 8 lines · Timur Tabi
Quoted 2 lines · Takashi Iwai

The problem is that HG repo doesn't contain the whole kernel tree but only the ALSA subtree to reduce the repo size.

So is it okay if I use the git repo to base my work? I use git for all other Linux development, so it would be awkward for me to use HG just for ALSA work.

Yes, perex/alsa.git "mm branch" contains the latest patches from ALSA HG repo.

Quoted 6 lines
Quoted 2 lines

That'd be helpful. Then I'll apply your second part and leave the first part to ppc guys.

Kumar Gala is going to apply the first part. It'll be in his "for-2.6.25" branch. Can I assume that you'll push the second part to alsa.git and then to Linus when the 2.6.25 window opens?

Yes. Usually all the current patches on ALSA HG repo in prior to the merge window are pushed to the next kernel.

Takashi

maintainer
#17 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

In reply to Timur Tabi
Quoted 8 lines · Timur Tabi
Quoted 2 lines · Takashi Iwai

The problem is that HG repo doesn't contain the whole kernel tree but only the ALSA subtree to reduce the repo size.

So is it okay if I use the git repo to base my work? I use git for all other Linux development, so it would be awkward for me to use HG just for ALSA work.

I'm not sure how it will work. The mm tree contains all patches going to mainstream kernel, but the tree is rebased regulary - both #mm and #linus branches (Stacked GIT is used to maintain ALSA patches on top of the Linus's tree).

Jaroslav

-----
Jaroslav Kysela <[email protected]>
Linux Kernel Sound Maintainer
ALSA Project, Red Hat, Inc.

#18 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

Quoted 10 lines · Jaroslav Kysela
Quoted 3 lines · Timur Tabi

So is it okay if I use the git repo to base my work? I use git for all other Linux development, so it would be awkward for me to use HG just for ALSA work.

I'm not sure how it will work. The mm tree contains all patches going to mainstream kernel, but the tree is rebased regulary - both #mm and #linus branches (Stacked GIT is used to maintain ALSA patches on top of the Linus's tree).

For driver work you will often find that you can just do development against Linus' repository since it is fairly uncommon to encounter conflicting changes in the area of the code code that you are working on. Changes can be merged with or cherry picked onto one of the ALSA branches to check that they'll apply correctly before submission without having to deal with that being rebased during development.

#19 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

In reply to Timur Tabi
Quoted 5 lines · Timur Tabi

Update the MPC8610 HPCD files to support the audio driver. Update booting-without-of.txt with information on the SSI device.

---

Can you respin this. It doesn't apply cleanly to my tree.

- k

author
#20 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

Quoted 1 line · Kumar Gala

Can you respin this. It doesn't apply cleanly to my tree.

Ok, but I have a feeling that the merge between alsa-git and powerpc-git is going to be ugly.

Signature · 2 lines
Timur Tabi
Linux kernel developer at Freescale
#21 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

Quoted 6 lines · Timur Tabi
Quoted 1 line · Kumar Gala

Can you respin this. It doesn't apply cleanly to my tree.

Ok, but I have a feeling that the merge between alsa-git and powerpc- git is going to be ugly.

Really, it would seem ok in that the powerpc stuff is only touch files under arch/powerpc. So as long as the alsa is only touching files in drivers/ I think we'll be ok. 8610 my bitch a bit until the two exist in one place.

My merge conflict was because of updates/changes to booting-without- of.txt

- k

#22 lore raw

Re: [PATCH v3] [POWERPC] Update MPC8610 HPCD to support audio drivers

At Fri, 18 Jan 2008 09:18:14 -0600,

Quoted 8 lines · Kumar Gala
Quoted 4 lines · Timur Tabi
Quoted 1 line · Kumar Gala

Can you respin this. It doesn't apply cleanly to my tree.

Quoted 7 lines
Quoted 2 lines

Ok, but I have a feeling that the merge between alsa-git and powerpc- git is going to be ugly.

Really, it would seem ok in that the powerpc stuff is only touch files under arch/powerpc. So as long as the alsa is only touching files in drivers/ I think we'll be ok. 8610 my bitch a bit until the two exist in one place.

The alsa tree doesn't touch ppc tree. It includes only only Timur's second patch, not the first part touching arch/powerpc. So, merging both trees shouldn't conflict.

Takashi