aboutsummaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2012-05-31add /var/lock/bts_rf_lock and /var/run/osmo-bts.pid for rf controlHarald Welte1-1/+31
an external application can create /var/lock/bts_rf_lock and then kill the pid in /var/run/osmo-bts.pid in order to shut down the BTS. Any re-spawning scripts will trigger, but osmo-bts will refuse to start up until /var/lock/bts_rf_lock is removed again.
2012-05-31sysmobts: fix double-free if msgq cannot be openedHarald Welte1-4/+3
2012-05-13sysmobts l1: make sure to read messages of arbitrary sizeHarald Welte1-1/+7
... and warn if the size is not what we expect. This is required to work with sysmobts-v2 firmware >= v2.1, as the SuperFemto_Prim_t is now larger than the GsmL1_Prim_t.
2012-05-13Adapt to L1 firmware/API version 2.1Harald Welte3-23/+13
2012-05-12sysmobts: Document the values of the clock-source in the vty commandHolger Hans Peter Freyther1-1/+5
We need to have a documentation for each possible value, add some simple ones for the available clock sources.
2012-05-12sysmobts: Save the clock-source to the config fileHolger Hans Peter Freyther2-4/+8
Make the clock names lower case to match with the vty command.
2012-05-12sysmobts: Add Network Listen as clock source for the btsHolger Hans Peter Freyther1-0/+1
2012-04-28sysmo-bts: Use HW_SYSMOBTS_V1 to select the development hardwareHolger Hans Peter Freyther4-8/+8
2012-04-28sysmo-bts: Move the payload setting into a new methodHolger Hans Peter Freyther1-21/+14
Make this code a bit easier to read by moving the payload setting into a new method.
2012-04-27RSL / SI: Make sure to have correct LAPDm header in SI5/SI6 on SACCHHarald Welte1-2/+2
SI5/SI6 and other messages on SACCH need the C/R and the EA bit set in the LAPDm header. Most devices accept a broken header, but especially the Wavecom Q2686 responds with tons of RR STATUS messages if there is any invalid bit.
2012-04-26fix the idle filling to comply with 04.06 5.4.2.3 (UI frame 0 byte len)Harald Welte1-1/+1
We used to send some crap before, which most phones happily accepted but some (particularly the Wavecom Q2686) didn't really like at all.
2012-04-20lchan: I forgot to handle TchH in my recent lchan fixes, add it to another placeHolger Hans Peter Freyther1-0/+1
Harald fixed the issue for the activation by adding TchH, but this needs to be added for de-activation as well.
2012-04-19sach_deact -> sacch_deact (follow spelling fix in openbsc)Harald Welte1-3/+3
2012-04-19add vty-configurable loopback modeHarald Welte3-1/+83
this allows the BTS to loop-back any incoming data on a TCH
2012-04-19Fix TCH/H channel activation after zecke's recent lchan fixesHarald Welte1-0/+1
2012-04-19add VTY command to manually alter transmit powerHarald Welte3-1/+34
this allows for quick manual tx power changes from the VTY, particularly useful in type approval or other measurements.
2012-04-19l1_if: allow for l1prim or sysprim without a completion callbackHarald Welte1-2/+8
2012-04-19fix VTY help strings related to TRXHarald Welte1-7/+8
2012-04-19add a VTY command for activating PDCH channels (in EGPRS mode)Harald Welte6-1/+101
This allows us to do RF measurements (EDGE EVM and the like) even without having any PCU/RLC/MAC code as of now. To use it, configure PDCH type timeslots (e.g. TS 7) in the BSC and then use "trx 0 7 activate 0" to manually activate the PDTCH lchan on top of that timeslot. The BTS will now happily transmit EDGE/8PSK data.
2012-04-19delete dead codeHarald Welte1-220/+0
2012-04-19ciphering: Make sure to initialize lchan to no ciphering when activatingHarald Welte2-8/+13
The ciphering parameters in L1 are persistent accross MPH deactivate/activate, so we need to make sure to always initialize them cleanly at RSL CHAN ACT time. This has the added benefit that we can also activate channels that have encryption enabled from the very beginning (required for encrypted handover).
2012-04-19Improve logging of L1 MPH request by printing the directionHarald Welte3-6/+26
where previously we would only see <0006> oml.c:931 (bts=0,trx=0,ts=1,ss=0) MPH-DEACTIVATE.req (FACCH/F) we now get <0006> oml.c:931 (bts=0,trx=0,ts=1,ss=0) MPH-DEACTIVATE.req (FACCH/F RxUL) to notice it is modifying the receive path in the uplink direction.
2012-04-19lchan: Refuse to activate a non-idle lchan.Holger Hans Peter Freyther1-0/+7
2012-04-19lchan: Send the ACT ACK/NACK after the Layer1 has handled act/deactHolger Hans Peter Freyther2-17/+24
Send the RSL ACT ACK/NACK after the Layer1 firmware has acked the activation/deactivation. In case the channel can not be activated we will send a NACK. In case the channel can not be deactivated we will send an ACK and the next time the channel is activated we will send a NACK. The release ack will be sent once the TxDownlink of the TCH/SDCCH is closed. Change the rsl_tx_chan_nack method to create a new msgb to be used by the hardware layer, change the return value to ask the caller to delete the msgb.
2012-04-19lchan: Separate the Uplink/Downlink in activate/deactivateHolger Hans Peter Freyther1-8/+16
2012-04-19lchan: Deactivate the SACCH only once, use the sach_deact flag for thatHolger Hans Peter Freyther1-2/+14
Use the deact_sach (renamed to deact_sacch in master) to remember if the SACCH has been disabled. This should fix the case of lchan errors due releasing the lchan twice.
2012-04-19lchan: rsl_tx_chan_nack will re-use the msgb, do not msgb_freeHolger Hans Peter Freyther1-4/+4
Do not msgb_free the msg as it will be re-used inside the nack method and return 1 so the caller does not free the msgb. This ownership model needs some consideration but the usage of ref counts will not yield good results.
2012-04-19lchan: Fix crashes when the specified lchan can not be foundHolger Hans Peter Freyther1-4/+20
gsm_lchan_name will crash if the lchan is NULL. Introduce an error_report method that will do the right thing in the future and report the error.
2012-04-19lchan: Fix the state transition in the deactivate handlerHolger Hans Peter Freyther1-3/+3
If the deactivation is failing the channel needs to be moved into and error state, if the deactivation completed the channel needs to be set to the none state and set the state to release reqeust on the deactivation.
2012-04-19lchan: Similar to OpenBSC use a set method to change the stateHolger Hans Peter Freyther3-7/+34
By making all modifications through lchan_set_state we can easily add code to verify the state transition.
2012-04-19sysmobts: Add an option to query the hardware version.Holger Hans Peter Freyther1-1/+16
2012-04-19common: Add the copyright text to the vty_app_infoHolger Hans Peter Freyther2-7/+7
This will make app -V print the copyright information like the other applications of our universe. An BTS integration that want to list additionaly copyright holders needs to access the vty_app_info and create a new copyright string.
2012-04-19ciphering: Better state tracking and HACK around L1 race conditionHarald Welte3-14/+39
We now check if the received message is an LAPDm I frame in order to determine if we have received the first valid encrypted message on the radio link. This relates to the fact that we often see 'old' UI frames coming up from L1, even after it has confirmed decryption has been enabled.
2012-04-19Support for cipheringHarald Welte2-5/+88
When the RR CIPH MODE CMD is transmitted to the MS, we need to tell the L1 to enable decryption on RX. After the first received frame has been decrypted successfully, we will enable encryption also on transmit. This has been tested with A5/1 so far, but A5/2 and A5/3 should work exactly identical.
2012-04-19make HR channels work for voice, not only signallingHarald Welte1-1/+4
without this, we would set a FR_V1 codec on a TCH/H channel, which the L1 is obviously not happy with.
2012-04-18TCH: Add support for the L1 RTP modeHarald Welte3-14/+81
In L1 RTP mode, the L1 already does all the bit-shifting and re-ordering required for the RTP formats (which have different bit/nibble order than the ETSI/3GPP encodings, for some odd reason). We don't enable it by default yet, as only HR/FR/EFR work with it, but AMR has some yet to be debugged problem. Enabling USE_L1_RTP_MODE would save some CPU cycles on the ARM side.
2012-04-14femtobts: The separate pdch/tch queues are not available in the old firmwareHolger Hans Peter Freyther3-1/+13
The old firmware does not expose separate queues for PDCH and TCH. The change appears to be too intrusive and I will try to find a more elegant solution.
2012-04-14sysmobts: Handle options before allocating the btsHolger Hans Peter Freyther1-2/+3
This way -h/--version will always work, even when the underlying hardware is not available.
2012-04-14misc: Use sizeof(uint32_t) instead of simply using 32 bitHolger Hans Peter Freyther1-1/+1
This code would break in case we shrink the bitmap, use sizeof instead.
2012-04-14femtobts: Use HW_FEMTOBTS instead of HW_VERSION_1 to select femtobtsHolger Hans Peter Freyther2-3/+3
Our header files use HW_FEMTOBTS guards to select the older femtobts design. Use the same macro in the bts code.
2012-04-12misc: Address a compiler warning and add an assert to a branchHolger Hans Peter Freyther1-0/+7
The compiler can not know that the "int priv_nr" will hold the enum values of the write queue, add a default branch and add a warning and an assert there. l1_transp_hw.c:108:1: warning: control reaches end of non-void function [-Wreturn-type]
2012-04-12misc: Fix compiler warning about printing a ptrdiffHolger Hans Peter Freyther1-1/+1
Use 't' modifier for pointer diff in the printf statement. oml.c: In function ‘oml_rx_set_bts_attr’: oml.c:403:3: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 9 has type ‘int’ [-Wformat]
2012-04-12misc: Fix compiler warning of the femtobts_clksrc_namesHolger Hans Peter Freyther1-1/+1
femtobts.c:249:2: warning: excess elements in array initializer [enabled by default] femtobts.c:249:2: warning: (near initialization for ‘femtobts_clksrc_names’) [enabled by default]
2012-04-05oml: temporary debug hackHarald Welte1-1/+6
2012-04-05Increase head-room in IPA messages receivedHarald Welte1-1/+1
Without that headroom, I ran into an abort due to insufficient headroom in the LAPDm code.
2012-04-05osmo-bts-sysmo: Add gsmtap for uplinkHarald Welte1-0/+30
2012-03-18set the default log mask for the L1 a bit more reasonableHarald Welte1-1/+1
2012-03-18osmo-bts-sysmo: Add GSMTAP support for transmit (DL) pathHarald Welte3-0/+104
there are VTY commands that can be used to filter which particular L1 sapis (channel types) should be sent in GSMTAP.
2012-03-18correctly print SAPI in log file on MPH-ACTIVATE.reqHarald Welte1-1/+1
2012-03-18Fix debug print of MPH-CONFIG.reqHarald Welte1-1/+1