openbsc.git branch neels/gtphub updated. 0.15.0-78-g1dbef68

gitosis at gitosis at
Sun Nov 29 18:15:12 UTC 2015

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The OpenBSC GSM Base Station Controller (+MSC/HLR/SGSN)".

The branch, neels/gtphub has been updated
  discards  0321c1acf9070dfb3df42c264f1a06d72dbfe3d3 (commit)
  discards  dd5eb285b67e287d7d9f9912cc80d1a17fc258b4 (commit)
  discards  794e9e0b720f20b3382ccda55789fb6feb5b7521 (commit)
  discards  346d506d0b2eebe93ae06f9b432c5f38f9f683ee (commit)
  discards  e4837989e63b7f51ae811f151ffc933c5f5c73cc (commit)
  discards  8326885067301fd8c8c566eeea346d9aff035f0a (commit)
  discards  3aa01614d1332b9a10920062b04127e5db7d7740 (commit)
  discards  a0cb29c321573d84b4e93cfc658cd4ceadbf5041 (commit)
  discards  532e9d7ceb76d1409ede36c9b304cf32a7648d40 (commit)
  discards  f321b223d4dc9ad0fc300a781945bf43cca23da4 (commit)
  discards  47eb5e2f2bcf8add821b076ed35b45e4af61672b (commit)
  discards  80524ff23caa213ce14ca7fa0df9da91ac2ffaf8 (commit)
  discards  c27f03c0d5208de86c698cf532b56c4f1692c17a (commit)
  discards  62580504d1756f506711a6e96bf063d3ce1dea31 (commit)
  discards  1fcdcc21eecf0cd56b21ac5e4f76a7f9a2ce559e (commit)
  discards  38a6177f76a1425feaec1045d9e28535abc0db21 (commit)
  discards  4c92268cbe855a9451b7acf0bff5e7c53bad2809 (commit)
  discards  4231731d4125bdcf68fc5cd99b6aee0eaa9c9b37 (commit)
  discards  3f40114e0285108d71fba3780566bd2c436ccc92 (commit)
  discards  e243b5c6b6183d911dc6a9a245e1c95a798ec280 (commit)
  discards  a63c177aa3ab50a7a00c04ac10ea282376ea4bc7 (commit)
  discards  42acf2cd2cc4ebbd2611c67aeb0744778e0ba72a (commit)
       via  1dbef680f35ff013aa4862bccb7751acdd5cacb2 (commit)
       via  637d9b1c90573106813296972fd4c622d85c93d6 (commit)
       via  ebe33de94be82c7b682e24a495a69400053b39ef (commit)
       via  6ffa456c1e7630212a072726c316d30f9365bbb9 (commit)
       via  63e0374673b41a3caaea8d61d47b56a098000d8a (commit)
       via  8bd011be830dc164ee0b7ca7f855c57efb6f5861 (commit)
       via  8310f1818058382bb9009b5e7bf7781b83c28365 (commit)
       via  711d502eaa27b788ac5f9e4c52bea27cdb584b4b (commit)
       via  28636afea50c49eb77ae62d344379df5c7be77a9 (commit)
       via  40b07b4c78b3872b467fbd54668ef371ebad0677 (commit)
       via  925f89dfa15e82d597f1d70521b74ba194b54d66 (commit)
       via  fab52ade17d26d29f06a1cf6723148e831f22cb2 (commit)
       via  6a9a4bd3d79c0c7e1041fce649419a5bf71971d2 (commit)
       via  d051d80a3564495a568b2886cdbf595cefb1d037 (commit)
       via  8fca7c67edfc26d7ab1ba3d3ca7f6ed791edfbd1 (commit)
       via  26e6151c4593c3fc57c189cf1bc51f80f257c117 (commit)
       via  9df43973ebc04507deaf1abbf0f3b517503ab5f8 (commit)
       via  c4e222a6d0cb987264d14e6ce84c316cf2653b43 (commit)
       via  5328d529b0c48d6f0011dfac25f138a88115e04a (commit)
       via  eb0ff980a75406b53d71da4ca934efe8a9017b79 (commit)
       via  cc92741e8a4439290c12417c402e4289914c03f9 (commit)
       via  6374ccc2badd96496069b36e87d3fab2fe6da9de (commit)
       via  96fad135b55cf153b32545d18604620a9f2b74b2 (commit)
       via  ff252bb80172826391b6286fd240266fe842cc83 (commit)

This update added new revisions after undoing existing revisions.  That is
to say, the old revision is not a strict subset of the new revision.  This
situation occurs when you --force push a change and generate a repository
containing something like this:

 * -- * -- B -- O -- O -- O (0321c1acf9070dfb3df42c264f1a06d72dbfe3d3)
             N -- N -- N (1dbef680f35ff013aa4862bccb7751acdd5cacb2)

When this happens we assume that you've already had alert emails for all
of the O revisions, and so we here report only the revisions in the N
branch from the common base, B.

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------

commit 1dbef680f35ff013aa4862bccb7751acdd5cacb2
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Sun Nov 29 19:14:58 2015 +0100


