Software Drivers

xsrio.h File Reference

#include <string.h>
#include "xstatus.h"
#include "xil_assert.h"
#include "xsrio_hw.h"

Classes

struct  XSrio_Config
struct  XSrio

Defines

#define XSRIO_H
#define XSRIO_IS_MEMORY   1
#define XSRIO_IS_PROCESSOR   2
#define XSRIO_IS_BRIDGE   3
#define XSRIO_OP_MODE_NREAD   0
#define XSRIO_OP_MODE_NWRITE   1
#define XSRIO_OP_MODE_SWRITE   2
#define XSRIO_OP_MODE_NWRITE_R   3
#define XSRIO_OP_MODE_DATA_MESSAGE   4
#define XSRIO_OP_MODE_DOORBELL   5
#define XSRIO_OP_MODE_ATOMIC   6
#define XSRIO_PORT_OK   0
#define XSRIO_PORT_UNINITIALIZED   1
#define XSRIO_PORT_HAS_ERRORS   2
#define XSRIO_DIR_TX   1
#define XSRIO_DIR_RX   2
#define XSrio_ReadDeviceVendorID(InstancePtr)
#define XSrio_ReadDeviceID(InstancePtr)
#define XSrio_ReadAsmVendorID(InstancePtr)
#define XSrio_ReadAsmID(InstancePtr)
#define XSrio_GetExFeaturesPointer(InstancePtr)
#define XSrio_ReadAsmRevision(InstancePtr)
#define XSrio_IsLargeSystem(InstancePtr)
#define XSrio_IsCRFSupported(InstancePtr)
#define XSrio_ReadSrcOps(InstancePtr)
#define XSrio_ReadDstOps(InstancePtr)
#define XSrio_GetLCSBA(InstancePtr)
#define XSrio_SetLCSBA(InstancePtr, Value)
#define XSrio_GetLargeBaseDeviceID(InstancePtr)
#define XSrio_SetLargeBaseDeviceID(InstancePtr, DeviceId)
#define XSrio_GetBaseDeviceID(InstancePtr)
#define XSrio_SetBaseDeviceID(InstancePtr, DeviceId)
#define XSrio_GetHostBaseDevID_LockCSR(InstancePtr)
#define XSrio_SetHostBaseDevID_LockCSR(InstancePtr, DeviceId)
#define XSrio_GetComponentTagCSR(InstancePtr)
#define XSrio_SetComponentTagCSR(InstancePtr, Value)
#define XSrio_GetExtFeaturesID(InstancePtr)
#define XSrio_GetSerialExtFeaturesPointer(InstancePtr)
#define XSrio_GetPortLinkTimeOutValue(InstancePtr)
#define XSrio_SetPortLinkTimeOutValue(InstancePtr, Value)
#define XSrio_GetPortRespTimeOutValue(InstancePtr)
#define XSrio_SetPortRespTimeOutValue(InstancePtr, Value)
#define XSrio_IsPEDiscovered(InstancePtr)
#define XSrio_SetDiscovered(InstancePtr)
#define XSrio_IsMasterEnabled(InstancePtr)
#define XSrio_SetMasterEnabled(InstancePtr)
#define XSrio_IsHost(InstancePtr)
#define XSrio_SetHostEnabled(InstancePtr)
#define XSrio_GetCommand(InstancePtr)
#define XSrio_SendCommand(InstancePtr, Value)
#define XSrio_IsResponseValid(InstancePtr)
#define XSrio_GetOutboundAckID(InstancePtr)
#define XSrio_SetOutboundAckID(InstancePtr, Value)
#define XSrio_GetInboundAckID(InstancePtr)
#define XSrio_SetInboundAckID(InstancePtr, Value)
#define XSrio_ClrOutStandingAckIDs(InstancePtr)
#define XSrio_IsEnumerationBoundary(InstancePtr)
#define XSrio_ClrEnumerationBoundary(InstancePtr)
#define XSrio_GetPortwidthOverride(InstancePtr)
#define XSrio_SetPortwidthOverride(InstancePtr, Value)
#define XSrio_GetSerialLaneExtFeaturesPointer(InstancePtr)
#define XSrio_ClrDecodingErrors(InstancePtr, Lanenum)
#define XSrio_GetRxSize(InstancePtr)
#define XSrio_ForceRxFlowControl(InstancePtr)
#define XSrio_GetTxSize(InstancePtr)
#define XSrio_CheckforTxReqreorder(InstancePtr)
#define XSrio_IsTxFlowControl(InstancePtr)
#define XSrio_GetDestinationID(InstancePtr)
#define XSrio_SetDestinationID(InstancePtr, Value)
#define XSrio_GetCRF(InstancePtr)
#define XSrio_SetCRF(InstancePtr)
#define XSrio_GetPriority(InstancePtr)
#define XSrio_SetPriority(InstancePtr, Value)
#define XSrio_RequestTID(InstancePtr)
#define XSrio_SetTID(InstancePtr, Value)
#define XSrio_ClrPortError(InstancePtr, Mask)
#define XSrio_GetPortErrorStatus(InstancePtr)
#define XSrio_SetPortControlStatus(InstancePtr, Mask)
#define XSrio_GetPortControlStatus(InstancePtr)

