📄 devlib.c
字号:
/*
*---------------------------------------------------------------------------
*
* I N T E L P R O P R I E T A R Y
*
* COPYRIGHT (c) 2001 BY INTEL CORPORATION. ALL RIGHTS
* RESERVED. NO PART OF THIS PROGRAM OR PUBLICATION MAY
* BE REPRODUCED, TRANSMITTED, TRANSCRIBED, STORED IN A
* RETRIEVAL SYSTEM, OR TRANSLATED INTO ANY LANGUAGE OR COMPUTER
* LANGUAGE IN ANY FORM OR BY ANY MEANS, ELECTRONIC, MECHANICAL,
* MAGNETIC, OPTICAL, CHEMICAL, MANUAL, OR OTHERWISE, WITHOUT
* THE PRIOR WRITTEN PERMISSION OF :
*
* INTEL CORPORATION
*
* 2200 MISSION COLLEGE BLVD
*
* SANTA CLARA, CALIFORNIA 95052-8119
*
*---------------------------------------------------------------------------
*/
#include "devlib.h"
#include "common_def.h"
/*****************************************************************************
**** IXF6192 ****
*****************************************************************************/
#ifdef INCLUDE_6192_LIB
/* Function Pointers for the Ixf6192 Chip */
const CommonFunctionPointers_t ixf6192CommonFuncPtrs =
{
Ixf6192InitChip, /* InitChip */
Ixf6192InitAllocMemory, /* InitAllocMemory */
Ixf6192DeAllocMemory, /* DeAllocMemory */
NULL, /* GetStatus */
NULL, /* GetOpMode */
NULL, /* SetOpMode */
Ixf6192Reset, /* Reset */
Ixf6192InitAlarmCallback, /* InitAlarmCallback */
Ixf6192ChipIsr, /* ChipIsr */
Ixf6192CfgTest, /* CfgTest */
Ixf6192GetCounters, /* GetCounters */
Ixf6192GetChipInfo, /* GetChipInfo */
Ixf6192SetChipOnline, /* SetChipOnline */
Ixf6192SetChipOffline, /* SetChipOffline */
Ixf6192SetAlarmCfg, /* SetAlarmCfg */
Ixf6192GetBuildVersion, /* GetBuildVersion */
Ixf6192Read, /* Read */
Ixf6192Write, /* Write */
Ixf6192GetCfg, /* GetCfg */
Ixf6192SetCfg /* SetCfg */
};
const SonetFunctionPointers_t ixf6192SonetFuncPtrs =
{
Ixf6192GetWindowSize, /* GetWindow */
Ixf6192SetWindowSize, /* SetWindow */
NULL, /* SetBERThreshold */
Ixf6192GetTrace, /* GetTrace */
Ixf6192SetTrace, /* SetTrace */
Ixf6192GetOhBytes, /* GetOhBytes */
Ixf6192SetOhByte, /* SetOhBytes */
Ixf6192SetRmstSourceBytes, /* SetRmstSourceBytes */
Ixf6192GetRmstSourceBytes, /* GetRmstSourceBytes */
Ixf6192MapFrames, /* MapFrame */
Ixf6192GetMappedFrames, /* GetMappedFrame */
Ixf6192GetFramesAuPointer /* GetAuPointer */
};
const ChipFunctionPointers_t ixf6192FuncPtrs =
{
&ixf6192CommonFuncPtrs, /* COMMON routines */
&ixf6192SonetFuncPtrs, /* SONET routines*/
NULL /* XGMAC routines */
};
#endif /* INCLUDE_6192_LIB */
/*****************************************************************************
**** IXF6048 ****
*****************************************************************************/
#ifdef INCLUDE_6048_LIB
/* Function Pointers for the Ixf6048 Chip */
const CommonFunctionPointers_t ixf6048CommonFuncPtrs =
{
Ixf6048InitChip, /* InitChip */
#if 0
Ixf6048InitAllocMemory, /* InitAllocMemory */
Ixf6048DeAllocMemory, /* DeAllocMemory */
Ixf6048GetStatus, /* GetStatus */
Ixf6048GetOpMode, /* GetOpMode */
#else
NULL, /* InitAllocMemory */
NULL, /* DeAllocMemory */
NULL, /* GetStatus */
NULL, /* GetOpMode */
#endif
Ixf6048SetOpMode, /* SetOpMode */
Ixf6048Reset, /* Reset */
#if 0
Ixf6048InitAlarmCallback, /* InitAlarmCallback */
Ixf6048ChipIsr, /* ChipIsr */
Ixf6048CfgTest, /* CfgTest */
Ixf6048GetCounters, /* GetCounters */
Ixf6048GetChipInfo, /* GetChipInfo */
Ixf6048SetChipOnline, /* SetChipOnline */
Ixf6048SetChipOffline, /* SetChipOffline */
Ixf6048SetAlarmCfg, /* SetAlarmCfg */
Ixf6048GetBuildVersion, /* GetBuildVersion */
#else
NULL, /* InitAlarmCallback */
NULL, /* ChipIsr */
NULL, /* CfgTest */
NULL, /* GetCounters */
NULL, /* GetChipInfo */
NULL, /* SetChipOnline */
NULL, /* SetChipOffline */
NULL, /* SetAlarmCfg */
NULL, /* GetBuildVersion */
#endif
Ixf6048Read, /* Read */
Ixf6048Write, /* Write */
NULL, /* GetCfg */
NULL /* SetCfg */
};
const SonetFunctionPointers_t ixf6048SonetFuncPtrs =
{
Ixf6048GetWindowSize, /* GetWindow */
Ixf6048SetWindowSize, /* SetWindow */
NULL, /* Set BER Threshold */
Ixf6048GetTrace, /* GetTrace */
Ixf6048SetTrace, /* SetTrace */
Ixf6048GetOhBytes, /* GetOhBytes */
Ixf6048SetOhByte, /* SetOhBytes */
NULL, /* SetRmstSourceBytes */
NULL, /* GetRmstSourceBytes */
NULL, /* MapFrame */
NULL, /* GetMappedFrame */
NULL /* GetAuPointer */
};
const ChipFunctionPointers_t ixf6048FuncPtrs =
{
(CommonFunctionPointers_t *)&ixf6048CommonFuncPtrs, /* COMMON routines */
(SonetFunctionPointers_t *)&ixf6048SonetFuncPtrs, /* SONET routines*/
NULL
};
#endif /* INCLUDE_6048_LIB */
/*****************************************************************************
**** IXF18100 ****
*****************************************************************************/
#ifdef INCLUDE_18100_LIB
/* Function Pointers for the Ixf18100 Chip */
const CommonFunctionPointers_t ixf18100CommonFuncPtrs =
{
Ixf18100InitChip, /* InitChip */
Ixf18100InitAllocMemory, /* InitAllocMemory */
Ixf18100DeAllocMemory, /* DeAllocMemory */
Ixf18100GetStatus, /* GetStatus */
Ixf18100GetOpMode, /* GetOpMode */
Ixf18100SetOpMode, /* SetOpMode */
Ixf18100Reset, /* Reset */
Ixf18100InitAlarmCallback, /* InitAlarmCallback */
Ixf18100ChipIsr, /* ChipIsr */
Ixf18100CfgTest, /* CfgTest */
Ixf18100GetCounters, /* GetCounters */
Ixf18100GetChipInfo, /* GetChipInfo */
NULL, /* SetChipOnline */
NULL, /* SetChipOffline */
Ixf18100SetAlarmCfg, /* SetAlarmCfg */
Ixf18100GetBuildVersion, /* GetBuildVersion */
Ixf18100Read, /* Read */
Ixf18100Write, /* Write */
Ixf18100GetCfg, /* GetCfg */
Ixf18100SetCfg /* SetCfg */
};
const SonetFunctionPointers_t ixf18100SonetFuncPtrs =
{
Ixf18100SonetGetWindowSize, /* GetWindow */
Ixf18100SonetSetWindowSize, /* SetWindow */
NULL, /* Set BER Threshold */
Ixf18100SonetGetTrace, /* GetTrace */
Ixf18100SonetSetTrace, /* SetTrace */
Ixf18100SonetGetOhBytes, /* GetOhBytes */
Ixf18100SonetSetOhBytes, /* SetOhBytes */
NULL, /* SetRmstSourceBytes */
NULL, /* GetRmstSourceBytes */
NULL, /* MapFrame */
NULL, /* GetMappedFrame */
NULL /* GetAuPointer */
};
const XgmacFunctionPointers_t ixf18100XgmacFuncPtrs =
{
Ixf18100XgmacGetAddress, /* GetMACAddress */
Ixf18100XgmacSetAddress /* SetMACAddress */
};
const ChipFunctionPointers_t ixf18100FuncPtrs =
{
&ixf18100CommonFuncPtrs, /* COMMON routines */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -