All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Loading...
Searching...
No Matches

Context buffer definitions. More...

Detailed Description

Context buffer definitions.

Author
Martine Lenders mlend.nosp@m.ers@.nosp@m.inf.f.nosp@m.u-be.nosp@m.rlin..nosp@m.de

Definition in file ctx.h.

#include <inttypes.h>
#include <stdbool.h>
#include "net/ipv6/addr.h"
#include "timex.h"
#include "modules.h"
+ Include dependency graph for ctx.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  gnrc_sixlowpan_ctx_t
 Entry in the 6LoWPAN context buffer. More...
 

Macros

#define GNRC_SIXLOWPAN_CTX_SIZE   (16)
 maximum number of entries in context buffer
 

Functions

gnrc_sixlowpan_ctx_tgnrc_sixlowpan_ctx_lookup_addr (const ipv6_addr_t *addr)
 Gets a context matching the given IPv6 address best with its prefix.
 
gnrc_sixlowpan_ctx_tgnrc_sixlowpan_ctx_lookup_id (uint8_t id)
 Gets context by ID.
 
gnrc_sixlowpan_ctx_tgnrc_sixlowpan_ctx_update (uint8_t id, const ipv6_addr_t *prefix, uint8_t prefix_len, uint16_t ltime, bool comp)
 Updates (or adds if currently not registered) a context.
 
static void gnrc_sixlowpan_ctx_remove (uint8_t id)
 Removes context.
 
static bool gnrc_sixlowpan_ctx_match (const gnrc_sixlowpan_ctx_t *ctx, const ipv6_addr_t *prefix, uint8_t prefix_len)
 Check if a prefix matches a compression context.
 
static bool gnrc_sixlowpan_ctx_update_6ctx (const ipv6_addr_t *prefix, uint8_t prefix_len, uint32_t valid)
 Create or update a compression context.
 
void gnrc_sixlowpan_ctx_reset (void)
 Resets the whole context buffer.
 

Context flags.

Flags to set in gnrc_sixlowpan_ctx_t::flags_id.

#define GNRC_SIXLOWPAN_CTX_FLAGS_CID_MASK   (0x0f)
 mask for the Context ID.
 
#define GNRC_SIXLOWPAN_CTX_FLAGS_COMP   (0x10)
 Use context for compression.