Functions

int XSrio_CfgInitialize (XSrio *InstancePtr, XSrio_Config *Config, u32 EffectiveAddress)
XSrio_ConfigXSrio_LookupConfig (u32 DeviceId)
int XSrio_GetPortStatus (XSrio *InstancePtr)
int XSrio_GetPEType (XSrio *InstancePtr)
int XSrio_IsOperationSupported (XSrio *InstancePtr, u8 Operation, u8 Direction)
void XSrio_SetWaterMark (XSrio *InstancePtr, u8 WaterMark0, u8 WaterMark1, u8 WaterMark2)
void XSrio_GetWaterMark (XSrio *InstancePtr, u8 *WaterMark0, u8 *WaterMark1, u8 *WaterMark2)

Detailed Description


Define Documentation

#define XSrio_CheckforTxReqreorder ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_IMP_BCSR_OFFSET) & \
             XSRIO_IMP_BCSR_TXREQ_REORDER_MASK) ? TRUE : FALSE)

XSrio_CheckforTxReqreorder checks whether the transmit buffer has been configured to allow reordering of requests.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the Tx Request reorder is enabled in the core.
  • FALSE If the Tx Request reorder is not enabled in the core.
Note:
C-style signature: u8 XSrio_CheckforTxReqreorder(XSrio *InstancePtr)
#define XSrio_ClrDecodingErrors ( InstancePtr,
Lanenum   ) 
Value:

XSrio_ClrDecodingErrors clears the 8B/10B decoding errors and return Result.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Lanenum is the Serial Lane-number(0,1,2,3).
Returns:
None
Note:
C-style signature: int XSrio_ClrDecodingErrors(XSrio *InstancePtr, u8 Lanenum)
#define XSrio_ClrEnumerationBoundary ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_N_CTL_CSR_OFFSET,      \
              (XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
               XSRIO_PORT_N_CTL_CSR_OFFSET) \
                | XSRIO_PORT_N_CTL_CSR_ENUMB_MASK)))

XSrio_ClrEnumerationBoundary clears the enumeration boundary of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_ClrEnumerationBoundary(XSrio *InstancePtr)
#define XSrio_ClrOutStandingAckIDs ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_N_ACKID_CSR_OFFSET,         \
              (XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                XSRIO_PORT_N_ACKID_CSR_OFFSET)  \
                | XSRIO_PORT_N_ACKID_CSR_CLSACKID_MASK)))

XSrio_ClrOutStandingAckIDs clears all outstanding unacknowledged received packets of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_ClrOutStandingAckIDs(XSrio *InstancePtr)
#define XSrio_ClrPortError ( InstancePtr,
Mask   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_N_ERR_STS_CSR_OFFSET,  \
              (XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                  XSRIO_PORT_N_ERR_STS_CSR_OFFSET) | \
                 (Mask & XSRIO_PORT_N_ERR_STS_CSR_ERR_ALL_MASK))))

XSrio_ClrPortError clears the Port Error specified by the Mask.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Mask is the mask for the Port Error to be cleared.
Returns:
None.
Note:
C-style signature: void XSrio_ClrPortError(XSrio *InstancePtrm, u32 Mask)
#define XSRIO_DIR_RX   2

Receive Direction Flag

#define XSRIO_DIR_TX   1

Transmit Direction Flag

#define XSrio_ForceRxFlowControl ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_IMP_BCSR_OFFSET,    \
                (XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
                    XSRIO_IMP_BCSR_OFFSET) | \
                                XSRIO_IMP_BCSR_FRX_FLOW_CNTL_MASK)))

XSrio_ForceRxFlowControl forces the Tx flow control enabled core to use Rx flow control.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_ForceRxFlowControl(XSrio *InstancePtr)
#define XSrio_GetBaseDeviceID ( InstancePtr   ) 
Value:

XSrio_GetBaseDeviceID returns the 8-bit Device Id for an endpoint in a small Transport system.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
8-bit Device Id.
Note:
C-style signature: u8 XSrio_GetBaseDeviceID(XSrio *InstancePtr)
#define XSrio_GetCommand ( InstancePtr   ) 
Value:

XSrio_GetCommand returns the command value that is sent on the Link-request Control symbol of the SRIO Gen2 core. This api is available only if the software assisted error recovery option is enabled in the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Command information of the link-request control symbol.
Note:
C-style signature: u32 XSrio_GetCommand(XSrio *InstancePtr)
#define XSrio_GetComponentTagCSR ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
             XSRIO_COMPONENT_TAG_CSR_OFFSET))

