aal2.h

来自「摩托罗拉Motolola公司网络处理器C3的示范代码.实现了ATM的AAL2层交」· C头文件 代码 · 共 54 行

H
54
字号
/* *  Copyright (c) 2001, 2002 C-Port Corporation *  All Rights Reserved * *  The information contained in this file is confidential and proprietary. *  Any reproduction, use or disclosure, in whole or in part, of this *  program, including any attempt to obtain a human-readable version of this *  program, without the express, prior written consent of C-Port *  Corporation is strictly prohibited. */#ifndef AAL2_H#define AAL2_H#include <dcpKernelSvcs.h>#define MAX_QUEUES_PER_PROC         4#define NUMBER_OF_CPS               16#define NUMBER_OF_PROCS             18#define CPprocID(x)   (((ProcCP & 0xFF) << 16) | (x))#define XPprocID      ((ProcXP & 0xFF) << 16)#define FPprocID      ((ProcFP & 0xFF) << 16)#define ATM_CP_FIRST      4#define ATM_CP_LAST       5#define QOS_CP_FIRST      6#define QOS_CP_LAST       7#define AAL2_RX_CLUSTER1_FIRST  0#define AAL2_RX_CLUSTER1_LAST   3 #define AAL2_RX_CLUSTER3_FIRST  8#define AAL2_RX_CLUSTER3_LAST   9 #define AAL2_TX_CP_FIRST  10#define AAL2_TX_CP_LAST   15#define ATM_CP(x)     ((x) >= ATM_CP_FIRST     && (x) <= ATM_CP_LAST)#define QOS_CP(x)     ((x) >= QOS_CP_FIRST  && (x) <= QOS_CP_LAST)#define AAL2_RX_CP(x) (((x) >= AAL2_RX_CLUSTER1_FIRST && (x) <= AAL2_RX_CLUSTER1_LAST) ||\                       ((x) >= AAL2_RX_CLUSTER3_FIRST && (x) <= AAL2_RX_CLUSTER3_LAST))#define AAL2_TX_CP(x) ((x) >= AAL2_TX_CP_FIRST && (x) <= AAL2_TX_CP_LAST)#undef APPLICATION_EVENT(id)#ifdef AAL2_APP_EVENT#define APPLICATION_EVENT(id) {  \    asm (".set noat"); \    asm volatile("andi $0, $0, " #id); \    asm (".set at"); \}#endif#endif /* AAL2_H */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?