aboutsummaryrefslogtreecommitdiffstats
path: root/src/sysmo_sock.cpp
AgeCommit message (Collapse)AuthorFilesLines
2013-10-30bts/tbf: Move the lists into the BTS and do the look-up from the BTSHolger Hans Peter Freyther1-0/+1
The list belongs to the BTS. This makes cleaning this up more easy and establishes a hierachy of resources that start from the BTS. The debug_diagram code is now broken.
2013-10-30pdch: Move enable/disable into the PDCH codeHolger Hans Peter Freyther1-1/+2
When a PDCH is disabled all resources should be freed. This is currently not possible as the PDCH does not know where it belongs to. On top of that the list (and other resources) should be properly initialized on construction so that disable() is idempotent and does not check if it was disabled. During the re-factoring I noticed that during a sysmobts re-start some resources are not freed. I left a warning in the code to resolve this issue later.
2013-10-30bts: Introduce a singleton for the BTS and use it in the codeHolger Hans Peter Freyther1-1/+1
Compared to the previous code there will be a branch to get the global pointer so the code will be slightly slower than the previous version but it allows us to start creating objects but still use the code from C. It is best approach I have found so far. One downside of C++ is that by default talloc will not be used (unless we override the new operator to use talloc. Right now we need to memset the C data structure by hand. The benefit of enforcing a better structure should is more important though.
2013-10-28tbf: Move the code to close all timeslots into the tbf classHolger Hans Peter Freyther1-10/+2
Move the code out of the sysmocom_socket (as this is only required to talk to our hardware) and into the TBF class that actually knows what a TBF is.
2013-10-28tbf: Move header definition from gprs_rlcmac to the tbfHolger Hans Peter Freyther1-0/+1
2013-07-27misc: Add an option exit/quit when the BSSGP is supposed to be destroyedHolger Hans Peter Freyther1-1/+1
The PCU does not properly re-set the state when the connection to the BTS is lost (and the SGSN potentially is re-started during that). This results in the BSSGP BVCI > 1 remaining blocked and no data will be accepted by the SGSN. Add the '-e' option and exit the PCU when the BSSGP/NS are getting destroyed.
2013-07-27misc: Remove if (timer_pending) stop_timer idiom from the codeHolger Hans Peter Freyther1-2/+1
osmo_timer_del is an idempotent operation. There is no requirement to check if it is running. If you don't want a timer to run, delete it. Maybe one should have called the method _unschedule, _cancel to make this more clear.
2013-01-25Fixed closing of PDCH when enabling sysmo-bts' direct DSP accessAndreas Eversberg1-0/+2
If not compiled with this support, the closing function does not exists, so it must not be called. Removed a "#warning", because closing is already supported.
2013-01-16Free each fl1h (sysmo-bts' layer 1 handler) when closing BTS<->PCU socketAndreas Eversberg1-0/+8
2012-09-28Fix: Cleanly open and close NS instanceAndreas Eversberg1-7/+11
2012-08-07Assign TFI to complete TRX, not just one TSAndreas Eversberg1-9/+8
This is required, since we may change slot allocation. In case of a change, we do not want to be unable to change, if the same TFI on one of the other slots is already in use by a different TBF (having same TFI, but on different slot).
2012-07-13Changed data structures for TBF and PDCH instances, to allow multislotAndreas Eversberg1-1/+4
The new data structure is required to define slot/TFI assigment for MS with multislot capability. Now there are two lists for TBFs: uplink and downlink. It is possible to have different TBFs with same TFI in the same direction, as long as they are assigned on different timeslots. See tbf.txt for description. Note: This does not implement any multislot support. It defines the new data structure. Currently only the first slot is assigned.
2012-07-13Adding signal handler to allow clean exit of PCUAndreas Eversberg1-1/+2
The signal handler will end the main loop, so clean exit is performed. The allocated memory is dumped in order to detect memory leaks. All talloc functions use tall_pcu_ctx context instead of NULL, to track memory leaks.
2012-07-12Merge branch 'jolly_new'Ivan Kluchnikov1-0/+303
Merge is based on jolly_new branch with two modifications. 1. Modified PCU L1 interface. pcu_l1_if.cpp - common functions for tx and rx messages on L1 interface. sysmo_sock.cpp - SYSMO-PCU socket functions. openbts_sock.cpp - OpenBTS-PCU socket functions. pcuif_proto.h - L1 interface's primitives. 2. Modified encoding of RLC/MAC Control messages, now we use structures and encode_gsm_rlcmac_downlink() function for encode control blocks (without hand-coding).