XSrio_GetComponentTagCSR returns the Component Tag Value set by the software during initialization.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Component Tag Value.
Note:
C-style signature: u32 XSrio_GetComponentTagCSR(XSrio *InstancePtr)
#define XSrio_GetCRF ( InstancePtr   ) 
Value:

XSrio_GetCRF checks whether the CRF is enabled in the core or not which will be used for outgoing maintenance requests.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
CRF Value used for outgoing maintenance requests.
Note:
C-style signature: u8 XSrio_GetCRF(XSrio *InstancePtr)
#define XSrio_GetDestinationID ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
             XSRIO_IMP_MRIR_OFFSET ) & \
             XSRIO_IMP_MRIR_REQ_DESTID_MASK)

XSrio_GetDestinationID gets the destination id value which will be used for outgoing maintenance requests.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Destination ID value of the outgoing maintenance request.
Note:
C-style signature: u8 XSrio_GetDestinationID(XSrio *InstancePtr)
#define XSrio_GetExFeaturesPointer ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
                XSRIO_ASM_INFO_CAR_OFFSET) & XSRIO_ASM_INFO_CAR_EFP_MASK)

XSrio_GetExFeaturesPointer gives the pointer to the Phy Register space of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Pointer to the Phy Register space of the core.
Note:
C-style signature: u16 XSrio_GetExFeaturesPointer(XSrio *InstancePtr)
#define XSrio_GetExtFeaturesID ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
             XSRIO_EFB_HEADER_OFFSET) & \
             XSRIO_EFB_HEADER_EFID_MASK)

XSrio_GetExtFeaturesID returns the Extended Features Id value.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Extended Features ID Value.
Note:
C-style signature: u16 XSrio_GetExtFeaturesID(XSrio *InstancePtr)
#define XSrio_GetHostBaseDevID_LockCSR ( InstancePtr   ) 
Value:

XSrio_GetHostBaseDevID_LockCSR returns the Device Id of the system host.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Device Id of the system host.
Note:
C-style signature: u16 XSrio_GetHostBaseDevID_LockCSR(XSrio *InstancePtr)
#define XSrio_GetInboundAckID ( InstancePtr   ) 
Value:

XSrio_GetInboundAckID returns the expected Ackid of the next received packet of the SRIO Gen2 core. This api is available only if the software assisted error recovery option is selected in the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Inbound Ack ID value.
Note:
C-style signature: u32 XSrio_GetInboundAckID(XSrio *InstancePtr)
#define XSrio_GetLargeBaseDeviceID ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
             XSRIO_BASE_DID_CSR_OFFSET) & \
             XSRIO_BASE_DID_CSR_LBDID_MASK)

XSrio_GetLargeBaseDeviceID returns the 16-bit Device Id for an endpoint in a Large transport system.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
16-bit Device Id.
Note:
C-style signature: u16 XSrio_GetLargeBaseDeviceID(XSrio *InstancePtr)
#define XSrio_GetLCSBA ( InstancePtr   ) 
Value:

XSrio_GetLCSBA returns the Local Configuration Space Base Address(LCSBA) of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Contents of Local Configuration Space Base Address Register.
Note:
C-style signature: u32 XSrio_GetLCSBA(XSrio *InstancePtr)
#define XSrio_GetOutboundAckID ( InstancePtr   ) 
Value:

XSrio_GetOutboundAckID returns the value of the next transmitted Ackid of the SRIO Gen2 Core. This api is available only if the software assisted error recovery option is selected core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Outbound Ack ID value.
Note:
C-style signature: u32 XSrio_GetOutboundAckID(XSrio *InstancePtr)
#define XSrio_GetPortControlStatus ( InstancePtr   ) 
Value:

XSrio_GetPortControlStatus returns the status of the port that is currently enabled in the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
The bit mask for the ports that are currently enabled.
Note:
C-style signature: u32 XSrio_GetPortControlStatus(XSrio *InstancePtr)
#define XSrio_GetPortErrorStatus ( InstancePtr   ) 
Value:

XSrio_GetPortErrorStatus returns the mask for the port errors currently enabled in the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
The bit mask for the port errors that are currently enabled.
Note:
C-style signature: u32 XSrio_GetPortErrorStatus(XSrio *InstancePtr)
#define XSrio_GetPortLinkTimeOutValue ( InstancePtr   ) 
Value:

XSrio_GetPortLinkTimeOutValue returns the Port Link Timeout value for the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Port link Timeout Value.
Note:
C-style signature: u32 XSrio_GetPortLinkTimeOutValue(XSrio *InstancePtr)
#define XSrio_GetPortRespTimeOutValue ( InstancePtr   ) 
Value:

XSrio_GetPortRespTimeOutValue returns the Port Response Timeout value for the the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Port Response Timeout value.
Note:
C-style signature: u32 XSrio_GetPortRespTimeOutValue(XSrio *InstancePtr)
#define XSrio_GetPortwidthOverride ( InstancePtr   ) 
Value:

