Data Structures | Macros | Typedefs | Enumerations
cpsw_macport.h File Reference

This file contains the structure definitions and function prototypes of the MAC Port submodule. More...

#include "cpsw_types.h"
#include "cpsw_port.h"

Data Structures

struct  CpswMacPort_Interface_s
 MAC port interface. More...
 
struct  CpswMacPort_SgmiiConfig_s
 SGMII configuration for MAC port. More...
 
struct  CpswMacPort_Config_s
 MAC port configuration. More...
 
struct  CpswMacPort_GenericInArgs_s
 Generic input args. More...
 
struct  CpswMacPort_PortStatus_s
 Port status. More...
 
struct  CpswMacPort_FifoStats_s
 FIFO related statistics of a MAC port. More...
 
struct  CpswMacPort_LinkConfig_s
 Link speed and duplexity configuration. More...
 
struct  CpswMacPort_SetTxPriorityInArgs_s
 Input args for CPSW_MACPORT_IOCTL_SET_TX_PRIORITY command. More...
 
struct  CpswMacPort_SetRxPriorityInArgs_s
 Input args for CPSW_MACPORT_IOCTL_SET_RX_PRIORITY command. More...
 
struct  CpswMacPort_SetRxDscpPriorityInArgs_s
 Input args for CPSW_MACPORT_IOCTL_SET_RX_DSCP_PRIORITY command. More...
 
struct  CpswMacPort_SetTrafficShapingInArgs_s
 Input args for CPSW_MACPORT_IOCTL_SET_TRAFFIC_SHAPING command. More...
 
struct  CpswMacPort_SetTxBlocksRemInArgs_s
 Input args for CPSW_MACPORT_IOCTL_SET_TX_BLOCKS_REM command. More...
 
struct  CpswMacPort_InterVlanRoutingParams_s
 Port interVLAN configuration info. More...
 
struct  CpswMacPort_TxShortGapConfig_s
 Configuration of transmit short inter packet gap feature. More...
 
struct  CpswMacPort_PortTxShortGapConfig_s
 Set transmit short inter packet gap feature input Args. More...
 
struct  CpswMacPort_IpTsConfig_s
 Port IP configuration for time synchronization events. More...
 
struct  CpswMacPort_TsEventConfig_s
 Port Configuration for Time Synchronization. More...
 
struct  CpswMacPort_EnableTsEventInArgs_s
 Enable Port Time Sync Event IOCTL inArgs. More...
 

Macros

#define CPSW_MACPORT_PUBLIC_IOCTL(x)   (CPSW_IOCTL_MACPORT_BASE | CPSW_IOCTL_MIN(x))
 Helper macro to create IOCTL commands for MAC port submodule.
 

Typedefs

typedef enum CpswMac_LayerType_e CpswMac_LayerType
 MAC interface layer type.
 
typedef enum CpswMac_SublayerType_e CpswMac_SublayerType
 MAC interface sublayer type.
 
typedef enum CpswMac_VariantType_e CpswMac_VariantType
 MAC interface variant (only for specific interface types)
 
typedef enum
CpswMacPort_InterVLANRouteId_e 
CpswMacPort_InterVLANRouteId
 MAC port interVLAN route identifier.
 
typedef enum CpswMacPort_VlanType_e CpswMacPort_VlanType
 Enum of VLAN usage type for CPTS packets.
 
typedef struct
CpswMacPort_Interface_s 
CpswMacPort_Interface
 MAC port interface.
 
typedef enum
CpswMac_SgmiiModeType_e 
CpswMac_SgmiiModeType
 SGMII mode type.
 
typedef struct
CpswMacPort_SgmiiConfig_s 
CpswMacPort_SgmiiConfig
 SGMII configuration for MAC port.
 
typedef struct CpswMacPort_Config_s CpswMacPort_Config
 MAC port configuration.
 
typedef struct
CpswMacPort_GenericInArgs_s 
CpswMacPort_GenericInArgs
 Generic input args.
 
typedef struct
CpswMacPort_PortStatus_s 
CpswMacPort_PortStatus
 Port status.
 
