beautypg.com

Data structure, Functions, Adlink_trunk_member_add () – ADLINK aTCA-N700 User Manual

Page 28: Adlink_trunk_monitor_t, Adlink_trunk_member_del ()

background image

Switch Manager API Programming Guide

28

Data Structure

adlink_trunk_monitor_t

typedef struct tm_port_node_s

{

UINT32 id; /*port number. start at 1 */

UINT32 status; /*link status. 0-link down/1-link up */

}tm_port_node_t;

typedef struct tm_group_node_s

{

UINT32 valid; /*indicate whether group is in monitor. 0-invalid/1-valid */

UINT32 cnt; /*port count in a trunk group*/

tm_port_node_t item[MAX_TRUNK_MEMBER]; /*port info*/

}tm_group_node_t;

typedef struct adlink_trunk_monitor_s

{

tm_group_node_t group[MAX_TRUNK_ID];

}adlink_trunk_monitor_t;

Define the entry format of port attribute table.

Functions

adlink_trunk_member_add ()

adlink_trunk_member_del ()

PROTOTYPE

status_t adlink_trunk_member_add (int trunk_id, UINT32 member_bmp);

status_t adlink_trunk_member_del (int trunk_id, UINT32 member_bmp);

DESCRIPTION

These functions are used to change trunk group member ports.

PARAMETERS

trunk_id

[IN] Trunk group id; Start from ‘1’;

member_bmp

[IN] Member ports in bitmap;