Merge "[Bugfix][T106BUG-291]fix the AT's response code;add cgir prefix;fix cgps correct response"
diff --git a/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-autosuspend/files/autosuspend_wakeup_count.c b/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-autosuspend/files/autosuspend_wakeup_count.c
index 85fbc84..b1d03ff 100755
--- a/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-autosuspend/files/autosuspend_wakeup_count.c
+++ b/cap/zx297520v3/sources/meta-zxic-custom/recipes-lynq/lynq-autosuspend/files/autosuspend_wakeup_count.c
@@ -235,13 +235,26 @@
}
#endif
-static int suspend_ctrl(char *wakeup_count,int wakeup_count_len)
+#ifdef MOBILETEK_TARGET_PLATFORM_T106
+int t106_early_suspend(void)
{
+ RLOGD("t106_early_suspend start\n");
+ system("/etc/init.d/syslog stop");
+ return 0;
+}
+void t106_early_resume(void)
+{
+ RLOGD("t106_early_resume start\n");
+ system("/etc/init.d/syslog start");
+ return NULL;
+}
+#endif
- char buf[80];
- int ret = 0;
#ifdef MOBILETEK_SUSPEND_CFG
+int t800_early_suspend(char *wakeup_count, int wakeup_count_len)
+{
+ char buf[80];
system("echo \"Sys standby mode\" >/dev/console");
// sleep(1);
system("echo 7 | emdlogger_ctrl");
@@ -278,6 +291,63 @@
return -1;
}
}
+ return 0;
+}
+
+void t800_early_resume(bool success)
+{
+ system("hwclock -s");
+ RLOGD("TIME: rtc to sys\n");
+ if (!success)
+ {
+
+ system("mdlogctl start");
+
+ system("echo 8 | emdlogger_ctrl");
+
+ usleep(200000);
+ ALOGI("Log on with failure\n");
+ return ;
+ }
+
+ if (lynq_screen(1) != 0) // notify ril for screen on
+ {
+ ALOGI("lynq_screen on fail\n");
+ }
+
+ system("mdlogctl start");
+
+ system("echo 8 | emdlogger_ctrl");
+ usleep(300000); //delay 2s for ril handling screen on,at least 70ms
+
+ return NULL;
+}
+#endif
+
+
+static int suspend_ctrl(char *wakeup_count,int wakeup_count_len)
+{
+
+
+ char buf[80];
+ int ret = 0;
+#ifdef MOBILETEK_SUSPEND_CFG
+ ret = t800_early_suspend(char *wakeup_count, wakeup_count_len);
+ if(ret != 0)
+ {
+ ALOGD("t800_early_suspend fail\n");
+ return -1;
+ }
+#endif
+
+
+#ifdef MOBILETEK_TARGET_PLATFORM_T106
+ ret = t106_early_suspend();
+ if(ret != 0)
+ {
+ ALOGD("t106_early_suspend fail\n");
+ return -1;
+ }
#endif
system("echo \"autosuspend:Sys suspend\" >/dev/console");
@@ -297,35 +367,14 @@
char buf[80];
long sleeptime = 0;
+
#ifdef MOBILETEK_SUSPEND_CFG
- system("hwclock -s");
- RLOGD("TIME: rtc to sys\n");
- if (!success)
- {
+ t800_early_resume(bool success);
+#endif
- system("mdlogctl start");
- system("echo 8 | emdlogger_ctrl");
-
- usleep(200000);
- ALOGI("Log on with failure\n");
- return ;
- }
-
-
- if (lynq_screen(1) != 0) // notify ril for screen on
- {
- ALOGI("lynq_screen on fail\n");
-
- }
-
- system("mdlogctl start");
-
-// sleep(1);
-
- system("echo 8 | emdlogger_ctrl");
-
- usleep(300000); //delay 2s for ril handling screen on,at least 70ms
+#ifdef MOBILETEK_TARGET_PLATFORM_T106
+ t106_early_resume();
#endif
pthread_mutex_lock(&time_info_mutex);
diff --git a/cap/zx297520v3/sources/meta-zxic/conf/pub_esdk.inc b/cap/zx297520v3/sources/meta-zxic/conf/pub_esdk.inc
index b66ac77..8b7ec5a 100755
--- a/cap/zx297520v3/sources/meta-zxic/conf/pub_esdk.inc
+++ b/cap/zx297520v3/sources/meta-zxic/conf/pub_esdk.inc
@@ -7,6 +7,7 @@
ZXIC_ZX297520V3_CFLAGS += "-I${BSPDIR}/pub/project/zx297520v3/include/drv "
ZXIC_ZX297520V3_CFLAGS += "-I${BSPDIR}/pub/project/zx297520v3/include/nv "
ZXIC_ZX297520V3_CFLAGS += "-D_CHIP_ZX297520V3 -DCPU_SHIFT=0 -D_USE_VEHICLE_DC -D_USE_ZXIC_DEBUG_INFO"
+ZXIC_ZX297520V3_CFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'vehicle_dc_ref', '-D_USE_VEHICLE_DC_REF', '', d)}"
ZXIC_EXTRA_CFLAGS += "${@bb.utils.contains('MACHINE', 'zx297520v3', '${ZXIC_ZX297520V3_CFLAGS}', '', d)}"
diff --git a/cap/zx297520v3/src/lynq/lib/liblynq-qser-data/lynq-qser-data.cpp b/cap/zx297520v3/src/lynq/lib/liblynq-qser-data/lynq-qser-data.cpp
index b5b2f6c..85767bc 100755
--- a/cap/zx297520v3/src/lynq/lib/liblynq-qser-data/lynq-qser-data.cpp
+++ b/cap/zx297520v3/src/lynq/lib/liblynq-qser-data/lynq-qser-data.cpp
@@ -411,6 +411,11 @@
sum_node = sum_node->next;
continue;
}
+ else if(strcmp((char *)xmlGetProp(sum_node, "apn_type"), apn->apn_type) == 0)
+ {
+ LYERRLOG("apntype already exists\n");
+ goto FAILED;
+ }
node_num++;
sum_node = sum_node->next;
}