typedef struct
CpswMacPort_FifoStats_s 
CpswMacPort_FifoStats
 FIFO related statistics of a MAC port.
 
typedef struct
CpswMacPort_LinkConfig_s 
CpswMacPort_LinkConfig
 Link speed and duplexity configuration.
 
typedef struct
CpswMacPort_SetTxPriorityInArgs_s 
CpswMacPort_SetTxPriorityInArgs
 Input args for CPSW_MACPORT_IOCTL_SET_TX_PRIORITY command.
 
typedef struct
CpswMacPort_SetRxPriorityInArgs_s 
CpswMacPort_SetRxPriorityInArgs
 Input args for CPSW_MACPORT_IOCTL_SET_RX_PRIORITY command.
 
typedef struct
CpswMacPort_SetRxDscpPriorityInArgs_s 
CpswMacPort_SetRxDscpPriorityInArgs
 Input args for CPSW_MACPORT_IOCTL_SET_RX_DSCP_PRIORITY command.
 
typedef struct
CpswMacPort_SetTrafficShapingInArgs_s 
CpswMacPort_SetTrafficShapingInArgs
 Input args for CPSW_MACPORT_IOCTL_SET_TRAFFIC_SHAPING command.
 
typedef struct
CpswMacPort_SetTxBlocksRemInArgs_s 
CpswMacPort_SetTxBlocksRemInArgs
 Input args for CPSW_MACPORT_IOCTL_SET_TX_BLOCKS_REM command.
 
typedef struct
CpswMacPort_InterVlanRoutingParams_s 
CpswMacPort_InterVlanRoutingParams
 Port interVLAN configuration info.
 
typedef struct
CpswMacPort_TxShortGapConfig_s 
CpswMacPort_TxShortGapConfig
 Configuration of transmit short inter packet gap feature.
 
typedef struct
CpswMacPort_PortTxShortGapConfig_s 
CpswMacPort_PortTxShortGapConfig
 Set transmit short inter packet gap feature input Args.
 
typedef struct
CpswMacPort_IpTsConfig_s 
CpswMacPort_IpTsConfig
 Port IP configuration for time synchronization events. More...
 
typedef struct
CpswMacPort_TsEventConfig_s 
CpswMacPort_TsEventConfig
 Port Configuration for Time Synchronization. More...
 
typedef struct
CpswMacPort_EnableTsEventInArgs_s 
CpswMacPort_EnableTsEventInArgs
 Enable Port Time Sync Event IOCTL inArgs.
 
typedef struct CpswMacPort_Obj_s * CpswMacPort_Handle
 MAC port submodule handle. More...
 

Enumerations

enum  CpswMacPort_Ioctls_e {
  CPSW_MACPORT_IOCTL_GET_STATUS = CPSW_MACPORT_PUBLIC_IOCTL(0U), CPSW_MACPORT_IOCTL_GET_FIFO_STATS = CPSW_MACPORT_PUBLIC_IOCTL(1U), CPSW_MACPORT_IOCTL_GET_LINK_CONFIG = CPSW_MACPORT_PUBLIC_IOCTL(2U), CPSW_MACPORT_IOCTL_IS_INBAND = CPSW_MACPORT_PUBLIC_IOCTL(3U),
  CPSW_MACPORT_IOCTL_SET_TX_PRIORITY = CPSW_MACPORT_PUBLIC_IOCTL(4U), CPSW_MACPORT_IOCTL_GET_TX_PRIORITY = CPSW_MACPORT_PUBLIC_IOCTL(5U), CPSW_MACPORT_IOCTL_SET_RX_PRIORITY = CPSW_MACPORT_PUBLIC_IOCTL(6U), CPSW_MACPORT_IOCTL_GET_RX_PRIORITY = CPSW_MACPORT_PUBLIC_IOCTL(7U),
  CPSW_MACPORT_IOCTL_SET_RX_DSCP_PRIORITY = CPSW_MACPORT_PUBLIC_IOCTL(8U), CPSW_MACPORT_IOCTL_GET_RX_DSCP_PRIORITY = CPSW_MACPORT_PUBLIC_IOCTL(9U), CPSW_MACPORT_IOCTL_SET_TRAFFIC_SHAPING = CPSW_MACPORT_PUBLIC_IOCTL(10U), CPSW_MACPORT_IOCTL_GET_TRAFFIC_SHAPING = CPSW_MACPORT_PUBLIC_IOCTL(11U),
  CPSW_MACPORT_IOCTL_SET_TX_BLOCKS_REM = CPSW_MACPORT_PUBLIC_IOCTL(12U), CPSW_MACPORT_IOCTL_GET_TX_BLOCKS_REM = CPSW_MACPORT_PUBLIC_IOCTL(13U), CPSW_MACPORT_IOCTL_PRINT_REGS = CPSW_MACPORT_PUBLIC_IOCTL(14U), CPSW_MACPORT_IOCTL_GET_RX_MTU = CPSW_MACPORT_PUBLIC_IOCTL(15U),
  CPSW_MACPORT_IOCTL_ENABLE_CPTS_EVENT = CPSW_MACPORT_PUBLIC_IOCTL(16U), CPSW_MACPORT_IOCTL_DISABLE_CPTS_EVENT = CPSW_MACPORT_PUBLIC_IOCTL(17U)
}
 MAC port IOCTL commands. More...
 
