Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros
bearer.h File Reference
#include "bcast.h"

Go to the source code of this file.

Data Structures

struct  tipc_media_addr
 
struct  tipc_media
 
struct  tipc_bearer
 
struct  tipc_bearer_names
 

Macros

#define MAX_BEARERS   2
 
#define MAX_MEDIA   2
 
#define TIPC_MEDIA_ADDR_SIZE   20
 
#define TIPC_MEDIA_TYPE_OFFSET   3
 
#define TIPC_MEDIA_TYPE_ETH   1
 

: bearer name (format = media:interface)

struct tipc_bearer - TIPC bearer structure : pointer to additional media-specific information about bearer : max packet size bearer can support : non-zero if bearer is blocked : spinlock for controlling access to bearer : media-specific address associated with bearer

: ptr to media structure associated with bearer : default link priority for bearer : default window size for bearer : default link tolerance for bearer : array index of this bearer within TIPC bearer array : ptr to (optional) structure making periodic link setup requests : list of non-congested links associated with bearer : list of congested links associated with bearer : non-zero if bearer structure is represents a bearer : network plane ('A' through 'H') currently associated with bearer : indicates which nodes in cluster can be reached through bearer

Note: media-specific code is responsible for initialization of the fields indicated below when a bearer is enabled; TIPC's generic bearer code takes care of initializing all other fields.

struct tipc_bearer tipc_bearers []
 
int tipc_register_media (struct tipc_media *m_ptr)
 
void tipc_recv_msg (struct sk_buff *buf, struct tipc_bearer *tb_ptr)
 
int tipc_block_bearer (const char *name)
 
void tipc_continue (struct tipc_bearer *tb_ptr)
 
int tipc_enable_bearer (const char *bearer_name, u32 disc_domain, u32 priority)
 
int tipc_disable_bearer (const char *name)
 
int tipc_eth_media_start (void)
 
void tipc_eth_media_stop (void)
 
int tipc_media_set_priority (const char *name, u32 new_value)
 
int tipc_media_set_window (const char *name, u32 new_value)
 
void tipc_media_addr_printf (char *buf, int len, struct tipc_media_addr *a)
 
struct sk_bufftipc_media_get_names (void)
 
struct sk_bufftipc_bearer_get_names (void)
 
void tipc_bearer_add_dest (struct tipc_bearer *b_ptr, u32 dest)
 
void tipc_bearer_remove_dest (struct tipc_bearer *b_ptr, u32 dest)
 
void tipc_bearer_schedule (struct tipc_bearer *b_ptr, struct tipc_link *l_ptr)
 
struct tipc_bearertipc_bearer_find (const char *name)
 
struct tipc_bearertipc_bearer_find_interface (const char *if_name)
 
struct tipc_mediatipc_media_find (const char *name)
 
int tipc_bearer_resolve_congestion (struct tipc_bearer *b_ptr, struct tipc_link *l_ptr)
 
int tipc_bearer_congested (struct tipc_bearer *b_ptr, struct tipc_link *l_ptr)
 
void tipc_bearer_stop (void)
 
void tipc_bearer_lock_push (struct tipc_bearer *b_ptr)
 

Macro Definition Documentation

#define MAX_BEARERS   2

Definition at line 42 of file bearer.h.

#define MAX_MEDIA   2

Definition at line 43 of file bearer.h.

#define TIPC_MEDIA_ADDR_SIZE   20

Definition at line 52 of file bearer.h.

#define TIPC_MEDIA_TYPE_ETH   1

Definition at line 58 of file bearer.h.

#define TIPC_MEDIA_TYPE_OFFSET   3

Definition at line 53 of file bearer.h.

Function Documentation

void tipc_bearer_add_dest ( struct tipc_bearer b_ptr,
u32  dest 
)

Definition at line 267 of file bearer.c.

int tipc_bearer_congested ( struct tipc_bearer b_ptr,
struct tipc_link l_ptr 
)

tipc_bearer_congested - determines if bearer is currently congested

Definition at line 382 of file bearer.c.

struct tipc_bearer* tipc_bearer_find ( const char name)
read

tipc_bearer_find - locates bearer object with matching bearer name

Definition at line 208 of file bearer.c.

struct tipc_bearer* tipc_bearer_find_interface ( const char if_name)
read

tipc_bearer_find_interface - locates bearer object with matching interface name

Definition at line 223 of file bearer.c.

struct sk_buff* tipc_bearer_get_names ( void  )
read

tipc_bearer_get_names - record names of bearers in buffer

Definition at line 242 of file bearer.c.

void tipc_bearer_lock_push ( struct tipc_bearer b_ptr)

Definition at line 309 of file bearer.c.

void tipc_bearer_remove_dest ( struct tipc_bearer b_ptr,
u32  dest 
)

Definition at line 274 of file bearer.c.

int tipc_bearer_resolve_congestion ( struct tipc_bearer b_ptr,
struct tipc_link l_ptr 
)

Definition at line 363 of file bearer.c.

void tipc_bearer_schedule ( struct tipc_bearer b_ptr,
struct tipc_link l_ptr 
)

Definition at line 350 of file bearer.c.

void tipc_bearer_stop ( void  )

Definition at line 588 of file bearer.c.

int tipc_block_bearer ( const char name)

tipc_block_bearer - Block the bearer with the given name, and reset all its links

Definition at line 514 of file bearer.c.

void tipc_continue ( struct tipc_bearer tb_ptr)

Definition at line 321 of file bearer.c.

int tipc_disable_bearer ( const char name)

Definition at line 568 of file bearer.c.

int tipc_enable_bearer ( const char name,
u32  disc_domain,
u32  priority 
)

tipc_enable_bearer - enable bearer with the given name

Definition at line 394 of file bearer.c.

int tipc_eth_media_start ( void  )

tipc_eth_media_start - activate Ethernet bearer support

Register Ethernet media type with TIPC bearer code. Also register with OS for notifications about device state changes.

Definition at line 372 of file eth_media.c.

void tipc_eth_media_stop ( void  )

tipc_eth_media_stop - deactivate Ethernet bearer support

Definition at line 392 of file eth_media.c.

void tipc_media_addr_printf ( char buf,
int  len,
struct tipc_media_addr a 
)

tipc_media_addr_printf - record media address in print buffer

Definition at line 118 of file bearer.c.

struct tipc_media* tipc_media_find ( const char name)
read

tipc_media_find - locates specified media object by name

Definition at line 54 of file bearer.c.

struct sk_buff* tipc_media_get_names ( void  )
read

tipc_media_get_names - record names of registered media in buffer

Definition at line 141 of file bearer.c.

int tipc_media_set_priority ( const char name,
u32  new_value 
)
int tipc_media_set_window ( const char name,
u32  new_value 
)
void tipc_recv_msg ( struct sk_buff head,
struct tipc_bearer b_ptr 
)

tipc_recv_msg - process TIPC messages arriving from off-node : pointer to message buffer chain : pointer to bearer message arrived on

Invoked with no locks held. Bearer pointer must point to a valid bearer structure (i.e. cannot be NULL), but bearer can be inactive.

Definition at line 1604 of file link.c.

int tipc_register_media ( struct tipc_media m_ptr)

tipc_register_media - register a media type

Bearers for this media type must be activated separately at a later stage.

Definition at line 84 of file bearer.c.

Variable Documentation

struct tipc_bearer tipc_bearers[]

Definition at line 47 of file bearer.c.