XSrio_GetPortwidthOverride returns the port width override value of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Port Width Override Value.
Note:
C-style signature: u8 XSrio_GetPortwidthOverride(XSrio *InstancePtr)
#define XSrio_GetPriority ( InstancePtr   ) 
Value:

XSrio_GetPriority priority used for outgoing maintenance requests.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Priority value.
Note:
C-style signature: u8 XSrio_GetPriority(XSrio *InstancePtr)
#define XSrio_GetRxSize ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
             XSRIO_IMP_BCSR_OFFSET ) & \
             XSRIO_IMP_BCSR_RXSIZE_MASK)

XSrio_GetRxSize returns the number of maximum-size packets the rx buffer holded.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Rx buffer size.
Note:
C-style signature: u8 XSrio_GetRxSize(XSrio *InstancePtr)
#define XSrio_GetSerialExtFeaturesPointer ( InstancePtr   ) 
Value:

XSrio_GetSerialExtFeaturesPointer returns the Extended Features Pointer which will point to the next extended features block if one exists.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Extended Features Pointer Address.
Note:
C-style signature: u16 XSrio_GetSerialExtFeaturesPointer(XSrio *InstancePtr)
#define XSrio_GetSerialLaneExtFeaturesPointer ( InstancePtr   ) 
Value:

XSrio_GetSerialLaneExtFeaturesPointer returns the extended features pointer For the serial lane which will point to the next extended features block If one exists.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Extended Features Pointer Address.
Note:
C-style signature: u16 XSrio_GetSerialLaneExtFeaturesPointer(XSrio *InstancePtr)
#define XSrio_GetTxSize ( InstancePtr   ) 
Value:

XSrio_GetTxSize returns the number of maximum-size packets the tx buffer holds.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Tx buffer size.
Note:
C-style signature: u8 XSrio_GetTxSize(XSrio *InstancePtr)
#define XSRIO_H
#define XSRIO_IS_BRIDGE   3

Core can be used as a bridge to another interface

#define XSRIO_IS_MEMORY   1

Core has physically addressable storage space

#define XSRIO_IS_PROCESSOR   2

Core has a local processor that runs code

#define XSrio_IsCRFSupported ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
                XSRIO_PEF_CAR_OFFSET) & XSRIO_PEF_CAR_CRF_MASK) ?  \
                        TRUE : FALSE)

XSrio_IsCRFSupported checks whether the PE(Processing Element) supports CRF(Critical Request Flow indicator).

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the System Supports CRF.
  • FALSE If the System Wont Support CRF.
Note:
C-style signature: u8 XSrio_IsCRFSupported(XSrio *InstancePtr)
#define XSrio_IsEnumerationBoundary ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_PORT_N_CTL_CSR_OFFSET) & \
             XSRIO_PORT_N_CTL_CSR_ENUMB_MASK) ? TRUE : FALSE)

XSrio_IsEnumerationBoundary checks whether the enumeration boundary is available or not for the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE if the EnumerationBoundary Enabled.
  • FALSE if the EnumerationBoundary is not Enabled.
Note:
C-style signature: u8 XSrio_IsEnumerationBoundary(XSrio *InstancePtr)
#define XSrio_IsHost ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
                XSRIO_PORT_GEN_CTL_CSR_OFFSET) \
                & XSRIO_PORT_GEN_CTL_CSR_HOST_MASK) ?  TRUE : FALSE)

XSrio_IsHost checks whether PE(Processing Element) is responsible for system exploration.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the Host bit is set.
  • FALSE If the Host bit is not set.
Note:
C-style signature: u8 XSrio_IsHost(XSrio *InstancePtr)
#define XSrio_IsLargeSystem ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
                XSRIO_PEF_CAR_OFFSET) & XSRIO_PEF_CAR_CTS_MASK) ?  \
                        TRUE : FALSE)

XSrio_IsLargeSystem checks whether PE(Processing Element) supports a large system (16-bit Device ids)

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the System Supports 16-bit Devices.
  • FALSE If the System Supports 8-bit Devices.
Note:
C-style signature: u8 XSrio_IsLargeSystem(XSrio *InstancePtr)
#define XSrio_IsMasterEnabled ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
                XSRIO_PORT_GEN_CTL_CSR_OFFSET) \
                & XSRIO_PORT_GEN_CTL_CSR_MENABLE_MASK) ?  TRUE : FALSE)

XSrio_IsMasterEnabled checks whether PE(Processing Element) is allowed to issue request into the system.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the Master Enable bit is set.
  • FALSE If the Master Enable bit is not set.
Note:
C-style signature: u8 XSrio_IsMasterEnabled(XSrio *InstancePtr)
#define XSrio_IsPEDiscovered ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
                XSRIO_PORT_GEN_CTL_CSR_OFFSET) & \
                XSRIO_PORT_GEN_CTL_CSR_DISCOVERED_MASK) ?  TRUE : FALSE)

