msm: mdm: GPIO changes for I2S devices
mdm GPIO configuration for I2S devices is now supported. Additionally
the mdm-driver can now handle the case where one of the lines it is
monitoring is assigned to GPIO 0.
Change-Id: I75fd06fc4f83fe652ab3bbb75980f2454a0f3621
Signed-off-by: Ameya Thakur <ameyat@codeaurora.org>
diff --git a/arch/arm/mach-msm/devices-8064.c b/arch/arm/mach-msm/devices-8064.c
index 1f0bd2c..792bc1d 100644
--- a/arch/arm/mach-msm/devices-8064.c
+++ b/arch/arm/mach-msm/devices-8064.c
@@ -2369,8 +2369,11 @@
#define MDM2AP_STATUS 49
#define AP2MDM_STATUS 48
#define AP2MDM_SOFT_RESET 27
+#define I2S_AP2MDM_SOFT_RESET 0
#define AP2MDM_WAKEUP 35
+#define I2S_AP2MDM_WAKEUP 44
#define MDM2AP_PBLRDY 46
+#define I2S_MDM2AP_PBLRDY 81
static struct resource mdm_resources[] = {
{
@@ -2417,6 +2420,51 @@
},
};
+static struct resource i2s_mdm_resources[] = {
+ {
+ .start = MDM2AP_ERRFATAL,
+ .end = MDM2AP_ERRFATAL,
+ .name = "MDM2AP_ERRFATAL",
+ .flags = IORESOURCE_IO,
+ },
+ {
+ .start = AP2MDM_ERRFATAL,
+ .end = AP2MDM_ERRFATAL,
+ .name = "AP2MDM_ERRFATAL",
+ .flags = IORESOURCE_IO,
+ },
+ {
+ .start = MDM2AP_STATUS,
+ .end = MDM2AP_STATUS,
+ .name = "MDM2AP_STATUS",
+ .flags = IORESOURCE_IO,
+ },
+ {
+ .start = AP2MDM_STATUS,
+ .end = AP2MDM_STATUS,
+ .name = "AP2MDM_STATUS",
+ .flags = IORESOURCE_IO,
+ },
+ {
+ .start = I2S_AP2MDM_SOFT_RESET,
+ .end = I2S_AP2MDM_SOFT_RESET,
+ .name = "AP2MDM_SOFT_RESET",
+ .flags = IORESOURCE_IO,
+ },
+ {
+ .start = I2S_AP2MDM_WAKEUP,
+ .end = I2S_AP2MDM_WAKEUP,
+ .name = "AP2MDM_WAKEUP",
+ .flags = IORESOURCE_IO,
+ },
+ {
+ .start = I2S_MDM2AP_PBLRDY,
+ .end = I2S_MDM2AP_PBLRDY,
+ .name = "MDM2AP_PBLRDY",
+ .flags = IORESOURCE_IO,
+ },
+};
+
struct platform_device mdm_8064_device = {
.name = "mdm2_modem",
.id = -1,
@@ -2424,6 +2472,12 @@
.resource = mdm_resources,
};
+struct platform_device i2s_mdm_8064_device = {
+ .name = "mdm2_modem",
+ .id = -1,
+ .num_resources = ARRAY_SIZE(i2s_mdm_resources),
+ .resource = i2s_mdm_resources,
+};
static int apq8064_LPM_latency = 1000; /* >100 usec for WFI */
struct platform_device apq8064_cpu_idle_device = {