Android-x86
Fork
Donation

  • R/O
  • HTTP
  • SSH
  • HTTPS

hardware-ril: Commit

hardware/ril


Commit MetaInfo

Revisión87e1dfeeaa75dc7671c89c8787646e7df1afdf35 (tree)
Tiempo2010-09-13 19:12:50
AutorChih-Wei Huang <cwhuang@linu...>
CommiterChih-Wei Huang

Log Message

Support 3G modem card on x86

Change-Id: I47b7dd5e1610a285a1a413dee1843018f097d9a0

Cambiar Resumen

Diferencia

--- a/reference-ril/reference-ril.c
+++ b/reference-ril/reference-ril.c
@@ -36,11 +36,12 @@
3636
3737 #define LOG_TAG "RIL"
3838 #include <utils/Log.h>
39+#include <cutils/properties.h>
3940
4041 #define MAX_AT_RESPONSE 0x1000
4142
4243 /* pathname returned from RIL_REQUEST_SETUP_DATA_CALL / RIL_REQUEST_SETUP_DEFAULT_PDP */
43-#define PPP_TTY_PATH "/dev/omap_csmi_tty1"
44+#define PPP_TTY_PATH "/dev/ppp0"
4445
4546 #ifdef USE_TI_COMMANDS
4647
@@ -241,7 +242,8 @@ static void onSIMReady()
241242 * ds = 1 // Status reports routed to TE
242243 * bfr = 1 // flush buffer
243244 */
244- at_send_command("AT+CNMI=1,2,2,1,1", NULL);
245+ LOGI ("######### SIM READY !!\n");
246+ at_send_command("AT+CNMI=1,2,2,1,0", NULL);
245247 }
246248
247249 static void requestRadioPower(void *data, size_t datalen, RIL_Token t)
@@ -1033,8 +1035,8 @@ static void requestSetupDataCall(void *data, size_t datalen, RIL_Token t)
10331035
10341036 if (qmistatus < 0) goto error;
10351037
1036- } else {
1037-
1038+ } else {
1039+#if 0
10381040 asprintf(&cmd, "AT+CGDCONT=1,\"IP\",\"%s\",,0,0", apn);
10391041 //FIXME check for error here
10401042 err = at_send_command(cmd, NULL);
@@ -1058,6 +1060,7 @@ static void requestSetupDataCall(void *data, size_t datalen, RIL_Token t)
10581060 if (err < 0 || p_response->success == 0) {
10591061 goto error;
10601062 }
1063+#endif
10611064 }
10621065
10631066 RIL_onRequestComplete(t, RIL_E_SUCCESS, response, sizeof(response));
@@ -1838,9 +1841,6 @@ static void initializeCallback(void *param)
18381841 /* Alternating voice/data off */
18391842 at_send_command("AT+CMOD=0", NULL);
18401843
1841- /* Not muted */
1842- at_send_command("AT+CMUT=0", NULL);
1843-
18441844 /* +CSSU unsolicited supp service notifications */
18451845 at_send_command("AT+CSSN=0,1", NULL);
18461846
@@ -2033,7 +2033,7 @@ mainLoop(void *param)
20332033 SOCK_STREAM );
20342034 } else if (s_device_path != NULL) {
20352035 fd = open (s_device_path, O_RDWR);
2036- if ( fd >= 0 && !memcmp( s_device_path, "/dev/ttyS", 9 ) ) {
2036+ if (fd >= 0) {
20372037 /* disable echo on serial ports */
20382038 struct termios ios;
20392039 tcgetattr( fd, &ios );
--- a/rild/rild.c
+++ b/rild/rild.c
@@ -132,7 +132,7 @@ int main(int argc, char **argv)
132132 }
133133
134134 /* special override when in the emulator */
135-#if 1
135+#if 0
136136 {
137137 static char* arg_overrides[3];
138138 static char arg_device[32];
Show on old repository browser