Skip to content

Commit

Permalink
ARM: mvebu: add audio support to Armada 370 DB
Browse files Browse the repository at this point in the history
This commit adds the necessary Device Tree informations to enable
audio support on the Armada 370 DB platform. In details it:

 * Instantiates the CS42L51 audio codec on the I2C0 bus, and
   configures this bus with the appropriate pin-muxing configuration.

 * Enables the I2S audio controller, and configures it with the
   appropriate pin-muxing configuration.

 * Through hog pins, ensures that the other pins possibly used for I2S
   are muxed with another function than I2S.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
  • Loading branch information
Thomas Petazzoni authored and Jason Cooper committed Feb 17, 2014
1 parent 8d001f0 commit 249f382
Showing 1 changed file with 48 additions and 0 deletions.
48 changes: 48 additions & 0 deletions arch/arm/boot/dts/armada-370-db.dts
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,22 @@
phy-mode = "rgmii-id";
};

i2c@11000 {
pinctrl-0 = <&i2c0_pins>;
pinctrl-names = "default";
status = "okay";
audio_codec: audio-codec@4a {
compatible = "cirrus,cs42l51";
reg = <0x4a>;
};
};

audio-controller@30000 {
pinctrl-0 = <&i2s_pins2>;
pinctrl-names = "default";
status = "okay";
};

mvsdio@d4000 {
pinctrl-0 = <&sdio_pins1>;
pinctrl-names = "default";
Expand All @@ -80,6 +96,30 @@
broken-cd;
};

pinctrl {
/*
* These pins might be muxed as I2S by
* the bootloader, but it conflicts
* with the real I2S pins that are
* muxed using i2s_pins. We must mux
* those pins to a function other than
* I2S.
*/
pinctrl-0 = <&hog_pins1 &hog_pins2>;
pinctrl-names = "default";

hog_pins1: hog-pins1 {
marvell,pins = "mpp6", "mpp8", "mpp10",
"mpp12", "mpp13";
marvell,function = "gpio";
};

hog_pins2: hog-pins2 {
marvell,pins = "mpp5", "mpp7", "mpp9";
marvell,function = "gpo";
};
};

usb@50000 {
status = "okay";
};
Expand Down Expand Up @@ -112,10 +152,18 @@
/* Port 0, Lane 0 */
status = "okay";
};

pcie@2,0 {
/* Port 1, Lane 0 */
status = "okay";
};
};
};

sound {
compatible = "marvell,a370db-audio";
marvell,audio-controller = <&audio_controller>;
marvell,audio-codec = <&audio_codec>;
status = "okay";
};
};

0 comments on commit 249f382

Please sign in to comment.