XSrio_IsPEDiscovered checks whether the PE(Processing Element) is discovered or not.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the PE is Discovered.
  • FALSE If the PE is not Discovered.
Note:
C-style signature: u8 XSrio_IsPEDiscovered(XSrio *InstancePtr)
#define XSrio_IsResponseValid ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_PORT_N_MNT_RES_CSR_OFFSET) & \
             XSRIO_PORT_N_MNT_RES_CSR_RVALID_MASK) ? TRUE : FALSE)

XSrio_IsResponseValid checks whether the link response is valid or not in the SRIO Gen2 Core. This api is available only if the software assisted error recovery option is enabled in the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE if the corresponding link request causes a link response.
  • FALSE if the corresponding link request not causes a link response.
Note:
C-style signature: u8 XSrio_IsResponseValid(XSrio *InstancePtr)
#define XSrio_IsTxFlowControl ( InstancePtr   ) 
Value:
((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_IMP_BCSR_OFFSET) & \
             XSRIO_IMP_BCSR_TX_FLOW_CNTL_MASK) ? TRUE : FALSE)

XSrio_IsTxFlowControl checks whether the BUF is currently operating in Tx flow control mode or not.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
  • TRUE If the Tx Flow Control is enabled in the core.
  • FALSE If the Tx Flow Control is not enabled in the core.
Note:
C-style signature: u8 XSrio_IsTxFlowControl(XSrio *InstancePtr)
#define XSRIO_OP_MODE_ATOMIC   6

Core supports atomic Operation

#define XSRIO_OP_MODE_DATA_MESSAGE   4

Core supports data message Operation

#define XSRIO_OP_MODE_DOORBELL   5

Core supports doorbell Operation

#define XSRIO_OP_MODE_NREAD   0

Core supports read Operation

#define XSRIO_OP_MODE_NWRITE   1

Core supports write Operation

#define XSRIO_OP_MODE_NWRITE_R   3

Core supports write with Response operation

#define XSRIO_OP_MODE_SWRITE   2

Core supports streaming-write Operation

#define XSRIO_PORT_HAS_ERRORS   2

Port has errors

#define XSRIO_PORT_OK   0

Port is initialized

#define XSRIO_PORT_UNINITIALIZED   1

Port is uninitialized

#define XSrio_ReadAsmID ( InstancePtr   ) 
Value:

XSrio_ReadAsmID returns the Assembly Id of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Assembly ID of the core.
Note:
C-style signature: u16 XSrio_ReadAsmID(XSrio *InstancePtr)
#define XSrio_ReadAsmRevision ( InstancePtr   ) 
Value:

XSrio_ReadAsmRevision returns the Assembly Revision value of the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Assembly revision of the core.
Note:
C-style signature: u16 XSrio_ReadAsmRevision(XSrio *InstancePtr)
#define XSrio_ReadAsmVendorID ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
                XSRIO_ASM_ID_CAR_OFFSET) & XSRIO_ASM_ID_CAR_ASMVID_MASK)

XSrio_ReadAsmVendorID returns the Assembly Vendor Id of the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Assembly Vendor ID of the core.
Note:
C-style signature: u16 XSrio_ReadAsmVendorID(XSrio *InstancePtr)
#define XSrio_ReadDeviceID ( InstancePtr   ) 
Value:

XSrio_ReadDeviceID returns the Device Id of the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Device ID of the core.
Note:
C-style signature: u16 XSrio_ReadDeviceID(XSrio *InstancePtr)
#define XSrio_ReadDeviceVendorID ( InstancePtr   ) 
Value:
(XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
                XSRIO_DEV_ID_CAR_OFFSET) & XSRIO_DEV_ID_VDRID_CAR_MASK)

XSrio_ReadDeviceVendorID returns the Device Vendor Id of the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Device Vendor ID of the core.
Note:
C-style signature: u16 XSrio_ReadDeviceVendorID(XSrio *InstancePtr)
#define XSrio_ReadDstOps ( InstancePtr   ) 
Value:
XSrio_ReadReg((InstancePtr)->Config.BaseAddress,        \
                XSRIO_DST_OPS_CAR_OFFSET)

XSrio_ReadDstOps returns the Destination Operations CAR Register contents.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Contents of the Destination Operations CAR Register.
Note:
C-style signature: u32 XSrio_ReadDstOps(XSrio *InstancePtr)
#define XSrio_ReadSrcOps ( InstancePtr   ) 
Value:
XSrio_ReadReg((InstancePtr)->Config.BaseAddress,        \
                XSRIO_SRC_OPS_CAR_OFFSET)

XSrio_ReadSrcOps returns the Source Operations CAR Register contents.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Contents of the Source Operations CAR Register.
Note:
C-style signature: u32 XSrio_ReadSrcOps(XSrio *InstancePtr)
#define XSrio_RequestTID ( InstancePtr   ) 
Value:

