diff options
author | Denis Kenzior <denkenz@gmail.com> | 2010-02-08 12:09:01 -0600 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2010-02-08 12:09:01 -0600 |
commit | 7f9a9b0cdc82d5bb03230a343d5b1504f210c447 (patch) | |
tree | 9f6e294750857e78092b6cc805cdb4218caa8acd /drivers/atmodem | |
parent | 87ca1b0c8f4c5b441eb3209b2b0c867870596882 (diff) | |
download | ofono-7f9a9b0cdc82d5bb03230a343d5b1504f210c447.tar.bz2 |
Fix: Don't use ofono_debug directly in plugins
Diffstat (limited to 'drivers/atmodem')
-rw-r--r-- | drivers/atmodem/call-forwarding.c | 8 | ||||
-rw-r--r-- | drivers/atmodem/call-settings.c | 9 | ||||
-rw-r--r-- | drivers/atmodem/cbs.c | 2 | ||||
-rw-r--r-- | drivers/atmodem/network-registration.c | 18 | ||||
-rw-r--r-- | drivers/atmodem/sim.c | 14 | ||||
-rw-r--r-- | drivers/atmodem/sms.c | 21 | ||||
-rw-r--r-- | drivers/atmodem/voicecall.c | 10 |
7 files changed, 40 insertions, 42 deletions
diff --git a/drivers/atmodem/call-forwarding.c b/drivers/atmodem/call-forwarding.c index b210242f..b5979f65 100644 --- a/drivers/atmodem/call-forwarding.c +++ b/drivers/atmodem/call-forwarding.c @@ -112,10 +112,10 @@ static void ccfc_query_cb(gboolean ok, GAtResult *result, gpointer user_data) } for (i = 0; i < num; i++) - ofono_debug("ccfc_cb: %d, %d, %s(%d) - %d sec", - list[i].status, list[i].cls, - list[i].phone_number.number, - list[i].phone_number.type, list[i].time); + DBG("ccfc_cb: %d, %d, %s(%d) - %d sec", + list[i].status, list[i].cls, + list[i].phone_number.number, + list[i].phone_number.type, list[i].time); out: cb(&error, num, list, cbd->data); diff --git a/drivers/atmodem/call-settings.c b/drivers/atmodem/call-settings.c index 7ec69d39..6c2c4aa4 100644 --- a/drivers/atmodem/call-settings.c +++ b/drivers/atmodem/call-settings.c @@ -71,7 +71,7 @@ static void ccwa_query_cb(gboolean ok, GAtResult *result, gpointer user_data) conditions |= cls; } - ofono_debug("CW enabled for: %d", conditions); + DBG("CW enabled for: %d", conditions); out: cb(&error, conditions, cbd->data); @@ -168,7 +168,7 @@ static void clip_query_cb(gboolean ok, GAtResult *result, gpointer user_data) g_at_result_iter_skip_next(&iter); g_at_result_iter_next_number(&iter, &status); - ofono_debug("clip_query_cb: network: %d", status); + DBG("clip_query_cb: network: %d", status); cb(&error, status, cbd->data); } @@ -220,7 +220,7 @@ static void colp_query_cb(gboolean ok, GAtResult *result, gpointer user_data) g_at_result_iter_skip_next(&iter); g_at_result_iter_next_number(&iter, &status); - ofono_debug("colp_query_cb: network: %d", status); + DBG("colp_query_cb: network: %d", status); cb(&error, status, cbd->data); } @@ -271,8 +271,7 @@ static void clir_query_cb(gboolean ok, GAtResult *result, gpointer user_data) g_at_result_iter_next_number(&iter, &override); g_at_result_iter_next_number(&iter, &network); - ofono_debug("clir_query_cb: override: %d, network: %d", - override, network); + DBG("clir_query_cb: override: %d, network: %d", override, network); cb(&error, override, network, cbd->data); } diff --git a/drivers/atmodem/cbs.c b/drivers/atmodem/cbs.c index adc52b52..1cbd487e 100644 --- a/drivers/atmodem/cbs.c +++ b/drivers/atmodem/cbs.c @@ -78,7 +78,7 @@ static void at_cbm_notify(GAtResult *result, gpointer user_data) return; } - ofono_debug("Got new Cell Broadcast via CBM: %s, %d", hexpdu, pdulen); + DBG("Got new Cell Broadcast via CBM: %s, %d", hexpdu, pdulen); if (decode_hex_own_buf(hexpdu, -1, &hexpdulen, 0, pdu) == NULL) { ofono_error("Unable to hex-decode the PDU"); diff --git a/drivers/atmodem/network-registration.c b/drivers/atmodem/network-registration.c index e8bdd770..d6651532 100644 --- a/drivers/atmodem/network-registration.c +++ b/drivers/atmodem/network-registration.c @@ -166,7 +166,7 @@ static void cops_cb(gboolean ok, GAtResult *result, gpointer user_data) op.status = 2; op.tech = tech; - ofono_debug("cops_cb: %s, %s %s %d", name, nd->mcc, nd->mnc, tech); + DBG("cops_cb: %s, %s %s %d", name, nd->mcc, nd->mnc, tech); cb(&error, &op, cbd->data); @@ -212,7 +212,7 @@ static void cops_numeric_cb(gboolean ok, GAtResult *result, gpointer user_data) extract_mcc_mnc(str, nd->mcc, nd->mnc); - ofono_debug("Cops numeric got mcc: %s, mnc: %s", nd->mcc, nd->mnc); + DBG("Cops numeric got mcc: %s, mnc: %s", nd->mcc, nd->mnc); return; @@ -282,7 +282,7 @@ static void cops_list_cb(gboolean ok, GAtResult *result, gpointer user_data) num += 1; } - ofono_debug("Got %d elements", num); + DBG("Got %d elements", num); list = g_try_new0(struct ofono_network_operator, num); @@ -343,15 +343,15 @@ static void cops_list_cb(gboolean ok, GAtResult *result, gpointer user_data) } } - ofono_debug("Got %d operators", num); + DBG("Got %d operators", num); { int i = 0; for (; i < num; i++) { - ofono_debug("Operator: %s, %s, %s, status: %d, %d", - list[i].name, list[i].mcc, list[i].mnc, - list[i].status, list[i].tech); + DBG("Operator: %s, %s, %s, status: %d, %d", + list[i].name, list[i].mcc, list[i].mnc, + list[i].status, list[i].tech); } } @@ -459,7 +459,7 @@ error: static inline void report_signal_strength(struct ofono_netreg *netreg, int strength) { - ofono_debug("csq_notify: %d", strength); + DBG("csq_notify: %d", strength); if (strength == 99) strength = -1; @@ -657,7 +657,7 @@ static void csq_cb(gboolean ok, GAtResult *result, gpointer user_data) g_at_result_iter_next_number(&iter, &strength); - ofono_debug("csq_cb: %d", strength); + DBG("csq_cb: %d", strength); if (strength == 99) strength = -1; diff --git a/drivers/atmodem/sim.c b/drivers/atmodem/sim.c index 890c4b24..5c3061e4 100644 --- a/drivers/atmodem/sim.c +++ b/drivers/atmodem/sim.c @@ -81,7 +81,7 @@ static void at_crsm_info_cb(gboolean ok, GAtResult *result, gpointer user_data) (sw1 == 0x90 && sw2 != 0x00)) goto error; - ofono_debug("crsm_info_cb: %02x, %02x, %i", sw1, sw2, len); + DBG("crsm_info_cb: %02x, %02x, %i", sw1, sw2, len); if (response[0] == 0x62) ok = sim_parse_3g_get_response(response, len, &flen, &rlen, @@ -162,7 +162,7 @@ static void at_crsm_read_cb(gboolean ok, GAtResult *result, return; } - ofono_debug("crsm_read_cb: %02x, %02x, %d", sw1, sw2, len); + DBG("crsm_read_cb: %02x, %02x, %d", sw1, sw2, len); cb(&error, response, len, cbd->data); } @@ -250,7 +250,7 @@ static void at_crsm_update_cb(gboolean ok, GAtResult *result, return; } - ofono_debug("crsm_update_cb: %02x, %02x", sw1, sw2); + DBG("crsm_update_cb: %02x, %02x", sw1, sw2); cb(&error, cbd->data); } @@ -379,7 +379,7 @@ static void at_cimi_cb(gboolean ok, GAtResult *result, gpointer user_data) imsi = g_at_result_iter_raw_line(&iter); - ofono_debug("cimi_cb: %s", imsi); + DBG("cimi_cb: %s", imsi); cb(&error, imsi, cbd->data); } @@ -467,7 +467,7 @@ static void at_cpin_cb(gboolean ok, GAtResult *result, gpointer user_data) return; } - ofono_debug("crsm_pin_cb: %s", pin_required); + DBG("crsm_pin_cb: %s", pin_required); cb(&error, pin_type, cbd->data); } @@ -670,7 +670,7 @@ static void at_lock_status_cb(gboolean ok, GAtResult *result, g_at_result_iter_next_number(&iter, &locked); - ofono_debug("lock_status_cb: %i", locked); + DBG("lock_status_cb: %i", locked); cb(&error, locked, cbd->data); } @@ -735,7 +735,7 @@ static void at_csim_envelope_cb(gboolean ok, GAtResult *result, response[len - 2] != 0x90 || response[len - 1] != 0) goto error; - ofono_debug("csim_envelope_cb: %i", len); + DBG("csim_envelope_cb: %i", len); cb(&error, response, len - 2, cbd->data); return; diff --git a/drivers/atmodem/sms.c b/drivers/atmodem/sms.c index 0b8b902f..41394098 100644 --- a/drivers/atmodem/sms.c +++ b/drivers/atmodem/sms.c @@ -158,7 +158,7 @@ static void at_csca_query_cb(gboolean ok, GAtResult *result, gpointer user_data) g_at_result_iter_next_number(&iter, &sca.type); - ofono_debug("csca_query_cb: %s, %d", sca.number, sca.type); + DBG("csca_query_cb: %s, %d", sca.number, sca.type); cb(&error, &sca, cbd->data); @@ -212,7 +212,7 @@ static void at_cmgs_cb(gboolean ok, GAtResult *result, gpointer user_data) if (!g_at_result_iter_next_number(&iter, &mr)) goto err; - ofono_debug("Got MR: %d", mr); + DBG("Got MR: %d", mr); cb(&error, mr, cbd->data); return; @@ -296,7 +296,7 @@ static void at_cds_notify(GAtResult *result, gpointer user_data) return; } - ofono_debug("Got new Status-Report PDU via CDS: %s, %d", pdu, pdulen); + DBG("Got new Status-Report PDU via CDS: %s, %d", pdu, pdulen); /* We must acknowledge the PDU using CNMA */ if (data->cnma_ack_pdu) @@ -330,8 +330,7 @@ static void at_cmt_notify(GAtResult *result, gpointer user_data) return; } - ofono_debug("Got new SMS Deliver PDU via CMT: %s, %d", - hexpdu, tpdu_len); + DBG("Got new SMS Deliver PDU via CMT: %s, %d", hexpdu, tpdu_len); decode_hex_own_buf(hexpdu, -1, &pdu_len, 0, pdu); ofono_sms_deliver_notify(sms, pdu, pdu_len, tpdu_len); @@ -376,7 +375,7 @@ static void at_cmgr_notify(GAtResult *result, gpointer user_data) if (strlen(hexpdu) > sizeof(pdu) * 2) goto err; - ofono_debug("Got PDU: %s, with len: %d", hexpdu, tpdu_len); + DBG("Got PDU: %s, with len: %d", hexpdu, tpdu_len); decode_hex_own_buf(hexpdu, -1, &pdu_len, 0, pdu); ofono_sms_deliver_notify(sms, pdu, pdu_len, tpdu_len); @@ -449,7 +448,7 @@ static void at_cmti_notify(GAtResult *result, gpointer user_data) if (!g_at_result_iter_next_number(&iter, &index)) goto err; - ofono_debug("Got a CMTI indication at %s, index: %d", strstore, index); + DBG("Got a CMTI indication at %s, index: %d", strstore, index); if (store == data->store) { struct cpms_request req; @@ -525,7 +524,7 @@ static void at_cmgl_notify(GAtResult *result, gpointer user_data) hexpdu = g_at_result_pdu(result); - ofono_debug("Found an old SMS PDU: %s, with len: %d", + DBG("Found an old SMS PDU: %s, with len: %d", hexpdu, tpdu_len); if (strlen(hexpdu) > sizeof(pdu) * 2) @@ -550,7 +549,7 @@ static void at_cmgl_cb(gboolean ok, GAtResult *result, gpointer user_data) struct ofono_sms *sms = user_data; if (!ok) - ofono_debug("Initial listing SMS storage failed!"); + DBG("Initial listing SMS storage failed!"); at_cmgl_done(sms); } @@ -855,7 +854,7 @@ static void at_cmgf_set_cb(gboolean ok, GAtResult *result, gpointer user_data) data->retries += 1; if (data->retries == MAX_CMGF_RETRIES) { - ofono_debug("Unable to enter PDU mode"); + DBG("Unable to enter PDU mode"); return at_sms_not_supported(sms); } @@ -1065,7 +1064,7 @@ static void at_csms_query_cb(gboolean ok, GAtResult *result, if (status_min <= 1 && 1 <= status_max) cnma_supported = TRUE; - ofono_debug("CSMS query parsed successfully"); + DBG("CSMS query parsed successfully"); out: snprintf(buf, sizeof(buf), "AT+CSMS=%d", cnma_supported ? 1 : 0); diff --git a/drivers/atmodem/voicecall.c b/drivers/atmodem/voicecall.c index efee9cdc..8e432534 100644 --- a/drivers/atmodem/voicecall.c +++ b/drivers/atmodem/voicecall.c @@ -302,7 +302,7 @@ static void atd_cb(gboolean ok, GAtResult *result, gpointer user_data) else validity = 2; - ofono_debug("colp_notify: %s %d %d", num, type, validity); + DBG("colp_notify: %s %d %d", num, type, validity); } /* Generate a voice call that was just dialed, we guess the ID */ @@ -662,7 +662,7 @@ static void cring_notify(GAtResult *result, gpointer user_data) */ vd->clcc_source = g_timeout_add(CLIP_INTERVAL, poll_clcc, vc); - ofono_debug("cring_notify"); + DBG("cring_notify"); } static void clip_notify(GAtResult *result, gpointer user_data) @@ -709,7 +709,7 @@ static void clip_notify(GAtResult *result, gpointer user_data) /* If we have CLI validity field, override our guessed value */ g_at_result_iter_next_number(&iter, &validity); - ofono_debug("clip_notify: %s %d %d", num, type, validity); + DBG("clip_notify: %s %d %d", num, type, validity); call = l->data; @@ -772,7 +772,7 @@ static void ccwa_notify(GAtResult *result, gpointer user_data) /* If we have CLI validity field, override our guessed value */ g_at_result_iter_next_number(&iter, &validity); - ofono_debug("ccwa_notify: %s %d %d %d", num, num_type, cls, validity); + DBG("ccwa_notify: %s %d %d %d", num, num_type, cls, validity); call = create_call(vc, class_to_call_type(cls), 1, 5, num, num_type, validity); @@ -827,7 +827,7 @@ static void at_voicecall_initialized(gboolean ok, GAtResult *result, struct ofono_voicecall *vc = user_data; struct voicecall_data *vd = ofono_voicecall_get_data(vc); - ofono_debug("voicecall_init: registering to notifications"); + DBG("voicecall_init: registering to notifications"); g_at_chat_register(vd->chat, "RING", ring_notify, FALSE, vc, NULL); g_at_chat_register(vd->chat, "+CRING:", cring_notify, FALSE, vc, NULL); |