commit 637d9b1c90573106813296972fd4c622d85c93d6
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 27 01:22:13 2015 +0100

    gtphub: make sure mapped TEIs aren't occupied.
    discussion pending.

commit ebe33de94be82c7b682e24a495a69400053b39ef
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 27 01:20:53 2015 +0100

    gtphub: use a single TEI pool across planes.
    There's no need to keep two separate number pools when both can be fed
    from the same pool. User and Ctrl plane TEIs can technically overlap without
    colliding, but it doesn't hurt if they don't overlap, either.

commit 6ffa456c1e7630212a072726c316d30f9365bbb9
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 27 00:05:56 2015 +0100

    gtphub: cosmetic: for_each_side,_plane macros.
    Simplify looping over sides and planes. I'm tired of typing the same for
    loops all the time.

commit 63e0374673b41a3caaea8d61d47b56a098000d8a
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Thu Nov 26 22:19:22 2015 +0100

    gtphub: implement restart counter properly.
    Force passing a restart counter, by adding such arg to gtphub_start() (test
    suite is not affected by this).
    In gtphub_main.c, add -r,--restart-file <path> and next_restart_count() to
    maintain the counter file. While at it, tweak the cmdline help to unify the
    formatting (mostly commas and a missing line break).
    Send gtphub's own restart counter. So far, the sender's restart counter was
    copied through, which would break as soon as more than one GSN would talk to
    the same peer with differing restart counters.
    Also fix the in-mem restart counter data type (one octet, not two).
    Sponsored-by: On-Waves ehi

commit 8bd011be830dc164ee0b7ca7f855c57efb6f5861
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Thu Nov 26 05:20:18 2015 +0100

    gtphub: complain about excess cmdline args.

commit 8310f1818058382bb9009b5e7bf7781b83c28365
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 24 13:31:06 2015 +0100

    gtphub: track tunnels explicitly.
    So far, gtphub worked perfectly by only tracking single TEIs ... for probably
    most uses. But a Ctrl plane tunnel may have expired despite a still active
    corresponding User plane tunnel. The User plane would continue to work
    indefinitely, but if any Ctrl messages followed after more than six hours of
    Ctrl silence, they would have been dropped due to an expired TEI mapping.
    We want to
    - combine expiry of a user TEI with its ctrl TEI. (done in this patch)
    - upon delete PDP context, remove both user and ctrl TEI mappings. (future)
    - when a peer indicates a restart counter bump, invalidate its tunnels.
    To facilitate these, track tunnels, complete with both SGSN's and GGSN's
    address, original and replaced TEIs, all for both user and ctrl plane, in a
    single struct. A single expiry entry handles the entire tunnel, instead of
    previously four separate expiries for each endpoint identifier.
    Add the concept of a "side", being either GGSN or SGSN, to index tunnel
    endpoint structs, and so on.
    Track the originating side in the gtp_packet_desc.
    Add header_tei_rx: set_tei() overwrites header_tei, but the originally received
    header TEI is still needed to match a Create PDP Context Response up with its
    Request (and for logging).
    Adjust the test suite to expect tunnel listing strings instead of TEI mappings,
    with a bonus of making it a lot easier to grok, and including the IP addresses.
    Add regression test for refreshing tunnel expiry upon use.
    Note: the current implementation is as slow as can possibly be, iterating all
    the tunnels all the time. Optimizations are kept for a future commit, on
    BTW, the sequence number mapping/unmapping structures remain unchanged.
    Sponsored-by: On-Waves ehi

commit 711d502eaa27b788ac5f9e4c52bea27cdb584b4b
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Wed Nov 25 16:45:59 2015 +0100

    gtphub: cosmetic/prepare: rename expiry queues.
    The expiry queues are already used for resolved GGSN addresses, and will
    soon enlist tunnel structs. Hence the naming should be more general.

commit 28636afea50c49eb77ae62d344379df5c7be77a9
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 24 13:32:23 2015 +0100

    gtphub: add assertion to ensure expiry ordering.
    Make 100% sure the user adds expiring_items in chronological order by asserting
    that a newly added expiry is >= the last expiry in the queue. Add llist_last()
    to facilitate.
    Sponsored-by: On-Waves ehi

commit 40b07b4c78b3872b467fbd54668ef371ebad0677
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 24 13:30:38 2015 +0100

    gtphub: cosmetic/prepare: add nr_map_refresh().

commit 925f89dfa15e82d597f1d70521b74ba194b54d66
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 24 13:27:13 2015 +0100

    gtphub: move timestamp into packet struct.
    Instead of passing the current time around in function arguments ('now'),
    rather store the current time once upon decoding a GTP packet in the
    gtp_packet_desc passed around anyway ('p->timestamp').
    Sponsored-by: On-Waves ehi

commit fab52ade17d26d29f06a1cf6723148e831f22cb2
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 24 13:23:44 2015 +0100

    gtphub: cosmetic: fix an argument name.

commit 6a9a4bd3d79c0c7e1041fce649419a5bf71971d2
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 20 03:16:19 2015 +0100

    gtphub: first vty show commands.
    Start adding VTY commands to show rate counters / statistics / cache dumps.
    Sponsored-by: On-Waves ehi

