Port Management Functions


Data Structures

struct  nmf_port_attr_state
 Port State Value. More...
struct  nmf_port_vlan_spec
 Port-Vlan Specification. More...
union  nmf_port_attr_value
 Port Attribute Value Types. More...
struct  nmf_port_stats
 Port Statistics. More...

Enumerations

enum  nmf_port_state
enum  nmf_port_bist_mode
 Port State Quailfier for BIST Mode.
enum  nmf_port_tagging_policy { NMF_PORT_VLAN_TAG_ADD_DEFAULT = 1, NMF_PORT_VLAN_TAG_ADD_EMPTY, NMF_PORT_VLAN_TAG_KEEP, NMF_PORT_VLAN_TAG_REPLACE }
enum  nmf_port_attr_id
 Port Attribute Identifiers. More...
enum  nmf_port_security_mode { NMF_PORT_SECURITY_OFF = 1, NMF_PORT_SECURITY_SAV, NMF_PORT_SECURITY_SPV, NMF_PORT_SECURITY_SHV }
 Port Security Modes. More...
enum  nmf_port_security_action { NMF_PORT_SECURITY_DROP = 1, NMF_PORT_SECURITY_TRAP }
 Port Security Actions. More...
enum  nmf_port_attr_lane_order
 Port Lane Ordering Settings.
enum  nmf_port_attr_lane_polarity
 Port Lane Polarity Settings.
enum  nmf_autoneg
 Port Autonegotiation Configuration. More...
enum  nmf_autoneg_capabilities
 Port Autonegotiation Capabilities Masks.
enum  nmf_dot1x_state { NMF_DOT1X_STATE_NOT_ACTIVE = 1, NMF_DOT1X_STATE_AUTH, NMF_DOT1X_STATE_NOT_AUTH }
 DOT1X Protocol State. More...
enum  nmf_port_capabilities
 Port Capabilities Mask.
enum  nmf_port_bridging_role
 Port Bridging Role Setting.

Functions

nmf_status_t nmf_port_attr_set (nmf_client_t clid, int slot, int port, enum nmf_port_attr_id id, union nmf_port_attr_value *value)
 Set a port attribute.
nmf_status_t nmf_port_attr_get (nmf_client_t clid, int slot, int port, enum nmf_port_attr_id id, union nmf_port_attr_value *value)
 Get a port attribute.
nmf_status_t nmf_port_stats_get (nmf_client_t clid, int slot, int port, struct nmf_port_stats *stats)
 Get a port's statistics.
nmf_status_t nmf_port_stats_reset (nmf_client_t clid, int slot, int port)
 Reset a port's statistic values to zero.
char * nmf_err_str (nmf_status_t s)
 Convert a status code of type nmf_status_t to a named string. This is useful for printing errors from API calls.

Detailed Description

Functions to administer the state of a switch port.

Enumeration Type Documentation

Port Autonegotiation Configuration.

Note that the availability of autonegotiation is specific to the PHY and may not be available on all ports.

Definition at line 776 of file nmf.h.

DOT1X Protocol State.

Enumerator:
NMF_DOT1X_STATE_NOT_ACTIVE  Not participating in 802.1x.
NMF_DOT1X_STATE_AUTH  802.1x is authorized.
NMF_DOT1X_STATE_NOT_AUTH  802.1x not authorized

Definition at line 797 of file nmf.h.

Port Attribute Identifiers.

TX_PAUSE_BIT_TIMES The number of bit-times that the link partner needs to pause in units of 512 bit-times. The attribute value may range from 0 to 65535. Specify zero to disable PAUSE. The default value is 65535

TX_PAUSE_MODE Determines the PAUSE frame format on transmit as follows: NMF_PORT_RX_PAUSE_CLASS_BASED, NMF_PORT_RX_PAUSE_NORMAL (default).

Definition at line 652 of file nmf.h.

Port Security Actions.

Enumerator:
NMF_PORT_SECURITY_DROP  Drop port security violations
NMF_PORT_SECURITY_TRAP  Trap port security violations to the mgmt port

Definition at line 725 of file nmf.h.

Port Security Modes.

Enumerator:
NMF_PORT_SECURITY_OFF  Turn off all source address security checks
NMF_PORT_SECURITY_SAV  Consider an unknown source address to be a security violation
NMF_PORT_SECURITY_SPV  Consider a known source address on a port other than what it was learned on to be a security violation
NMF_PORT_SECURITY_SHV  Consider an unknown source address or known source address previously learned on another port (station move) to be a security violation.

Definition at line 708 of file nmf.h.

Port states

Definition at line 590 of file nmf.h.

Enumerator:
NMF_PORT_VLAN_TAG_ADD_DEFAULT  Treat the incoming frame as if it is untagged for the purpose of VLAN association, i.e. the frame is associated with the per port VLAN default. If the frame leaves the switch tagged in 802.1Q mode, it gets an additional VLAN tag. If the frame leaves the switch untagged in 802.1Q mode, then any original VLAN is preserved, but this tag is not added.
NMF_PORT_VLAN_TAG_ADD_EMPTY  Treat the incoming frame as untagged but do not associate it with the default vlan. This allows the vlan tag to be processed by an ACL rule to rewrite the added tag.
NMF_PORT_VLAN_TAG_KEEP  Tag only untagged frames.
NMF_PORT_VLAN_TAG_REPLACE  Overwrite all frames with the port's default VLAN/VPRI

Definition at line 616 of file nmf.h.


Function Documentation

char* nmf_err_str ( nmf_status_t  s  ) 

Convert a status code of type nmf_status_t to a named string. This is useful for printing errors from API calls.

Parameters:
s An NMF status value.
Returns:
NMF_UNKNOWN If the nmf_status_t value exceeds the list of known status types.

string A string containing the name of the corresponding status value passed in.

nmf_status_t nmf_port_attr_get ( nmf_client_t  clid,
int  slot,
int  port,
enum nmf_port_attr_id  id,
union nmf_port_attr_value value 
)

Get a port attribute.

Parameters:
clid The client handle.
slot The slot number
port The port number.
id The attribute identifier
value Pointer to memory containing the attribute value
Returns:
NMF_OK Success

nmf_status_t nmf_port_attr_set ( nmf_client_t  clid,
int  slot,
int  port,
enum nmf_port_attr_id  id,
union nmf_port_attr_value value 
)

Set a port attribute.

Parameters:
clid The client handle.
slot The slot number.
port The port number.
id The attribute identifier
value Pointer to memory containing the attribute value.
Returns:
NMF_OK Success

nmf_status_t nmf_port_stats_get ( nmf_client_t  clid,
int  slot,
int  port,
struct nmf_port_stats stats 
)

Get a port's statistics.

Parameters:
clid The client handle.
slot The slot number
port The port number.
stats Pointer to structure to receive stats
Returns:
NMF_OK Success

nmf_status_t nmf_port_stats_reset ( nmf_client_t  clid,
int  slot,
int  port 
)

Reset a port's statistic values to zero.

Parameters:
clid The client handle.
slot The slot number
port The port number.
Returns:
NMF_OK Success


Generated on Wed Sep 1 09:40:57 2010 for NetManage by  doxygen 1.5.6