/* Data Path MAC API * Contains initialization APIs and runtime control APIs for DPMAC
*/
struct fsl_mc_io;
int dpmac_open(struct fsl_mc_io *mc_io,
u32 cmd_flags, int dpmac_id,
u16 *token);
int dpmac_close(struct fsl_mc_io *mc_io,
u32 cmd_flags,
u16 token);
/** * enum dpmac_link_type - DPMAC link type * @DPMAC_LINK_TYPE_NONE: No link * @DPMAC_LINK_TYPE_FIXED: Link is fixed type * @DPMAC_LINK_TYPE_PHY: Link by PHY ID * @DPMAC_LINK_TYPE_BACKPLANE: Backplane link type
*/ enum dpmac_link_type {
DPMAC_LINK_TYPE_NONE,
DPMAC_LINK_TYPE_FIXED,
DPMAC_LINK_TYPE_PHY,
DPMAC_LINK_TYPE_BACKPLANE
};
/** * struct dpmac_link_state - DPMAC link configuration request * @rate: Rate in Mbps * @options: Enable/Disable DPMAC link cfg features (bitmap) * @up: Link state * @state_valid: Ignore/Update the state of the link * @supported: Speeds capability of the phy (bitmap) * @advertising: Speeds that are advertised for autoneg (bitmap)
*/ struct dpmac_link_state {
u32 rate;
u64 options; int up; int state_valid;
u64 supported;
u64 advertising;
};
/** * enum dpmac_counter_id - DPMAC counter types * * @DPMAC_CNT_ING_FRAME_64: counts 64-bytes frames, good or bad. * @DPMAC_CNT_ING_FRAME_127: counts 65- to 127-bytes frames, good or bad. * @DPMAC_CNT_ING_FRAME_255: counts 128- to 255-bytes frames, good or bad. * @DPMAC_CNT_ING_FRAME_511: counts 256- to 511-bytes frames, good or bad. * @DPMAC_CNT_ING_FRAME_1023: counts 512- to 1023-bytes frames, good or bad. * @DPMAC_CNT_ING_FRAME_1518: counts 1024- to 1518-bytes frames, good or bad. * @DPMAC_CNT_ING_FRAME_1519_MAX: counts 1519-bytes frames and larger * (up to max frame length specified), * good or bad. * @DPMAC_CNT_ING_FRAG: counts frames which are shorter than 64 bytes received * with a wrong CRC * @DPMAC_CNT_ING_JABBER: counts frames longer than the maximum frame length * specified, with a bad frame check sequence. * @DPMAC_CNT_ING_FRAME_DISCARD: counts dropped frames due to internal errors. * Occurs when a receive FIFO overflows. * Includes also frames truncated as a result of * the receive FIFO overflow. * @DPMAC_CNT_ING_ALIGN_ERR: counts frames with an alignment error * (optional used for wrong SFD). * @DPMAC_CNT_EGR_UNDERSIZED: counts frames transmitted that was less than 64 * bytes long with a good CRC. * @DPMAC_CNT_ING_OVERSIZED: counts frames longer than the maximum frame length * specified, with a good frame check sequence. * @DPMAC_CNT_ING_VALID_PAUSE_FRAME: counts valid pause frames (regular and PFC) * @DPMAC_CNT_EGR_VALID_PAUSE_FRAME: counts valid pause frames transmitted * (regular and PFC). * @DPMAC_CNT_ING_BYTE: counts bytes received except preamble for all valid * frames and valid pause frames. * @DPMAC_CNT_ING_MCAST_FRAME: counts received multicast frames. * @DPMAC_CNT_ING_BCAST_FRAME: counts received broadcast frames. * @DPMAC_CNT_ING_ALL_FRAME: counts each good or bad frames received. * @DPMAC_CNT_ING_UCAST_FRAME: counts received unicast frames. * @DPMAC_CNT_ING_ERR_FRAME: counts frames received with an error * (except for undersized/fragment frame). * @DPMAC_CNT_EGR_BYTE: counts bytes transmitted except preamble for all valid * frames and valid pause frames transmitted. * @DPMAC_CNT_EGR_MCAST_FRAME: counts transmitted multicast frames. * @DPMAC_CNT_EGR_BCAST_FRAME: counts transmitted broadcast frames. * @DPMAC_CNT_EGR_UCAST_FRAME: counts transmitted unicast frames. * @DPMAC_CNT_EGR_ERR_FRAME: counts frames transmitted with an error. * @DPMAC_CNT_ING_GOOD_FRAME: counts frames received without error, including * pause frames. * @DPMAC_CNT_EGR_GOOD_FRAME: counts frames transmitted without error, including * pause frames.
*/ enum dpmac_counter_id {
DPMAC_CNT_ING_FRAME_64,
DPMAC_CNT_ING_FRAME_127,
DPMAC_CNT_ING_FRAME_255,
DPMAC_CNT_ING_FRAME_511,
DPMAC_CNT_ING_FRAME_1023,
DPMAC_CNT_ING_FRAME_1518,
DPMAC_CNT_ING_FRAME_1519_MAX,
DPMAC_CNT_ING_FRAG,
DPMAC_CNT_ING_JABBER,
DPMAC_CNT_ING_FRAME_DISCARD,
DPMAC_CNT_ING_ALIGN_ERR,
DPMAC_CNT_EGR_UNDERSIZED,
DPMAC_CNT_ING_OVERSIZED,
DPMAC_CNT_ING_VALID_PAUSE_FRAME,
DPMAC_CNT_EGR_VALID_PAUSE_FRAME,
DPMAC_CNT_ING_BYTE,
DPMAC_CNT_ING_MCAST_FRAME,
DPMAC_CNT_ING_BCAST_FRAME,
DPMAC_CNT_ING_ALL_FRAME,
DPMAC_CNT_ING_UCAST_FRAME,
DPMAC_CNT_ING_ERR_FRAME,
DPMAC_CNT_EGR_BYTE,
DPMAC_CNT_EGR_MCAST_FRAME,
DPMAC_CNT_EGR_BCAST_FRAME,
DPMAC_CNT_EGR_UCAST_FRAME,
DPMAC_CNT_EGR_ERR_FRAME,
DPMAC_CNT_ING_GOOD_FRAME,
DPMAC_CNT_EGR_GOOD_FRAME
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.