XSrio_RequestTID gives the transfer id value which will be used for the next outgoing maintenance request. This value will increment after each request is sent.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
Transfer ID value.
Note:
C-style signature: u8 XSrio_RequestTID(XSrio *InstancePtr)
#define XSrio_SendCommand ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_PORT_N_MNT_REQ_CSR_OFFSET,        \
             Value & XSRIO_PORT_N_MNT_REQ_CSR_CMD_MASK))

XSrio_SendCommand sends the given command in the link-request control symbol of the SRIO Gen2 core. This api is available only if the software assisted error recovery option is selected in the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Command to be send.
Returns:
None.
Note:
C-style signature: void XSrio_SendCommand(XSrio *InstancePtr, u8 Value)
#define XSrio_SetBaseDeviceID ( InstancePtr,
DeviceId   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
           XSRIO_BASE_DID_CSR_OFFSET,  \
           ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,   \
             XSRIO_BASE_DID_CSR_OFFSET) & XSRIO_BASE_DID_CSR_LBDID_MASK) \
             |((DeviceId << XSRIO_BASE_DID_CSR_BDID_SHIFT) \
             & XSRIO_BASE_DID_CSR_BDID_MASK))))

XSrio_SetBaseDeviceID configures the 8-bit Device Id for an endpoint in a small transport system.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
DeviceId is the Device ID that needs to be configured.
Returns:
None.
Note:
C-style signature: void XSrio_SetBaseDeviceID(XSrio *InstancePtr, u8 DeviceId)
#define XSrio_SetComponentTagCSR ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_COMPONENT_TAG_CSR_OFFSET,         \
             Value))

XSrio_SetComponentTagCSR sets the Component Tag Value for SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Component Tag Value to be set.
Returns:
None.
Note:
C-style signature: void XSrio_SetComponentTagCSR(XSrio *InstancePtr, u32 Value)
#define XSrio_SetCRF ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_IMP_MRIR_OFFSET,    \
                (XSrio_ReadReg((InstancePtr)->Config.BaseAddress,       \
                    XSRIO_IMP_MRIR_OFFSET) | \
                                XSRIO_IMP_MRIR_REQ_CRF_MASK)))

XSrio_SetCRF sets CRF value that is used for outgoing maintenance requests. This api will work only when the CRF support is enabled in the core

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_SetCRF(XSrio *InstancePtr)
#define XSrio_SetDestinationID ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
           XSRIO_IMP_MRIR_OFFSET,       \
             ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                XSRIO_IMP_MRIR_OFFSET) & ~XSRIO_IMP_MRIR_REQ_DESTID_MASK) | \
                                (Value & XSRIO_IMP_MRIR_REQ_DESTID_MASK))))

XSrio_SetDestinationID sets Device Id which will be used for Outgoing maintenance requests.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Device Id value.
Returns:
None.
Note:
C-style signature: void XSrio_SetDestinationID(XSrio *InstancePtr, u8 Value)
#define XSrio_SetDiscovered ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_GEN_CTL_CSR_OFFSET,         \
             (XSrio_ReadReg((InstancePtr)->Config.BaseAddress,  \
                XSRIO_PORT_GEN_CTL_CSR_OFFSET)  \
                | XSRIO_PORT_GEN_CTL_CSR_DISCOVERED_MASK)))

XSrio_SetDiscovered configures the device as Discovered so that it is responsible for system exploration.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_SetDiscovered(XSrio *InstancePtr)
#define XSrio_SetHostBaseDevID_LockCSR ( InstancePtr,
DeviceId   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_HOST_DID_LOCK_CSR_OFFSET,         \
                  (DeviceId & XSRIO_HOST_DID_LOCK_CSR_HBDID_MASK)))

XSrio_SetHostBaseDevID_LockCSR configures the Host Base Device Id of the SRIO gen2 Core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
DeviceId is the Device ID that needs to be configured.
Returns:
None.
Note:
C-style signature: void XSrio_SetHostBaseDevID_LockCSR(XSrio *InstancePtr, u16 DeviceId)
#define XSrio_SetHostEnabled ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_GEN_CTL_CSR_OFFSET,         \
              (XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                XSRIO_PORT_GEN_CTL_CSR_OFFSET)  \
                | XSRIO_PORT_GEN_CTL_CSR_HOST_MASK)))

XSrio_SetHostEnabled configures the device to be responsible for system exploration.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_SetHostEnabled(XSrio *InstancePtr)
#define XSrio_SetInboundAckID ( InstancePtr,
Value   ) 
Value:

