* [PATCH 0/5] Make use of defined call_status enum
@ 2011-02-04 20:35 Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 1/5] atmodem: use " Jeevaka Badrappan
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: Jeevaka Badrappan @ 2011-02-04 20:35 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 736 bytes --]
Hi,
Following set of patches makes use of the defined call_status enum
instead of using the actual defined values.
Regards,
Jeevaka
Jeevaka Badrappan (5):
atmodem: use defined call_status enum
hfpmodem: Use defined call_status enum
huaweimodem: Use defined call_status enum
ifxmodem: Use defined call_status enum
stemodem: Use defined call_status enum
drivers/atmodem/voicecall.c | 51 ++++++++++++++++++++++++--------------
drivers/hfpmodem/voicecall.c | 12 +++++----
drivers/huaweimodem/voicecall.c | 20 +++++++++------
drivers/ifxmodem/voicecall.c | 33 ++++++++++++++++---------
drivers/stemodem/voicecall.c | 3 +-
5 files changed, 74 insertions(+), 45 deletions(-)
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 1/5] atmodem: use defined call_status enum
2011-02-04 20:35 [PATCH 0/5] Make use of defined call_status enum Jeevaka Badrappan
@ 2011-02-04 20:35 ` Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 2/5] hfpmodem: Use " Jeevaka Badrappan
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Jeevaka Badrappan @ 2011-02-04 20:35 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 6849 bytes --]
---
drivers/atmodem/voicecall.c | 51 +++++++++++++++++++++++++++----------------
1 files changed, 32 insertions(+), 19 deletions(-)
diff --git a/drivers/atmodem/voicecall.c b/drivers/atmodem/voicecall.c
index 583e037..42b44fa 100644
--- a/drivers/atmodem/voicecall.c
+++ b/drivers/atmodem/voicecall.c
@@ -161,7 +161,8 @@ static void clcc_poll_cb(gboolean ok, GAtResult *result, gpointer user_data)
nc = n ? n->data : NULL;
oc = o ? o->data : NULL;
- if (nc && nc->status >= 2 && nc->status <= 5)
+ if (nc && nc->status >= CALL_STATUS_DIALING &&
+ nc->status <= CALL_STATUS_WAITING)
poll_again = TRUE;
if (oc && (nc == NULL || (nc->id > oc->id))) {
@@ -216,7 +217,8 @@ static void clcc_poll_cb(gboolean ok, GAtResult *result, gpointer user_data)
* arrives, or RING is used, then signal the call
* here
*/
- if (nc->status == 4 && (vd->flags & FLAG_NEED_CLIP)) {
+ if (nc->status == CALL_STATUS_INCOMING &&
+ (vd->flags & FLAG_NEED_CLIP)) {
if (nc->type == 0)
ofono_voicecall_notify(vc, nc);
@@ -323,10 +325,10 @@ static void atd_cb(gboolean ok, GAtResult *result, gpointer user_data)
for (l = vd->calls; l; l = l->next) {
call = l->data;
- if (call->status != 0)
+ if (call->status != CALL_STATUS_ACTIVE)
continue;
- call->status = 1;
+ call->status = CALL_STATUS_HELD;
ofono_voicecall_notify(vc, call);
}
@@ -345,7 +347,7 @@ static void atd_cb(gboolean ok, GAtResult *result, gpointer user_data)
}
/* Generate a voice call that was just dialed, we guess the ID */
- call = create_call(vc, 0, 0, 2, num, type, validity);
+ call = create_call(vc, 0, 0, CALL_STATUS_DIALING, num, type, validity);
if (call == NULL) {
ofono_error("Unable to malloc, call tracking will fail!");
return;
@@ -467,14 +469,16 @@ static void at_hold_all_active(struct ofono_voicecall *vc,
static void at_release_all_held(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
- unsigned int held_status = 0x1 << 1;
+ unsigned int held_status = 0x1 << CALL_STATUS_HELD;
at_template("AT+CHLD=0", vc, generic_cb, held_status, cb, data);
}
static void at_set_udub(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
- unsigned int incoming_or_waiting = (0x1 << 4) | (0x1 << 5);
+ unsigned int incoming_or_waiting =
+ (0x1 << CALL_STATUS_INCOMING) | (0x1 << CALL_STATUS_WAITING);
+
at_template("AT+CHLD=0", vc, generic_cb, incoming_or_waiting,
cb, data);
}
@@ -547,7 +551,8 @@ static void at_deflect(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
char buf[128];
- unsigned int incoming_or_waiting = (0x1 << 4) | (0x1 << 5);
+ unsigned int incoming_or_waiting =
+ (0x1 << CALL_STATUS_INCOMING) | (0x1 << CALL_STATUS_WAITING);
snprintf(buf, sizeof(buf), "AT+CTFR=%s,%d", ph->number, ph->type);
at_template(buf, vc, generic_cb, incoming_or_waiting, cb, data);
@@ -631,17 +636,19 @@ static void ring_notify(GAtResult *result, gpointer user_data)
struct ofono_call *call;
/* See comment in CRING */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(5),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_WAITING),
at_util_call_compare_by_status))
return;
/* RING can repeat, ignore if we already have an incoming call */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status))
return;
/* Generate an incoming call of unknown type */
- call = create_call(vc, 9, 1, 4, NULL, 128, 2);
+ call = create_call(vc, 9, 1, CALL_STATUS_INCOMING, NULL, 128, 2);
if (call == NULL) {
ofono_error("Couldn't create call, call management is fubar!");
return;
@@ -667,12 +674,14 @@ static void cring_notify(GAtResult *result, gpointer user_data)
* the stage change. If this happens, simply ignore the RING/CRING
* when a waiting call exists (cannot have waiting + incoming in GSM)
*/
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(5),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_WAITING),
at_util_call_compare_by_status))
return;
/* CRING can repeat, ignore if we already have an incoming call */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status))
return;
@@ -692,7 +701,7 @@ static void cring_notify(GAtResult *result, gpointer user_data)
type = 9;
/* Generate an incoming call */
- create_call(vc, type, 1, 4, NULL, 128, 2);
+ create_call(vc, type, 1, CALL_STATUS_INCOMING, NULL, 128, 2);
/* We have a call, and call type but don't know the number and
* must wait for the CLIP to arrive before announcing the call.
@@ -715,7 +724,8 @@ static void clip_notify(GAtResult *result, gpointer user_data)
GSList *l;
struct ofono_call *call;
- l = g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ l = g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status);
if (l == NULL) {
ofono_error("CLIP for unknown call");
@@ -776,7 +786,8 @@ static void cdip_notify(GAtResult *result, gpointer user_data)
GSList *l;
struct ofono_call *call;
- l = g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ l = g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status);
if (l == NULL) {
ofono_error("CDIP for unknown call");
@@ -824,7 +835,8 @@ static void cnap_notify(GAtResult *result, gpointer user_data)
GSList *l;
struct ofono_call *call;
- l = g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ l = g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status);
if (l == NULL) {
ofono_error("CNAP for unknown call");
@@ -877,7 +889,8 @@ static void ccwa_notify(GAtResult *result, gpointer user_data)
struct ofono_call *call;
/* Some modems resend CCWA, ignore it the second time around */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(5),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_WAITING),
at_util_call_compare_by_status))
return;
@@ -908,7 +921,7 @@ static void ccwa_notify(GAtResult *result, gpointer user_data)
DBG("%s %d %d %d", num, num_type, cls, validity);
- call = create_call(vc, class_to_call_type(cls), 1, 5,
+ call = create_call(vc, class_to_call_type(cls), 1, CALL_STATUS_WAITING,
num, num_type, validity);
if (call == NULL) {
ofono_error("Unable to malloc. Call management is fubar");
--
1.7.0.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/5] hfpmodem: Use defined call_status enum
2011-02-04 20:35 [PATCH 0/5] Make use of defined call_status enum Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 1/5] atmodem: use " Jeevaka Badrappan
@ 2011-02-04 20:35 ` Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 3/5] huaweimodem: " Jeevaka Badrappan
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: Jeevaka Badrappan @ 2011-02-04 20:35 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 2002 bytes --]
---
drivers/hfpmodem/voicecall.c | 12 +++++++-----
1 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/drivers/hfpmodem/voicecall.c b/drivers/hfpmodem/voicecall.c
index a87ddbe..32fc290 100644
--- a/drivers/hfpmodem/voicecall.c
+++ b/drivers/hfpmodem/voicecall.c
@@ -33,7 +33,7 @@
#include <ofono/log.h>
#include <ofono/modem.h>
#include <ofono/voicecall.h>
-#include <common.h>
+#include "common.h"
#include "gatchat.h"
#include "gatresult.h"
@@ -337,7 +337,7 @@ static void atd_cb(gboolean ok, GAtResult *result, gpointer user_data)
for (l = vd->calls; l; l = l->next) {
call = l->data;
- if (call->status != 0)
+ if (call->status != CALL_STATUS_ACTIVE)
continue;
call->status = CALL_STATUS_HELD;
@@ -436,7 +436,7 @@ static void hfp_release_all_held(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
struct voicecall_data *vd = ofono_voicecall_get_data(vc);
- unsigned int held_status = 0x1 << 1;
+ unsigned int held_status = 0x1 << CALL_STATUS_HELD;
if (vd->ag_mpty_features & AG_CHLD_0) {
hfp_template("AT+CHLD=0", vc, generic_cb, held_status,
@@ -451,7 +451,8 @@ static void hfp_set_udub(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
struct voicecall_data *vd = ofono_voicecall_get_data(vc);
- unsigned int incoming_or_waiting = (0x1 << 4) | (0x1 << 5);
+ unsigned int incoming_or_waiting =
+ (0x1 << CALL_STATUS_INCOMING) | (0x1 << CALL_STATUS_WAITING);
if (vd->ag_mpty_features & AG_CHLD_0) {
hfp_template("AT+CHLD=0", vc, generic_cb, incoming_or_waiting,
@@ -647,7 +648,8 @@ static void ccwa_notify(GAtResult *result, gpointer user_data)
DBG("ccwa_notify: %s %d %d", num, num_type, validity);
- call = create_call(vc, 0, 1, 5, num, num_type, validity);
+ call = create_call(vc, 0, 1, CALL_STATUS_WAITING, num, num_type,
+ validity);
if (call == NULL) {
ofono_error("malloc call struct failed. "
--
1.7.0.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 3/5] huaweimodem: Use defined call_status enum
2011-02-04 20:35 [PATCH 0/5] Make use of defined call_status enum Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 1/5] atmodem: use " Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 2/5] hfpmodem: Use " Jeevaka Badrappan
@ 2011-02-04 20:35 ` Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 4/5] ifxmodem: " Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 5/5] stemodem: " Jeevaka Badrappan
4 siblings, 0 replies; 6+ messages in thread
From: Jeevaka Badrappan @ 2011-02-04 20:35 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 2677 bytes --]
---
drivers/huaweimodem/voicecall.c | 20 ++++++++++++--------
1 files changed, 12 insertions(+), 8 deletions(-)
diff --git a/drivers/huaweimodem/voicecall.c b/drivers/huaweimodem/voicecall.c
index 53377d9..1800763 100644
--- a/drivers/huaweimodem/voicecall.c
+++ b/drivers/huaweimodem/voicecall.c
@@ -38,6 +38,7 @@
#include "gatchat.h"
#include "gatresult.h"
+#include "common.h"
#include "huaweimodem.h"
static const char *none_prefix[] = { NULL };
@@ -170,8 +171,9 @@ static void cring_notify(GAtResult *result, gpointer user_data)
int id;
/* CRING can repeat, ignore if we already have an incoming call */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
- at_util_call_compare_by_status))
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
+ at_util_call_compare_by_status))
return;
g_at_result_iter_init(&iter, result);
@@ -192,7 +194,7 @@ static void cring_notify(GAtResult *result, gpointer user_data)
id = ofono_voicecall_get_next_callid(vc);
/* Generate an incoming call */
- create_call(vc, type, 1, 4, NULL, 128, 2, id);
+ create_call(vc, type, 1, CALL_STATUS_INCOMING, NULL, 128, 2, id);
/* Assume the CLIP always arrives, and we signal the call there */
DBG("%d", type);
@@ -208,8 +210,9 @@ static void clip_notify(GAtResult *result, gpointer user_data)
GSList *l;
struct ofono_call *call;
- l = g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
- at_util_call_compare_by_status);
+ l = g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
+ at_util_call_compare_by_status);
if (l == NULL) {
ofono_error("CLIP for unknown call");
return;
@@ -307,7 +310,8 @@ static void orig_notify(GAtResult *result, gpointer user_data)
ofono_info("Call origin: id %d type %d", call_id, call_type);
- call = create_call(vc, call_type, 0, 2, NULL, 128, 2, call_id);
+ call = create_call(vc, call_type, 0, CALL_STATUS_DIALING, NULL, 128, 2,
+ call_id);
if (call == NULL) {
ofono_error("Unable to malloc, call tracking will fail!");
return;
@@ -345,7 +349,7 @@ static void conf_notify(GAtResult *result, gpointer user_data)
/* Set call to alerting */
call = l->data;
- call->status = 3;
+ call->status = CALL_STATUS_ALERTING;
if (call->type == 0)
ofono_voicecall_notify(vc, call);
@@ -382,7 +386,7 @@ static void conn_notify(GAtResult *result, gpointer user_data)
/* Set call to active */
call = l->data;
- call->status = 0;
+ call->status = CALL_STATUS_ACTIVE;
if (call->type == 0)
ofono_voicecall_notify(vc, call);
--
1.7.0.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 4/5] ifxmodem: Use defined call_status enum
2011-02-04 20:35 [PATCH 0/5] Make use of defined call_status enum Jeevaka Badrappan
` (2 preceding siblings ...)
2011-02-04 20:35 ` [PATCH 3/5] huaweimodem: " Jeevaka Badrappan
@ 2011-02-04 20:35 ` Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 5/5] stemodem: " Jeevaka Badrappan
4 siblings, 0 replies; 6+ messages in thread
From: Jeevaka Badrappan @ 2011-02-04 20:35 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 4974 bytes --]
---
drivers/ifxmodem/voicecall.c | 33 +++++++++++++++++++++------------
1 files changed, 21 insertions(+), 12 deletions(-)
diff --git a/drivers/ifxmodem/voicecall.c b/drivers/ifxmodem/voicecall.c
index e7f72fc..a0bee8b 100644
--- a/drivers/ifxmodem/voicecall.c
+++ b/drivers/ifxmodem/voicecall.c
@@ -38,6 +38,7 @@
#include "gatchat.h"
#include "gatresult.h"
+#include "common.h"
#include "ifxmodem.h"
static const char *none_prefix[] = { NULL };
@@ -143,7 +144,8 @@ static void xcallstat_notify(GAtResult *result, gpointer user_data)
* In the case of incoming, we will get the info from CLIP
* indications.
*/
- if (status != 4 && status != 5) {
+ if (status != CALL_STATUS_INCOMING &&
+ status != CALL_STATUS_WAITING) {
ofono_info("Received an XCALLSTAT for an untracked"
" call, this indicates a bug!");
return;
@@ -155,7 +157,7 @@ static void xcallstat_notify(GAtResult *result, gpointer user_data)
call = l->data;
/* Check if call has been disconnected */
- if (status == 6) {
+ if (status == CALL_STATUS_DISCONNECTED) {
enum ofono_disconnect_reason r;
if (vd->local_release & (0x1 << call->id))
@@ -282,7 +284,7 @@ static void atd_cb(gboolean ok, GAtResult *result, gpointer user_data)
}
/* Generate a voice call that was just dialed, we guess the ID */
- call = create_call(vc, 0, 0, 2, num, type, validity);
+ call = create_call(vc, 0, 0, CALL_STATUS_DIALING, num, type, validity);
if (call == NULL) {
ofono_error("Unable to malloc, call tracking will fail!");
return;
@@ -390,14 +392,16 @@ static void ifx_hold_all_active(struct ofono_voicecall *vc,
static void ifx_release_all_held(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
- unsigned int held_status = 0x1 << 1;
+ unsigned int held_status = 0x1 << CALL_STATUS_HELD;
ifx_template("AT+CHLD=0", vc, generic_cb, held_status, cb, data);
}
static void ifx_set_udub(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
- unsigned int incoming_or_waiting = (0x1 << 4) | (0x1 << 5);
+ unsigned int incoming_or_waiting =
+ (0x1 << CALL_STATUS_INCOMING) | (0x1 << CALL_STATUS_WAITING);
+
ifx_template("AT+CHLD=0", vc, generic_cb, incoming_or_waiting,
cb, data);
}
@@ -470,7 +474,8 @@ static void ifx_deflect(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
char buf[128];
- unsigned int incoming_or_waiting = (0x1 << 4) | (0x1 << 5);
+ unsigned int incoming_or_waiting =
+ (0x1 << CALL_STATUS_INCOMING) | (0x1 << CALL_STATUS_WAITING);
snprintf(buf, sizeof(buf), "AT+CTFR=%s,%d", ph->number, ph->type);
ifx_template(buf, vc, generic_cb, incoming_or_waiting, cb, data);
@@ -541,12 +546,14 @@ static void cring_notify(GAtResult *result, gpointer user_data)
* the stage change. If this happens, simply ignore the RING/CRING
* when a waiting call exists (cannot have waiting + incoming in GSM)
*/
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(5),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_WAITING),
at_util_call_compare_by_status))
return;
/* CRING can repeat, ignore if we already have an incoming call */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status))
return;
@@ -566,7 +573,7 @@ static void cring_notify(GAtResult *result, gpointer user_data)
type = 9;
/* Generate an incoming call */
- create_call(vc, type, 1, 4, NULL, 128, 2);
+ create_call(vc, type, 1, CALL_STATUS_INCOMING, NULL, 128, 2);
/* Assume the CLIP always arrives, and we signal the call there */
DBG("cring_notify");
@@ -582,7 +589,8 @@ static void clip_notify(GAtResult *result, gpointer user_data)
GSList *l;
struct ofono_call *call;
- l = g_slist_find_custom(vd->calls, GINT_TO_POINTER(4),
+ l = g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_INCOMING),
at_util_call_compare_by_status);
if (l == NULL) {
ofono_error("CLIP for unknown call");
@@ -637,7 +645,8 @@ static void ccwa_notify(GAtResult *result, gpointer user_data)
struct ofono_call *call;
/* Some modems resend CCWA, ignore it the second time around */
- if (g_slist_find_custom(vd->calls, GINT_TO_POINTER(5),
+ if (g_slist_find_custom(vd->calls,
+ GINT_TO_POINTER(CALL_STATUS_WAITING),
at_util_call_compare_by_status))
return;
@@ -668,7 +677,7 @@ static void ccwa_notify(GAtResult *result, gpointer user_data)
DBG("ccwa_notify: %s %d %d %d", num, num_type, cls, validity);
- call = create_call(vc, class_to_call_type(cls), 1, 5,
+ call = create_call(vc, class_to_call_type(cls), 1, CALL_STATUS_WAITING,
num, num_type, validity);
if (call == NULL) {
ofono_error("Unable to malloc. Call management is fubar");
--
1.7.0.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 5/5] stemodem: Use defined call_status enum
2011-02-04 20:35 [PATCH 0/5] Make use of defined call_status enum Jeevaka Badrappan
` (3 preceding siblings ...)
2011-02-04 20:35 ` [PATCH 4/5] ifxmodem: " Jeevaka Badrappan
@ 2011-02-04 20:35 ` Jeevaka Badrappan
4 siblings, 0 replies; 6+ messages in thread
From: Jeevaka Badrappan @ 2011-02-04 20:35 UTC (permalink / raw)
To: ofono
[-- Attachment #1: Type: text/plain, Size: 747 bytes --]
---
drivers/stemodem/voicecall.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/drivers/stemodem/voicecall.c b/drivers/stemodem/voicecall.c
index 4a3a83d..3ca106e 100644
--- a/drivers/stemodem/voicecall.c
+++ b/drivers/stemodem/voicecall.c
@@ -356,7 +356,8 @@ static void ste_deflect(struct ofono_voicecall *vc,
ofono_voicecall_cb_t cb, void *data)
{
char buf[128];
- unsigned int incoming_or_waiting = (0x1 << 4) | (0x1 << 5);
+ unsigned int incoming_or_waiting =
+ (0x1 << CALL_STATUS_INCOMING) | (0x1 << CALL_STATUS_WAITING);
snprintf(buf, sizeof(buf), "AT+CTFR=\"%s\",%d", ph->number, ph->type);
ste_template(buf, vc, ste_generic_cb, incoming_or_waiting, cb, data);
--
1.7.0.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-02-04 20:35 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-04 20:35 [PATCH 0/5] Make use of defined call_status enum Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 1/5] atmodem: use " Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 2/5] hfpmodem: Use " Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 3/5] huaweimodem: " Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 4/5] ifxmodem: " Jeevaka Badrappan
2011-02-04 20:35 ` [PATCH 5/5] stemodem: " Jeevaka Badrappan
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.