On Monday 01 June 2009 19:33:44 Andreas.Eversberg wrote:
This patch will fix usage counting of logical channel.
Also it adds
usage counter debugging.
The use counter is increased on loaction update request. The counter is
not decreased when location update responds (mm_rx_id_resp()), but if
subscriber is authorized, it will be decreased on
release_loc_update_req(). If lchan closes, the location update is also
released (release_loc_update_req()), also if the location update times
out.
I don't like this part. First of all when making release_loc_update_req
"public" it should be properly prefixed, but I don't think chan_alloc.c
should
know/care about gsm_04_08.c at all. Also tying the timeout of the Location
Update with the autorelease of the channel does not seem appropriate.
I would very much prefer if this logic can stay within gsm_04_08.c and we fix
the usage count issue there.
For me it looks like:
- We get a reference when creating the loc_update_request
- We start a timer
- We put the reference when destroying the loc update request...
- So we might just remove the extra put/use for the waiting for IMSI/IMEI
and fix the "leak" like this?
what do you think?
z.