XSrio_SetInboundAckID sets the value of the next transmitted Ackid of the SRIO Gen2 core. This api is available only if the software assisted error recovery option is selected in the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the InBound Ack Id to be set.
Returns:
None.
Note:
C-style signature: void XSrio_SetInboundAckID(XSrio *InstancePtr, u8 Value) This api won't work if you call the XSrio_ClrOutStandingAckIDs before calling this api.
#define XSrio_SetLargeBaseDeviceID ( InstancePtr,
DeviceId   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_BASE_DID_CSR_OFFSET,                         \
             ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
              XSRIO_BASE_DID_CSR_OFFSET) & XSRIO_BASE_DID_CSR_BDID_MASK)  | \
              (DeviceId & XSRIO_BASE_DID_CSR_LBDID_MASK))))

XSrio_SetLargeBaseDeviceID configures the 16-bit Device Id for an endpoint in a Large transport system.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
DeviceId is the Device ID that needs to be configured.
Returns:
None.
Note:
C-style signature: void XSrio_SetLargeBaseDeviceID(XSrio *InstancePtr, u16 DeviceId)
#define XSrio_SetLCSBA ( InstancePtr,
Value   ) 
Value:

XSrio_SetLCSBA Configures the Local Configuration Space Base Address of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Local Configuration Space Base Address that needs to be configured.
Returns:
None.
Note:
C-style signature: void XSrio_SetLCSBA(XSrio *InstancePtr, u32 Value)
#define XSrio_SetMasterEnabled ( InstancePtr   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_GEN_CTL_CSR_OFFSET,         \
             (XSrio_ReadReg((InstancePtr)->Config.BaseAddress,  \
                XSRIO_PORT_GEN_CTL_CSR_OFFSET)  \
                | XSRIO_PORT_GEN_CTL_CSR_MENABLE_MASK)))

XSrio_SetMasterEnabled configures the device so that it is allowed to issue requests into the system.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Returns:
None.
Note:
C-style signature: void XSrio_SetMasterEnabled(XSrio *InstancePtr)
#define XSrio_SetOutboundAckID ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
             XSRIO_PORT_N_ACKID_CSR_OFFSET,  \
             ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                XSRIO_PORT_N_ACKID_CSR_OFFSET) &        \
                XSRIO_PORT_N_ACKID_CSR_RESET_OBACKID_MASK) \
                | (Value & XSRIO_PORT_N_ACKID_CSR_OBACKID_MASK))))

XSrio_SetOutboundAckID sets value of the next transmitted Ackid of the SRIO Gen2 Core. This api is available only if the software assisted error Recovery option is selected in the core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Outbound Ack Id to be set.
Returns:
None.
Note:
C-style signature: void XSrio_SetOutboundAckID(XSrio *InstancePtr, u8 Value)
#define XSrio_SetPortControlStatus ( InstancePtr,
Mask   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_N_CTL_CSR_OFFSET,      \
              (XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                XSRIO_PORT_N_CTL_CSR_OFFSET) \
                | (Mask & XSRIO_PORT_N_CTL_CSR_STATUS_ALL_MASK))))

XSrio_SetPortControlStatus Configures specific port specified by the Mask.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Mask is the mask for the port that needs to be enabled.
Returns:
None.
Note:
C-style signature: void XSrio_SetPortControlStatus(XSrio *InstancePtrm, u32 Mask)
#define XSrio_SetPortLinkTimeOutValue ( InstancePtr,
Value   ) 
Value:

XSrio_SetPortLinkTimeOutValue sets the Port Link Timeout value for the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Port Link Timeout value to be set.
Returns:
None.
Note:
C-style signature: void XSrio_SetPortLinkTimeOutValue(XSrio *InstancePtr, u16 Value)
#define XSrio_SetPortRespTimeOutValue ( InstancePtr,
Value   ) 
Value:

XSrio_SetPortRespTimeOutValue sets the Port Response Timeout value for the The SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Port Response Timeout to be set.
Returns:
None.
Note:
C-style signature: void XSrio_SetPortRespTimeOutValue(XSrio *InstancePtr, u16 Value)
#define XSrio_SetPortwidthOverride ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
              XSRIO_PORT_N_CTL_CSR_OFFSET,      \
                ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,      \
                        XSRIO_PORT_N_CTL_CSR_OFFSET) &  \
                                XSRIO_PORT_N_CTL_CSR_RESET_PWO_MASK) | \
                                ((Value << XSRIO_PORT_N_CTL_CSR_PWO_SHIFT)  \
                                        & XSRIO_PORT_N_CTL_CSR_PWO_MASK))))

XSrio_SetPortwidthOverride configures the port width override value of the SRIO Gen2 core.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the port width override value needs to be set.
Returns:
None.
Note:
C-style signature: void XSrio_SetPortwidthOverride(XSrio *InstancePtr, u8 Value)
#define XSrio_SetPriority ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
            XSRIO_IMP_MRIR_OFFSET,      \
             ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress, \
                 XSRIO_IMP_MRIR_OFFSET) & ~XSRIO_IMP_MRIR_REQ_PRIO_MASK) | \
                     ((Value << XSRIO_IMP_MRIR_REQ_PRIO_SHIFT)&  \
                          XSRIO_IMP_MRIR_REQ_PRIO_MASK))))

