sync : rk2928 add phonepad support
authorxkd <xkd@rock-chips.com>
Thu, 28 Mar 2013 11:28:44 +0000 (19:28 +0800)
committerxkd <xkd@rock-chips.com>
Thu, 28 Mar 2013 11:28:44 +0000 (19:28 +0800)
commit:72d981d8fde265a5b3768be98f4ee1ed1778b19d

arch/arm/mach-rk2928/board-rk2926-sdk.c
arch/arm/mach-rk2928/board-rk2928-a720.c
arch/arm/mach-rk2928/board-rk2928-sdk.c
arch/arm/mach-rk2928/board-rk2928-tb.c

index dffaa1ea194932959e02a1c8b9dcc37ee2bd0e66..4f409d337c36b959b0b41f562246928db2af65cd 100755 (executable)
 #include "../../../drivers/spi/rk29_spim.h"
 #endif
 
+#ifdef CONFIG_SND_SOC_RK2928
+#include "../../../sound/soc/codecs/rk2928_codec.h"
+#endif
+
 #include "board-rk2928-sdk-camera.c" 
 #include "board-rk2928-sdk-key.c"
 
@@ -809,6 +813,17 @@ struct rk29_sdmmc_platform_data default_sdmmc1_data = {
 
 
 #ifdef CONFIG_SND_SOC_RK2928
+static int hpctl_io_init(void)
+{
+    int ret = 0;
+    return ret;
+}
+
+struct rk2928_codec_pdata rk2928_codec_pdata_info={
+    .hpctl = INVALID_GPIO,
+    .hpctl_io_init = hpctl_io_init,
+};
+
 static struct resource resources_acodec[] = {
        {
                .start  = RK2928_ACODEC_PHYS,
@@ -827,6 +842,9 @@ static struct platform_device device_acodec = {
        .id             = -1,
        .num_resources  = ARRAY_SIZE(resources_acodec),
        .resource       = resources_acodec,
+    .dev = {
+        .platform_data = &rk2928_codec_pdata_info,
+    }
 };
 #endif
 
index c93d9e375a1cabe9b22daa864b2cc2c3066710b2..f99dddf1926c19260757be3c4d420bb431733e2b 100755 (executable)
 #include "../../../drivers/spi/rk29_spim.h"
 #endif
 
+#ifdef CONFIG_SND_SOC_RK2928
+#include "../../../sound/soc/codecs/rk2928_codec.h"
+#endif
+
 #include "board-rk2928-a720-camera.c" 
 #include "board-rk2928-a720-key.c"
 
@@ -584,6 +588,17 @@ struct rk29_sdmmc_platform_data default_sdmmc0_data = {
 #endif // CONFIG_SDMMC0_RK29
 
 #ifdef CONFIG_SND_SOC_RK2928
+static int hpctl_io_init(void)
+{
+    int ret=0;
+    return ret;
+}
+
+struct rk2928_codec_pdata rk2928_codec_pdata_info={
+    .hpctl = INVALID_GPIO,
+    .hpctl_io_init = hpctl_io_init,
+};
+
 static struct resource resources_acodec[] = {
        {
                .start  = RK2928_ACODEC_PHYS,
@@ -602,6 +617,9 @@ static struct platform_device device_acodec = {
        .id             = -1,
        .num_resources  = ARRAY_SIZE(resources_acodec),
        .resource       = resources_acodec,
+    .dev = {
+        .platform_data = &rk2928_codec_pdata_info,
+    }
 };
 #endif
 
index ac25fa49f4f41591afcf25f1e702525d7fcc7ad2..62c15bdc5cf3d1c5029da78e0d58e6f41128d765 100755 (executable)
 #include "../../../drivers/spi/rk29_spim.h"
 #endif
 
+#ifdef CONFIG_SND_SOC_RK2928
+#include "../../../sound/soc/codecs/rk2928_codec.h"
+#endif
+
 #include "board-rk2928-sdk-camera.c" 
 #include "board-rk2928-sdk-key.c"
 
@@ -822,6 +826,17 @@ static struct platform_device device_mt6622 = {
 #endif
 
 #ifdef CONFIG_SND_SOC_RK2928
+static int hpctl_io_init(void)
+{
+    int ret = 0;
+    return ret;
+}
+
+struct rk2928_codec_pdata rk2928_codec_pdata_info={
+    .hpctl = INVALID_GPIO,
+    .hpctl_io_init = hpctl_io_init,
+};
+
 static struct resource resources_acodec[] = {
        {
                .start  = RK2928_ACODEC_PHYS,
@@ -840,6 +855,9 @@ static struct platform_device device_acodec = {
        .id             = -1,
        .num_resources  = ARRAY_SIZE(resources_acodec),
        .resource       = resources_acodec,
+    .dev = {
+        .platform_data = &rk2928_codec_pdata_info,
+    }
 };
 #endif
 
index e710a96b1c33016dfc61277c3ede95a134af59a1..ef2b64de70aeb791d66ec2a2b595a6ac858fb3ff 100755 (executable)
 #if defined(CONFIG_SPIM_RK29)
 #include "../../../drivers/spi/rk29_spim.h"
 #endif
+
+#ifdef CONFIG_SND_SOC_RK2928
+#include "../../../sound/soc/codecs/rk2928_codec.h"
+#endif
+
 #if defined(CONFIG_GPS_RK)
 #include "../../../drivers/misc/gps/rk_gps/rk_gps.h"
 #endif
@@ -685,6 +690,17 @@ static struct platform_device device_rfkill_rk = {
 #endif
 
 #ifdef CONFIG_SND_SOC_RK2928
+static int hpctl_io_init(void)
+{
+    int ret=0;
+    return ret;
+}
+
+struct rk2928_codec_pdata rk2928_codec_pdata_info={
+    .hpctl = INVALID_GPIO,
+    .hpctl_io_init = hpctl_io_init,
+};
+
 static struct resource resources_acodec[] = {
        {
                .start  = RK2928_ACODEC_PHYS,
@@ -708,6 +724,9 @@ static struct platform_device device_acodec = {
        .id             = -1,
        .num_resources  = ARRAY_SIZE(resources_acodec),
        .resource       = resources_acodec,
+    .dev = {
+        .platform_data = &rk2928_codec_pdata_info,
+    }
 };
 #endif