summaryrefslogtreecommitdiffstats
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2012-11-05GSM48: Avoid unaligned access in gsm48_construct_raAndreas Eversberg1-1/+3
This avoids an unaligned access on platforms that don't support them, such as ARMv4/ARMv5.
2012-10-27Do not use --version-script linker flag on OSXTobias Engel2-2/+2
Add a check to not use --version-script linker flag if compiled on OSX since it doesn't exist there
2012-10-27Define struct iphdr for OSXTobias Engel1-1/+1
Use FreeBSD struct iphdr definition for OSX also. From the commentary in the source file: On BSD the IPv4 struct is called struct ip and instead of iXX the members are called ip_XX. One could change this code to use struct ip but that would require to define _BSD_SOURCE and that might have other complications. Instead make sure struct iphdr is present on FreeBSD.
2012-10-22logging: Make sure to install standard "end" command in VTY nodeHarald Welte1-0/+2
When you are in the config-log VTY node, you expect "end" to work like in any other sub-node of config.
2012-10-22logging: Don't forget to save "logging filter all 1"Harald Welte1-0/+4
Prior to this fix, a persistent file or syslog log configuration didn't work across an application re-start, as the "logging filter all 1" was never saved and thus no messages were logged.
2012-09-30Doc: Adding new parameter descriptions in gprs_bssgp_bss.cAndreas Eversberg1-1/+9
2012-09-30Fix: Correcting bssgp_tx_fc_bvc, bssgp_tx_fc_ms, bssgp_tx_ul_udAndreas Eversberg2-9/+28
2012-09-29Fix: gprs_ns_destroy() now frees all NSVCs and its timersAndreas Eversberg1-4/+14
Freeing memory of registered timers and file descriptors cause corrupt lists.
2012-09-27logging.c: Do not crash on empty category nameNico Golde1-5/+7
log_parse_category_mask(), skip log category name right away if name is NULL to prevent passing a NULL ptr to strlen.
2012-09-21gsm_utils.c: in 7bit decoding, first check if the last character was an ↵Nico Golde1-5/+5
extension character before doing anything else
2012-09-20gsm_utils: Fix up coding style in previous patchHarald Welte1-2/+2
'if' is not a function, so we have space before parenthesis.
2012-09-20gsm_utils.c: cleanup + do not use dynamic memory when decoding 7bit messagesNico Golde1-14/+13
2012-09-11logging: Introduce a print_filename flag for the logtargetHolger Hans Peter Freyther1-5/+17
Introduce a print_filename attribute for each logtarget. Initialize it with 1 to be backward compatible with earlier versions. The bit is taken from an existint bitfield. There were at least six bits left of the byte.
2012-09-11vty: Address compiler warning about the const qualifierHolger Hans Peter Freyther1-1/+1
vty.c: In function 'vty_out_newline': vty.c:294:12: warning: initialization discards 'const' qualifier from pointer target type [enabled by default]
2012-09-11vty: Address compiler warning about tolowerHolger Hans Peter Freyther1-0/+1
Include ctype.h to have a declaration of tolower. utils.c: In function 'vty_cmd_string_from_valstr': utils.c:95:6: warning: implicit declaration of function 'tolower' [-Wimplicit-function-declaration]
2012-09-11gsm: Address compiler warning about unused variable 'z'Holger Hans Peter Freyther1-3/+4
The comment explains why we don't care about the content of z, stop storing it. gsm_utils.c: In function 'gsm_7bit_encode': gsm_utils.c:253:13: warning: variable 'z' set but not used [-Wunused-but-set-variable]
2012-09-11logging: Mark the log_info_cat pointer as constsHolger Hans Peter Freyther1-2/+3
Applications should keep the log area in a static const area. Mark the pointer as const to address compiler warnings in OpenBSC, cast the const away for the osmo_log_info as it is not declared as const.
2012-09-10Gb: Add functions for sending flow control messages from BSS sideHarald Welte1-0/+105
2012-09-10Gb: Add header file for BSS-side BSSGP functionsHarald Welte1-0/+1
.. not sure how we could have missed that so far.
2012-09-08libosmogb: make build conditional, disable in embedded buildHarald Welte1-0/+2
when we build for osmocom-bb cross-compilation, we don't have sockets nor netinet/in.h and thus NS/BSSGP make no sense...
2012-09-08backtrace: don't use fprintf, but printf (for osmocom-bb)Harald Welte1-1/+1
2012-09-07BSSGP: print per-bvc flow control parameters on vtyHarald Welte1-1/+12
2012-09-07BSSGP: make bvc_ctx->fc a dynamic talloc allocationHarald Welte1-5/+7
this ensures that we can talloc the flow-control queue entries as siblings off the bvc_ctx.
2012-09-07BSSGP flow-control: various fixesHarald Welte2-10/+36
* add more comments on units of struct members * make sure to parsre FC-BVC message correctly * add error message in case user passes PDU larger than bucket size * add new function to initialize flow control struct
2012-09-07libosmogb: Port BSSGP flow control from openbsc/laforge/bssgp_fc branchHarald Welte2-4/+225
This code is supposed to implement the BSSGP flow control algorithm, both for the per-BSS and for the per-MS flow control. The code currently has no test cases, they will come in a separate commit.
2012-09-07BSSGP: fix unused variable compiler warningsHarald Welte1-8/+2
2012-09-07libosmogb: build without strict aliasing rulesHarald Welte1-1/+1
This allows us to reliably do the trick with casting structures like libgb_msgb_cb to the msgb->cb[] array. Shamelessly stolen from the Linux kernel.
2012-08-29libosmogsm: Back-port SMS related fixes from openbscHarald Welte1-1/+10
This was fixed in 9c3dc90d16a40789081c84e46620f4d66689fec1 of openbsc.git, after the sms code had been migrated here: introduce HAVE_TM_GMTOFF_IN_TM Not all architectures have the tm.tm_gmtoff member. This fixes cygwin builds.
2012-08-24GSM 04.08: Add support for parsing CSD related bearer capabilitiesHarald Welte1-5/+90
Also adds a test case for both encoder and decoder of this IE
2012-08-24gsm48_ie: annotate functions with chapter numbers from 04.08 specHarald Welte1-29/+29
2012-08-20import vty_cmd_string_from_valstr() from osmo-btsHarald Welte1-0/+54
This function is able to generate a VTY help string based on an array of 'struct value_string'.
2012-08-03increaes libosmocgsm LIBVERSIN due to gsm_decode_lai() changeHarald Welte1-1/+1
2012-08-03serial: don't set O_NDELAY, as it is more or less O_NONBLOCKHarald Welte1-1/+1
Applications like osmocon will set O_NONBLOCK themselves or have it done indirectly by registering it with libosmocore/select.c code.
2012-08-03gb: Make suspend_ref a plain uint8_t instead of a uint8_t*Holger Hans Peter Freyther1-1/+1
The OpenSUSE build is not happy about the uint8_t to uint8_t* assignment. As the suspend_ref is a mandatory field we can make it a plain uint8_t. Increase the LIBVERSION as the ABI has changed.
2012-08-02libgb: Link to the libraries used by libgbHolger Hans Peter Freyther1-1/+4
The Mandriva linker appears to be more strict in enforcing the as-needed rules. Link to the libraries that are used by libgb.
2012-08-02vty: Print the string using "%s", string to avoid security issuesHolger Hans Peter Freyther1-1/+1
The Mandriva GCC is more strict about handling format strings, the copyright string might contain escape sequences and then any memory could be read.
2012-07-25vty: Document the .TEXT of the descriptionHolger Hans Peter Freyther1-1/+2
2012-07-25vty: Add xsd and a command that can generate the documentation.Holger Hans Peter Freyther1-0/+148
When building the doxygen documentation do not remove the other VTY documentation files in the doc/vty folder. Create a command that can be installed to dump all nodes and commands as XML on the given VTY. Create a schema for the XML file and a XSL-T script that can merge the generated file with additional information.
2012-07-21Fix encoding of BSSGP_IE_NUM_OCT_AFF in bssgp_tx_llc_discarded()Andreas Eversberg1-1/+1
This is a 24bit integer value, and thus we need to encode the three least significant octets of the network-byte-order 32bit value, not the three most significant octets.
2012-07-18authentication: More documentationHarald Welte1-3/+54
2012-07-14backtrace: update copyright noticeHarald Welte1-3/+1
Holger wrote that function and I made the logging version of it. The header was copied during the separation of backtrace.c from gsm_utils.c in the past, and of course gsm_utils.c had more people involved...
2012-07-14backtrace: Add a variant that uses the libosmocore logging frameworkHarald Welte1-9/+37
I recently discovered that we can only print backtraces to stdout, which is of course useless in a daemon environment. We'd rather want to use the libosmocore logging framework instead.
2012-07-14TLV: add new "vTvLV" type for GANHarald Welte2-1/+22
This new TLV type is specific to TS 44.318. Contrary to the TvLV type of TS 08.16/08.18, it has an inverted meaning of the extension (0x80) bit: * if the extension bit is not set, 1-byte length * if the extension bit is set, 2-byte length Futhermore, it has support for variable-length tags, where the tag part can be optionally two bytes in length. As this esoteric option hasn't been seen in the wild yet, we only add encoding support but skip decoding for now.
2012-07-13gsm48_decode_lai(): return real integers for mcc/mnc, not hex!Harald Welte1-6/+13
This is to make it orthogonal with gsm48_encode_lai()
2012-07-13add gsm48_decode_lai() to map fileHarald Welte1-0/+1
2012-07-13import gsm48_decode_lai() function from osmocom-bb/mobile sysinfo.cHarald Welte1-0/+14
2012-07-13timer: Add function osmo_timer_remaining() to determine remainign timeHarald Welte1-0/+28
2012-07-12freebsd: Make libgb compile on FreeBSDHolger Hans Peter Freyther2-0/+38
Include header files for recfrom/AF_INET and include a struct ip_hdr as it is not available on *BSD.
2012-07-12logging: Fix compile breakage introduced by the warning fixesHolger Hans Peter Freyther1-4/+4
Make sure the declaration and definition match, add const to the functions called by logp/logp2. Compile output: logging.c:317: error: conflicting types for 'logp' ../include/osmocom/core/logging.h:34: note: previous declaration of 'logp' was here logging.c:327: error: conflicting types for 'logp2' ../include/osmocom/core/logging.h:168: note: previous declaration of 'logp2' was here make[3]: *** [logging.lo] Error 1
2012-07-11correct inverted logic from commit f3ba8aAlexander Huemer1-1/+1