diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2010-06-28 17:09:29 +0800 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2010-06-28 18:01:47 +0800 |
commit | 4049455d744455dd48fa359a220822303fc3a5be (patch) | |
tree | 262a428bb44471ee7d7ddbdf89421633ba409392 /openbsc/include/openbsc/gsm_data.h | |
parent | 2412a07965ace5fc425b401438d21ff86ceeb2df (diff) |
bsc_msc: Remove use_count from the subscriber connection
A channel will be released in case of
* Errors via the clear_request callback...
* no more transactions and operations are going on.
This means that if we do something without a transaction
the channel might be closed down right away. The bug fix
will be to create a transaction/operation.
Diffstat (limited to 'openbsc/include/openbsc/gsm_data.h')
-rw-r--r-- | openbsc/include/openbsc/gsm_data.h | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/openbsc/include/openbsc/gsm_data.h b/openbsc/include/openbsc/gsm_data.h index b1091cdb2..491cca12a 100644 --- a/openbsc/include/openbsc/gsm_data.h +++ b/openbsc/include/openbsc/gsm_data.h @@ -120,26 +120,6 @@ typedef int gsm_cbfn(unsigned int hooknum, struct msgb *msg, void *data, void *param); -/* - * Use the channel. As side effect the lchannel recycle timer - * will be started. - */ -#define LCHAN_RELEASE_TIMEOUT 20, 0 -#define use_subscr_con(con) \ - do { (con)->use_count++; \ - DEBUGP(DREF, "lchan (bts=%d,trx=%d,ts=%d,ch=%d) increases usage to: %d\n", \ - (con)->lchan->ts->trx->bts->nr, (con)->lchan->ts->trx->nr, (con)->lchan->ts->nr, \ - (con)->lchan->nr, (con)->use_count); \ - bsc_schedule_timer(&(con)->release_timer, LCHAN_RELEASE_TIMEOUT); } while(0); - -#define put_subscr_con(con) \ - do { (con)->use_count--; \ - DEBUGP(DREF, "lchan (bts=%d,trx=%d,ts=%d,ch=%d) decreases usage to: %d\n", \ - (con)->lchan->ts->trx->bts->nr, (con)->lchan->ts->trx->nr, (con)->lchan->ts->nr, \ - (con)->lchan->nr, (con)->use_count); \ - } while(0); - - /* Real authentication information containing Ki */ enum gsm_auth_algo { AUTH_ALGO_NONE, @@ -239,22 +219,17 @@ struct gsm_subscriber_connection { /* To whom we are allocated at the moment */ struct gsm_subscriber *subscr; - /* Timer started to release the channel */ - struct timer_list release_timer; - /* * Operations that have a state and might be pending */ struct gsm_loc_updating_operation *loc_operation; struct gsm_security_operation *sec_operation; - /* use count. how many users use this channel */ - unsigned int use_count; - /* Are we part of a special "silent" call */ int silent_call; /* back pointers */ + int in_release; struct gsm_lchan *lchan; struct gsm_bts *bts; }; |