[ARM] pxa: add the missing AC97 pin configurations
authorEric Miao <eric.y.miao@gmail.com>
Mon, 4 Jan 2010 09:00:13 +0000 (17:00 +0800)
committerEric Miao <eric.y.miao@gmail.com>
Mon, 1 Mar 2010 23:40:48 +0000 (07:40 +0800)
Missing AC97 pin configurations are added where pxa_set_ac97_info() are
called for all pxa25x/pxa27x platforms. Where no exact configuration is
provided, use the default as in sound/arm/pxa2xx-ac97-lib.c

Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
12 files changed:
arch/arm/mach-pxa/balloon3.c
arch/arm/mach-pxa/e740.c
arch/arm/mach-pxa/e750.c
arch/arm/mach-pxa/e800.c
arch/arm/mach-pxa/lpd270.c
arch/arm/mach-pxa/lubbock.c
arch/arm/mach-pxa/mainstone.c
arch/arm/mach-pxa/mioa701.c
arch/arm/mach-pxa/pcm990-baseboard.c
arch/arm/mach-pxa/trizeps4.c
arch/arm/mach-pxa/viper.c
arch/arm/mach-pxa/zeus.c

index 6f813aa4c79c8d4f6b4ebeba5953df724f3e4d3b..f3b5ace815e51488f8437f4fc08866e6478e12be 100644 (file)
@@ -132,6 +132,14 @@ static void __init balloon3_init_irq(void)
                "enabled\n", __func__, BALLOON3_AUX_NIRQ);
 }
 
