Commit Graph

33 Commits

Author SHA1 Message Date
Harald Welte ea34a4e3a7 split libgb into a separate library for outside use
This also removes the dependency to osmo_sock() inside libcommon and
replaces it with osmo_sock_* from libosmocore
2012-06-16 15:14:00 +08:00
Harald Welte 67161f27d1 Allow VTY-based configuration of T3105
This timer will only be forwarded to BS11 and Ericsson Abis so far,
not to Nokia and ip.access BTS yet.
2012-06-03 16:58:18 +02:00
Harald Welte c513ded578 vty / cfg_bts_tsc: TSC range is 0..7, not 0..255 2012-05-31 10:57:40 +02:00
Holger Hans Peter Freyther 8ec4952557 bsc: Create a osmo_bsc_data and embed osmo_msc_data
We want to have multiple MSCs but we also have some data
that is only present on a per BSC basis. Right now the
MSC data is not allocated with talloc, so we have some
change in the talloc contexts.
2012-03-16 11:56:10 +01:00
Harald Welte 1fe73a19cd ARFCNs are in the range of 0..1023, not 0..1024
I'm sure I read somewhere that it actually was 0..1024, as I kept
wondering how stupid it was to use 10bit+1.  However, that source
was incorrect, as GSM TS 05.05 quite clearly states 0..1023
2012-01-29 13:24:12 +01:00
Holger Hans Peter Freyther 7173f63eed bsc: Fix "show lchan" for partially provided information
show lchan should be capable of showing all allocated lchans,
all of a given bts, a given trx, a given ts. This feature was
broken when I added the ability to show a more simple summary.

Restore the initial behavior by splitting out the for loops
for the bts/trx/ts and check if we have parsed all parameters
and then call and return the subroutine.
2012-01-15 00:02:54 +01:00
Gus Bourg 1c5dd2c9bb Add NITZ (timezone) support as part of MM INFO
The UTC offset from the operating system will be used by default to
calculate the NITZ in MM INFO.  However,  a "timezone" vty command is
added at the BTS level, allowing BTS-specific overrides, e.g. in case
BTSs are distributed accross multiple timezones.
2011-12-02 10:18:17 +01:00
Sylvain Munaut 63ef215e15 bsc_vty: Fix usage of deprecated osmo_osmo_hexdump_nospc
The typo was fixed upstream

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-11-13 23:05:48 +01:00
Sylvain Munaut c951946691 libbsc/nokia_site: Fix reset procedure and add option to skip it.
do_reset was not initialized anywhere anymore, so the reset was never
triggered. It's now fixed and we add an option to skip it in the
config so that when in production, you can restart without config
changes quickly.

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2011-10-18 21:51:02 +02:00
Holger Hans Peter Freyther 08542564fe vty: Document more VTY parameters of a command
The below is used to identify commands that need proper documentation

diff --git a/src/vty/command.c b/src/vty/command.c
index ab1eaca..bcf72d0 100644
--- a/src/vty/command.c
+++ b/src/vty/command.c
@@ -426,6 +426,20 @@ void install_element(enum node_type ntype, struct cmd_element *cmd)

        cmd->strvec = cmd_make_descvec(cmd->string, cmd->doc);
        cmd->cmdsize = cmd_cmdsize(cmd->strvec);
+
+       printf("NODE: %d\n", ntype);
+
+       int j;
+       for (j = 0; j < vector_count(cmd->strvec); ++j) {
+               vector descvec = vector_slot(cmd->strvec, j);
+               int i;
+               for (i = 0; i < vector_active(descvec); i++) {
+                       struct desc *desc = vector_slot(descvec, i);
+                       if (desc == NULL)
+                               continue;
+                       printf(" %s %s\n", desc->cmd, desc->str);
+               }
+       }
 }
2011-10-12 08:30:14 +02:00
Harald Welte f7a2b19771 Revert "we don't have openbsc/ipaccess.h anymore"
This reverts commit 8697e43bb2.
2011-08-23 16:00:22 +02:00
Harald Welte 8697e43bb2 we don't have openbsc/ipaccess.h anymore 2011-08-20 18:10:18 +02:00
Pablo Neira Ayuso ed5cacb240 src: port openBSC over libosmo-abis
This is a big patch that ports openBSC over libosmo-abis.
Sorry, the changes that are included here are all dependent
of libosmo-abis, splitting them into smaller pieces would
leave the repository in some intermediate state, which is
not desired.

The main changes are:

- The directory libabis/ has been removed as it now lives in
  libosmo-abis.

- new configuration file format for nanoBTS and HSL femto, we
  need to define the virtual e1_line and attach it to the OML
  link.

- all the existing BTS drivers (nanoBTS, hsl femto, Nokia site,
  BS11 and rbs2000) now use the new libosmo-abis framework.

- use r232 input driver available in libosmo-abis for bs11_config.

- use ipa_msg_recv instead of old ipaccess_read_msg function.

- delete definition of gsm_e1_subslot and input_signal_data.
  These structures now lives in libosmo-abis.

Most of this patch are deletions of libabis/ which has been
moved to libosmo-abis.

This patch also modifies openBSC to use all the new definitions
available in libosmocore and libosmo-abis. In order to do that,
we have replaced the following:

- DINP, DMI, DMIB and DMUX by their respective DL* correspondences.
- SS_GLOBAL by SS_L_GLOBAL
- SS_INPUT by SS_L_INPUT
- S_GLOBAL_SHUTDOWN by S_L_GLOBAL_SHUTDOWN
- SS_INPUT by SS_L_INPUT
- S_INP_* by S_L_INP_* sub-signals
- E1INP_NODE by L_E1INP_NODE vty node

