diff options
author | Patrick McHardy <kaber@trash.net> | 2011-02-24 21:47:07 +0100 |
---|---|---|
committer | Patrick McHardy <kaber@trash.net> | 2011-02-24 21:47:07 +0100 |
commit | f5b3fafa479707eab35fe76f59ec1d5873264a00 (patch) | |
tree | 735680004cc37a112795fb945210be869a016321 | |
parent | 3b1c1f5e44814c252c127c12b1bc02dcf554ecbc (diff) |
cc: convert -res primitives to return void
There is no reasonable way for the caller to respond to an error returned
by a -res primitive, the initiator is responsible for resending the
request. Change all CC -res primitives to return void.
Signed-off-by: Patrick McHardy <kaber@trash.net>
-rw-r--r-- | include/dect/cc.h | 20 | ||||
-rw-r--r-- | src/cc.c | 28 |
2 files changed, 21 insertions, 27 deletions
diff --git a/include/dect/cc.h b/include/dect/cc.h index 4f114ec..ffa25ab 100644 --- a/include/dect/cc.h +++ b/include/dect/cc.h @@ -298,28 +298,28 @@ extern int dect_mncc_alert_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_alert_param *param); extern int dect_mncc_connect_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_connect_param *param); -extern int dect_mncc_connect_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_connect_param *param); +extern void dect_mncc_connect_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_connect_param *param); extern int dect_mncc_release_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_release_param *param); -extern int dect_mncc_release_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_release_param *param); +extern void dect_mncc_release_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_release_param *param); extern int dect_mncc_facility_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_facility_param *param); extern int dect_mncc_info_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_info_param *param); extern int dect_mncc_modify_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_modify_param *param); -extern int dect_mncc_modify_res(struct dect_handle *dh, struct dect_call *call, - bool success, const struct dect_mncc_modify_param *param); +extern void dect_mncc_modify_res(struct dect_handle *dh, struct dect_call *call, + bool success, const struct dect_mncc_modify_param *param); extern int dect_mncc_hold_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_hold_param *param); -extern int dect_mncc_hold_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_hold_param *param); +extern void dect_mncc_hold_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_hold_param *param); extern int dect_mncc_retrieve_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_hold_param *param); -extern int dect_mncc_retrieve_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_hold_param *param); +extern void dect_mncc_retrieve_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_hold_param *param); extern int dect_mncc_iwu_info_req(struct dect_handle *dh, struct dect_call *call, const struct dect_mncc_iwu_info_param *param); @@ -1043,8 +1043,8 @@ EXPORT_SYMBOL(dect_mncc_connect_req); * @param call Call Control Endpoint * @param param call connection parameters */ -int dect_mncc_connect_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_connect_param *param) +void dect_mncc_connect_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_connect_param *param) { struct dect_cc_connect_ack_msg msg = { .display = param->display, @@ -1061,12 +1061,10 @@ int dect_mncc_connect_res(struct dect_handle *dh, struct dect_call *call, goto err1; call->state = DECT_CC_ACTIVE; - - return 0; + return; err1: dect_call_disconnect_uplane(dh, call); - return -1; } EXPORT_SYMBOL(dect_mncc_connect_res); @@ -1111,8 +1109,8 @@ EXPORT_SYMBOL(dect_mncc_release_req); * @param call Call Control Endpoint * @param param call release parameters */ -int dect_mncc_release_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_release_param *param) +void dect_mncc_release_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_release_param *param) { struct dect_cc_release_com_msg msg = { .release_reason = param->release_reason, @@ -1134,7 +1132,6 @@ int dect_mncc_release_res(struct dect_handle *dh, struct dect_call *call, dect_cc_stop_timers(dh, call); dect_call_shutdown(dh, call); - return 0; } EXPORT_SYMBOL(dect_mncc_release_res); @@ -1218,11 +1215,10 @@ EXPORT_SYMBOL(dect_mncc_modify_req); * @param success success/failure of service modification * @param param call modification parameters */ -int dect_mncc_modify_res(struct dect_handle *dh, struct dect_call *call, - bool success, const struct dect_mncc_modify_param *param) +void dect_mncc_modify_res(struct dect_handle *dh, struct dect_call *call, + bool success, const struct dect_mncc_modify_param *param) { cc_debug_entry(call, "MNCC_MODIFY-res: success: %u", success); - return 0; } EXPORT_SYMBOL(dect_mncc_modify_res); @@ -1254,11 +1250,10 @@ EXPORT_SYMBOL(dect_mncc_hold_req); * @param call Call Control Endpoint * @param param call hold parameters */ -int dect_mncc_hold_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_hold_param *param) +void dect_mncc_hold_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_hold_param *param) { cc_debug_entry(call, "MNCC_HOLD-res"); - return 0; } EXPORT_SYMBOL(dect_mncc_hold_res); @@ -1284,11 +1279,10 @@ EXPORT_SYMBOL(dect_mncc_retrieve_req); * @param call Call Control Endpoint * @param param call retrieve parameters */ -int dect_mncc_retrieve_res(struct dect_handle *dh, struct dect_call *call, - const struct dect_mncc_hold_param *param) +void dect_mncc_retrieve_res(struct dect_handle *dh, struct dect_call *call, + const struct dect_mncc_hold_param *param) { cc_debug_entry(call, "MNCC_RETRIEVE-res"); - return 0; } EXPORT_SYMBOL(dect_mncc_retrieve_res); |