XSrio_SetPriority sets the Priority which will be used for outgoing maintenance requests.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the Priority value which will used for outgoing maintenance requests.
Returns:
None.
Note:
C-style signature: void XSrio_SetPriority(XSrio *InstancePtr, u8 Value)
#define XSrio_SetTID ( InstancePtr,
Value   ) 
Value:
(XSrio_WriteReg((InstancePtr)->Config.BaseAddress,      \
            XSRIO_IMP_MRIR_OFFSET,      \
              ((XSrio_ReadReg((InstancePtr)->Config.BaseAddress,        \
                  XSRIO_IMP_MRIR_OFFSET) & ~XSRIO_IMP_MRIR_REQ_TID_MASK) | \
                     ((Value << XSRIO_IMP_MRIR_REQ_TID_SHIFT)&  \
                           XSRIO_IMP_MRIR_REQ_TID_MASK))))

XSrio_SetTID sets the transfer id which will be used for the next outgoing maintenance request.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Value is the transfer id value which of the next outgoing maintenance request.
Returns:
None.
Note:
C-style signature: void XSrio_SetTID(XSrio *InstancePtr, u8 Value)

Function Documentation

int XSrio_CfgInitialize ( XSrio InstancePtr,
XSrio_Config Config,
u32  EffectiveAddress 
)

Initialization and Control functions in xsrio.c

Initialize the XSrio instance provided by the caller based on the given Config structure.

Parameters:
InstancePtr is the XSrio instance to operate on.
Config is the device configuration structure containing information about a specific SRIO Device.
EffectiveAddress is the Physical address of the hardware in a Virtual Memory operating system environment.It is the Base Address in a stand alone environment.
Returns:
  • XST_SUCCESS Initialization was successful.
Note:
None.
int XSrio_GetPEType ( XSrio InstancePtr  ) 

XSrio_GetPEType API will check for the Processing Element type and return the type of type of Processing Element

Parameters:
InstancePtr is the XSrio instance to operate on.
Returns:
  • XSRIO_IS_MEMORY if the core is configured as a memory
  • XSRIO_IS_PROCESSOR if the core is configured as a processor
  • XSRIO_IS_BRIDGE if the core is configured as a bridge.
Note:
: None.
int XSrio_GetPortStatus ( XSrio InstancePtr  ) 

XSrio_GetPortStatus will check the status of the port and returns the status of the port to the user

Parameters:
InstancePtr is the XSrio instance to operate on.
Returns:
  • XSRIO_PORT_OK Port is initialized with no errors.
  • XSRIO_PORT_UNINITIALIZED Port is not initialized. No Serial Rapidio link is present.
  • XSRIO_PORT_HAS_ERRORS Port is initialized but has errors.
Note:
: None.
void XSrio_GetWaterMark ( XSrio InstancePtr,
u8 *  WaterMark0,
u8 *  WaterMark1,
u8 *  WaterMark2 
)

XSrio_GetWaterMark API reads the water mark values.

Parameters:
InstancePtr is the XSrio instance to operate on.
WaterMark0 is a pointer to a variable where the driver will pass back the water mark 0 value.
WaterMark1 is a pointer to a variable where the driver will pass back the water mark 1 value.
WaterMark2 is a pointer to a variable where the driver will pass back the water mark 2 value.
Returns:
None.
Note:
: None.
int XSrio_IsOperationSupported ( XSrio InstancePtr,
u8  Operation,
u8  Direction 
)

XSrio_IsOperationSupported tells whether the operation is supported by the SRIO Gen2 core or not.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
Operation type is the operation type of the SRIO Packet
Direction type
Returns:
  • XST_SUCCESS if the operation is supported by the core.
    • XST_FAILURE if the operation is not supported by the core.
Note:
None.
XSrio_Config* XSrio_LookupConfig ( u32  DeviceId  ) 

Looks up the device configuration based on the unique device ID. The table XSrio_ConfigTable contains the configuration info for each device in the system.

Parameters:
DeviceId is the unique device ID of the device to lookup for
Returns:
The configuration structure for the device. If the device ID is not found,a NULL pointer is returned.
Note:
None
void XSrio_SetWaterMark ( XSrio InstancePtr,
u8  WaterMark0,
u8  WaterMark1,
u8  WaterMark2 
)

XSrio_SetWaterMark Configures the watermark to transfer a priority packet.

Parameters:
InstancePtr is a pointer to the SRIO Gen2 instance to be worked on.
WaterMark0 is the water mark value to transfer a priority 0 packet.
WaterMark1 is the water mark value to transfer a priority 1 packet.
WaterMark2 is the water mark value to transfer a priority 2 packet.
Returns:
None.
Note:
None.