commit d051d80a3564495a568b2886cdbf595cefb1d037
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 20 01:28:40 2015 +0100

    gtphub: add first rate counters
    Sponsored-by: On-Waves ehi

commit 8fca7c67edfc26d7ab1ba3d3ca7f6ed791edfbd1
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 20 01:27:22 2015 +0100

    gtphub: cosmetic: clarify bind pointer naming.
    Some gtphub_bind pointers point to an array of binds, some point directly at
    instances. Make the distinction between the two more obvious by adding an
    '_arr' suffix to the array ones.
    Partly in preparation for upcoming rate counters.
    Sponsored-by: On-Waves ehi

commit 26e6151c4593c3fc57c189cf1bc51f80f257c117
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 20 00:08:28 2015 +0100

    gtphub: add explicit cleanup handles.
    Clean up functionality is added for the test suite only, to be able to clean
    out all allocations and test against memory leaks.
    So far, it was sufficient to expire everything to free a gtphub. In preparation
    for the upcoming rate counters, which will need to be freed explicitly, add
    gtphub functions to clean up everything.
    As added bonus, also close the sockets explicitly -- not really needed upon
    program exit, neither by the test suite, but *if* we have a cleanup function,
    it should clean up everything properly.
    Closing the sockets is however kept separate, for the test suite.
    gtphub_start() and gtphub_stop() are for normal use (published in gtphub.h),
    and gtphub_init() and gtphub_free() are for the test suite, without sockets.
    (gtphub_stop() will probably never be called by anyone, but its existence
    completes the picture.)
    In gtphub_test.c, have a function to clean up the testing gtphub struct. First,
    expire everything by timeout, assert emptiness, then call the cleanup function.
    Call from each test in the end.
    Sponsored-by: On-Waves ehi

commit 9df43973ebc04507deaf1abbf0f3b517503ab5f8
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Fri Nov 20 00:04:41 2015 +0100

    gtphub: ensure cleanup of peer addresses.
    Upon calling gtphub_peer_del(), all addresses and ports should already have
    expired (by force). Make sure the code heeds that with a so far missing
    Sponsored-by: On-Waves ehi

commit c4e222a6d0cb987264d14e6ce84c316cf2653b43
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Wed Nov 18 18:11:32 2015 +0100

    gtphub: ares vty and init
    From sgsn_vty.c, copy the cfg_grx_ggsn_cmd to add an ares server to the static
    This is sort of preliminary. As described in comments, the sgsn_ares functions
    should actually be separated from the static sgsn structure. gtphub keeps such
    an sgsn structure just for the sgsn_ares functions.
    Sponsored-by: On-Waves ehi

commit 5328d529b0c48d6f0011dfac25f138a88115e04a
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Wed Nov 18 18:11:09 2015 +0100

    gtphub: review some logging.
    Sponsored-by: On-Waves ehi

commit eb0ff980a75406b53d71da4ca934efe8a9017b79
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Wed Nov 18 17:53:00 2015 +0100

    gtphub: cosmetic: rename a file.
    gtphub_ext.c's initial purpose was to wrap a specific function. The file
    then turned into everything related to DNS, which fits pretty well. Rename
    to gtphub_ares.c.
    Tweak the header comment to reflect the new file name.
    Sponsored-by: On-Waves ehi

commit cc92741e8a4439290c12417c402e4289914c03f9
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 17 14:30:37 2015 +0100

    gtphub: nr_map: add min,max and wrap.
    Implement min/max bounds for nr_pool, adjust nr_pool_init() and current tests,
    and create unit tests for nr_map wrapping.
    Sequence numbers range from 0 to 65535, while TEIs range from 1 to 0xffffffff.
    Both cause problems when the nr_pool surpasses the range: seq exit their valid
    range, causing unmappings to fail, and a TEI would be mapped as zero (invalid).
    Add a comment about TEI wrapping, and lose the comment about random TEIs (not
    really important).
    Sponsored-by: On-Waves ehi

commit 6374ccc2badd96496069b36e87d3fab2fe6da9de
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Tue Nov 17 14:24:46 2015 +0100

    gtphub: fix number map range for TEIs.
    Use unsigned int for nr_map, just large enough to fit the TEI space.
    Adjust log output formats and casts accordingly.
    Fixes: TEIs are uint32_t, but the nr_map so far used int. This would cause TEIs
    from 0x80000000 on to be handled and printed as a negative value.
    Sponsored-by: On-Waves ehi

commit 96fad135b55cf153b32545d18604620a9f2b74b2
Author: Neels Hofmeyr <nhofmeyr at>
Date:   Wed Nov 18 17:09:22 2015 +0100

    gtphub: add to debian build
    By the example of osmo-sgsn, package osmo-gtphub for debian.
    Sponsored-by: On-Waves ehi


Summary of changes:
 openbsc/             | 6 ++++++
 openbsc/tests/         | 5 +++--
 openbsc/tests/gtphub/ | 4 ++++
 3 files changed, 13 insertions(+), 2 deletions(-)

The OpenBSC GSM Base Station Controller (+MSC/HLR/SGSN)

More information about the osmocom-commitlog mailing list