This patch has been tested with:
- one nanoBTS
- the HSL femto with the examples available under libosmo-abis
- BS11 with both dahdi and misdn drivers.
2011-08-19 22:38:35 +02:00
Jan Luebbe 563d99d3c3 libbsc: Only skip lchans with state AND type set to NONE in show lchan
The function lchan_alloc only considers lchans to be available if both
the type and state are NONE. So change show lchan to list all lchans
 that are not considered available.
2011-08-11 17:21:24 +02:00
Harald Welte 986926ebde E1 Input: Move 'show e1_*' command to e1_input_vty.c 2011-08-11 12:59:54 +02:00
Dieter Spaar 402ccedcf4 BSC VTY: Accept MNC of 0-999, as 0 is a valid MNC 2011-07-27 23:43:56 +02:00
Holger Hans Peter Freyther 5e3bbba962 bsc: Call the RF Control interface ctrl all the way
We had the rf_ctrl_name and the rf_ctl pointer, make both use
the word ctrl.
2011-07-19 19:53:52 +02:00
Harald Welte 46324ccfcd bsc_vty: Fix some Smatch warnings
/home/laforge/projects/git/openbsc/openbsc/src/libbsc/bsc_vty.c +1062
show_e1ts(25) warn: variable dereferenced before check 'line'
/home/laforge/projects/git/openbsc/openbsc/src/libbsc/bsc_vty.c +1075
show_e1ts(38) warn: buffer overflow 'line->ts' 32 <= 32
2011-07-16 13:16:39 +02:00
Harald Welte 3300c01e82 split gsm_data.c in gsm_data_shared.c and gsm_data.c
This facilitates the use of gsm_data.c from osmo-bts
2011-06-05 13:31:33 +02:00
Harald Welte 135a648ad7 Introduce per-ts TSC
This allows us to configure a TSC for each timeslot, not just one globally for
the entire BTS.
2011-06-03 14:03:27 +02:00
Harald Welte d64c0bca17 gsm_data_shared: introduce 'struct gsm_abis_mo'
... as a common wrapper around nm_attr and nm_state
2011-06-03 14:03:27 +02:00
Harald Welte cdc59ff5cc abis_nm: Some more fall-out from the abis_nm move to libosmocore
we want get_string_value(), not the equivalent of get_value_string()
2011-05-23 20:42:26 +02:00
Harald Welte 867d9f3985 abis_nm: fix some fallout regarding abis_nm migration to libosmocore
Thanks to Holger for noticing this.
2011-05-23 20:30:39 +02:00
Pablo Neira Ayuso c0d17f2266 src: use namespace prefix osmo_* for misc utils
Summary of changes:

s/bcd2char/osmo_bcd2char/g
s/char2bcd/osmo_char2bcd/g
s/hexparse/osmo_hexparse/g
s/hexdump/osmo_hexdump/g
s/hexdump_nospc/osmo_hexdump_nospc/g
s/ubit_dump/osmo_ubit_dump/g
s/static_assert/osmo_static_assert/g
2011-05-07 12:58:59 +02:00
Pablo Neira Ayuso dfb342c19a src: use namespace prefix osmo_counter*
Summary of changes:

s/struct counter/struct osmo_counter/g
s/counter_inc/osmo_counter_inc/g
s/counter_get/osmo_counter_get/g
s/counter_reset/osmo_counter_reset/g
s/counter_alloc/osmo_counter_alloc/g
s/counter_free/osmo_counter_free
2011-05-06 12:14:16 +02:00
Holger Hans Peter Freyther 66e14cdda6 paging: Provide the number of pending requests
Address the FIXME and take code from the on-waves/bsc-master
branch. This will count the number of requests.
2011-05-02 19:19:15 +02:00
Holger Hans Peter Freyther a8a09df6a6 misc: Remove sys/types.h includes from the files
These are not needed any more. We used them for u_int
types but we now use uint which comes from stdint.h
2011-04-18 17:31:39 +02:00
Pablo Neira Ayuso 136f453dd2 src: use new library libosmogsm and new path to headers in libosmocore
libosmogsm is a new library that is distributed in the libosmocore.
Now, openbsc depends on it. This patch gets openbsc with this
change.

This patch also rewrites all include path to the new
osmocom/[gsm|core]

Signed-off-by: Pablo Neira Ayuso <pablo@gnumonks.org>
2011-03-23 18:17:56 +01:00
Pablo Neira Ayuso 739a566961 bsc: change bsc_vty_init to take logging categories as parameter
This change is required to finish the integration of the VTY and
the per-application logging categories that provides:

"vty: integration with logging framework"

in libosmocore.

It has been tested with osmo-nitb. The other just compiled tested.
2011-03-19 18:50:38 -03:00
Pablo Neira Ayuso 682587748f vty: fix segfault if rf_ctl is not set
This is the case of osmo-nitb, since it does not call
osmo_bsc_rf_create().

term1: $ ./osmo-nitb -c ../openbsc.cfg.nanobts
term2: $ telnet localhost 4242
term2: OpenBSC> show network
term1: Segmentation fault
2011-03-08 15:35:34 +01:00
Harald Welte c08e8be4ee fix path of bscconfig.h include file 2011-03-04 13:53:51 +01:00
Harald Welte fd355a3c6f [HSL] initial support for the HSL 2.75G Femtocell
The HSL Femtocell seems to be a poor man implementation of the
ip.access Abis/IP protocol, but cutting corners wherever possible.

We try to workaround those corners wherever possible...
2011-03-04 13:44:07 +01:00
Harald Welte 89579b4317 prefix sub-directories containing libraries with 'lib'
... and make sure tests work again after restructuring
2011-03-04 13:23:09 +01:00