+static unsigned long balloon3_ac97_pin_config[] = {
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+       GPIO113_AC97_nRESET,
+};
+
 static void balloon3_backlight_power(int on)
 {
        pr_debug("%s: power is %s\n", __func__, on ? "on" : "off");
@@ -292,8 +300,10 @@ static void __init balloon3_init(void)
        pxa_set_stuart_info(NULL);
 
        pxa_set_i2c_info(NULL);
-       if (balloon3_has(BALLOON3_FEATURE_AUDIO))
+       if (balloon3_has(BALLOON3_FEATURE_AUDIO)) {
+               pxa2xx_mfp_config(ARRAY_AND_SIZE(balloon3_ac97_pin_config));
                pxa_set_ac97_info(NULL);
+       }
 
        if (balloon3_has(BALLOON3_FEATURE_TOPPOLY)) {
                pxa2xx_mfp_config(ARRAY_AND_SIZE(balloon3_lcd_pin_config));
index 94b23a9e3877ed053e42170803b8519029076bf5..d578021d1a10039752ac9da211e3ad4911f909db 100644 (file)
@@ -134,6 +134,12 @@ static unsigned long e740_pin_config[] __initdata = {
        /* IrDA */
        GPIO38_GPIO | MFP_LPM_DRIVE_HIGH,
 
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+
        /* Audio power control */
        GPIO16_GPIO,  /* AC97 codec AVDD2 supply (analogue power) */
        GPIO40_GPIO,  /* Mic amp power */
index 5eccbce73a3300621ef3beecd4977054f4bc32dc..af83caa52dd42147bc45c4fe83e5ea8a7cae2965 100644 (file)
@@ -132,6 +132,12 @@ static unsigned long e750_pin_config[] __initdata = {
        /* IrDA */
        GPIO38_GPIO | MFP_LPM_DRIVE_HIGH,
 
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+
        /* Audio power control */
        GPIO4_GPIO,  /* Headphone amp power */
        GPIO7_GPIO,  /* Speaker amp power */
index aad129bed19928ed61cd531269b5ffc8a6dd8d2f..8ea97bf53fe16681a2a584b67809d41729c24c47 100644 (file)
 
 /* ------------------------ e800 LCD definitions ------------------------- */
 
+static unsigned long e800_pin_config[] __initdata = {
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+};
+
 static struct w100_gen_regs e800_lcd_regs = {
        .lcd_format =            0x00008003,
        .lcdd_cntl1 =            0x02a00000,
@@ -195,6 +203,7 @@ static struct platform_device *devices[] __initdata = {
 
 static void __init e800_init(void)
 {
+       pxa2xx_mfp_config(ARRAY_AND_SIZE(e800_pin_config));
        pxa_set_ffuart_info(NULL);
        pxa_set_btuart_info(NULL);
        pxa_set_stuart_info(NULL);
index c87abc3334cbfc6dbf5250bfe62c5eaa2b29c6a4..d279507fc748275dfff6670544699cf6464eee7f 100644 (file)
@@ -83,6 +83,10 @@ static unsigned long lpd270_pin_config[] __initdata = {
        GPIO89_USBH1_PEN,
 
        /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
        GPIO45_AC97_SYSCLK,
 
        GPIO1_GPIO | WAKEUP_ON_EDGE_BOTH,
index 56ae54ef44f36b104826f24b2f9588afd5be0662..2f5e45e08f5caf9bca9f5fe7898d40a3b60c7316 100644 (file)
@@ -66,6 +66,12 @@ static unsigned long lubbock_pin_config[] __initdata = {
        GPIO25_SSP1_TXD,
        GPIO26_SSP1_RXD,
 
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+
        /* LCD - 16bpp DSTN */
        GPIOxx_LCD_DSTN_16BPP,
 
index 36370392abe1c05354d5ec2c32ee4f3595b8b7d6..5543c64da9efbaedf903d8eaff3904616f90bd7e 100644 (file)
@@ -88,6 +88,10 @@ static unsigned long mainstone_pin_config[] = {
        GPIO57_nIOIS16,
 
        /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
        GPIO45_AC97_SYSCLK,
 
        /* Keypad */
index ca47ee19248b414c5195aaf8e831581a06185323..843fcca76e26dc4153cf79128f964f7c20eace94 100644 (file)
@@ -137,6 +137,10 @@ static unsigned long mioa701_pin_config[] = {
        GPIO41_FFUART_RTS,
 
        /* Sound */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
        GPIO89_AC97_SYSCLK,
        MIO_CFG_IN(GPIO12_HPJACK_INSERT, AF0),
 
index e74bdfc2551df893a49e54065eaecb60df0ce1de..9d0ecea1760c9608c05a7d4e907cfa90e726da9e 100644 (file)
@@ -58,6 +58,12 @@ static unsigned long pcm990_pin_config[] __initdata = {
        /* I2C */
        GPIO117_I2C_SCL,
        GPIO118_I2C_SDA,
+
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
 };
 
 /*
index 441600845a72eee1be6b3e918d9ce5b76ed3fe51..797f2544d0ce7170ea02f61f0f6f9a17160f4d8f 100644 (file)
@@ -72,6 +72,12 @@ static unsigned long trizeps4_pin_config[] __initdata = {
        GPIO79_nCS_3,           /* Logic CS */
        GPIO0_GPIO | WAKEUP_ON_EDGE_RISE,       /* Logic irq */
 
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+
        /* LCD - 16bpp Active TFT */
        GPIOxx_LCD_TFT_16BPP,
 
index 12d4ed338d037ef170519ab8c47037727b5d0c1d..1dd13346f977a14ab0c39b59136a50ca8b2d5d59 100644 (file)
@@ -711,6 +711,12 @@ static mfp_cfg_t viper_pin_config[] __initdata = {
        GPIO80_nCS_4,
        GPIO33_nCS_5,
 
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+
        /* FP Backlight */
        GPIO9_GPIO,                             /* VIPER_BCKLIGHT_EN_GPIO */
        GPIO10_GPIO,                            /* VIPER_LCD_EN_GPIO */
index 75f2a37f945df03afd4d8e50d10e627fbea701f0..9c2ec776f601e82336f560c06f0b02543d3f9394 100644 (file)
@@ -706,6 +706,12 @@ static struct i2c_board_info __initdata zeus_i2c_devices[] = {
 };
 
 static mfp_cfg_t zeus_pin_config[] __initdata = {
+       /* AC97 */
+       GPIO28_AC97_BITCLK,
+       GPIO29_AC97_SDATA_IN_0,
+       GPIO30_AC97_SDATA_OUT,
+       GPIO31_AC97_SYNC,
+
        GPIO15_nCS_1,
        GPIO78_nCS_2,
        GPIO80_nCS_4,