enum  CpswMac_LayerType_e { CPSW_MAC_LAYER_MII = 1U, CPSW_MAC_LAYER_GMII = 0U, CPSW_MAC_LAYER_XGMII = 2U }
 MAC interface layer type. More...
 
enum  CpswMac_SublayerType_e {
  CPSW_MAC_SUBLAYER_STANDARD = 0U, CPSW_MAC_SUBLAYER_REDUCED = 1U, CPSW_MAC_SUBLAYER_SERIAL = 2U, CPSW_MAC_SUBLAYER_QUAD_SERIAL_MAIN = 3U,
  CPSW_MAC_SUBLAYER_QUAD_SERIAL_SUB = 4U
}
 MAC interface sublayer type. More...
 
enum  CpswMac_VariantType_e { CPSW_MAC_VARIANT_NONE = 0U, CPSW_MAC_VARIANT_FORCED = 1U }
 MAC interface variant (only for specific interface types) More...
 
enum  CpswMacPort_InterVLANRouteId_e {
  CPSW_MACPORT_INTERVLAN_ROUTEID_FIRST, CPSW_MACPORT_INTERVLAN_ROUTEID_1 = CPSW_MACPORT_INTERVLAN_ROUTEID_FIRST, CPSW_MACPORT_INTERVLAN_ROUTEID_2, CPSW_MACPORT_INTERVLAN_ROUTEID_3,
  CPSW_MACPORT_INTERVLAN_ROUTEID_4, CPSW_MACPORT_INTERVLAN_ROUTEID_LAST = CPSW_MACPORT_INTERVLAN_ROUTEID_4
}
 MAC port interVLAN route identifier. More...
 
enum  CpswMacPort_VlanType_e { CPSW_MACPORT_VLAN_TYPE_NONE = 0x00U, CPSW_MACPORT_VLAN_TYPE_SINGLE_TAG = 0x01U, CPSW_MACPORT_VLAN_TYPE_STACKED_TAGS = 0x02U }
 Enum of VLAN usage type for CPTS packets. More...
 
enum  CpswMac_SgmiiModeType_e {
  CPSW_MAC_SGMIIMODE_INVALID = 0U, CPSW_MAC_SGMIIMODE_FIBER_WITH_PHY = 1U, CPSW_MAC_SGMIIMODE_SGMII_WITH_PHY = 2U, CPSW_MAC_SGMIIMODE_SGMII_AUTONEG_MASTER = 3U,
  CPSW_MAC_SGMIIMODE_SGMII_AUTONEG_SLAVE = 4U, CPSW_MAC_SGMIIMODE_SGMII_FORCEDLINK = 5U
}
 SGMII mode type. More...
 

Detailed Description

This file contains the structure definitions and function prototypes of the MAC Port submodule.


Copyright 2020, Texas Instruments Incorporated