Root/target/linux/amazon/files/include/asm-mips/amazon/atm_mib.h

1#ifndef AMAZON_ATM_MIB_H
2#define AMAZON_ATM_MIB_H
3
4#ifdef CONFIG_IFX_ATM_MIB
5#include <asm/types.h>
6#ifdef __KERNEL__
7#include <linux/list.h>
8#endif
9#endif /* CONFIG_IFX_ATM_MIB */
10
11#ifndef __KERNEL__
12#include <atmMIB/local_list.h>
13typedef unsigned int __u32;
14#endif
15
16typedef struct{
17    __u32 ifHCInOctets_h;
18    __u32 ifHCInOctets_l;
19    __u32 ifHCOutOctets_h;
20    __u32 ifHCOutOctets_l;
21    __u32 ifInErrors;
22    __u32 ifInUnknownProtos;
23    __u32 ifOutErrors;
24}atm_cell_ifEntry_t;
25
26typedef struct{
27    __u32 ifHCInOctets_h;
28    __u32 ifHCInOctets_l;
29    __u32 ifHCOutOctets_h;
30    __u32 ifHCOutOctets_l;
31    __u32 ifInUcastPkts;
32    __u32 ifOutUcastPkts;
33    __u32 ifInErrors;
34    __u32 ifInDiscards;
35    __u32 ifOutErros;
36    __u32 ifOutDiscards;
37}atm_aal5_ifEntry_t;
38
39typedef struct{
40    __u32 aal5VccCrcErrors;
41    __u32 aal5VccSarTimeOuts;//no timer support yet
42    __u32 aal5VccOverSizedSDUs;
43}atm_aal5_vcc_t;
44
45#if defined(CONFIG_IFX_ATM_MIB) || defined(IFX_CONFIG_SNMP_ATM_MIB)
46/* ATM-MIB data structures */
47typedef struct atmIfConfEntry {
48    int ifIndex;
49    int atmInterfaceMaxVpcs;
50    int atmInterfaceMaxVccs;
51    int atmInterfaceConfVpcs;
52    int atmInterfaceConfVccs;
53    int atmInterfaceMaxActiveVpiBits;
54    int atmInterfaceMaxActiveVciBits;
55    int atmInterfaceIlmiVpi;
56    int atmInterfaceIlmiVci;
57    int atmInterfaceAddressType;
58    char atmInterfaceAdminAddress[40];
59    unsigned long atmInterfaceMyNeighborIpAddress;
60    char atmInterfaceMyNeighborIfName[20];
61    int atmInterfaceCurrentMaxVpiBits;
62    int atmInterfaceCurrentMaxVciBits;
63    char atmInterfaceSubscrAddress[40];
64    int flags;
65}atmIfConfEntry;
66
67typedef struct atmTrafficDescParamEntry {
68    /* Following three parameters are used to update VCC QoS values */
69    int ifIndex;
70    short atmVclvpi;
71    int atmVclvci;
72
73    unsigned int atmTrafficParamIndex;
74    unsigned char traffic_class;
75    int max_pcr;
76    /* Subramani: Added min_pcr */
77    int min_pcr;
78    int cdv;
79    int scr;
80    int mbs;
81    int atmTrafficRowStatus;
82    int atmTrafficFrameDiscard;
83    struct list_head vpivci_head;
84    struct list_head list;
85}atmTrafficDescParamEntry;
86
87
88typedef struct atmVclEntry {
89     int ifIndex;
90     short atmVclvpi;
91     int atmVclvci;
92     char vpivci[20];
93     int atmVclAdminStatus;
94     int atmVclOperStatus;
95    unsigned long atmVclLastChange;
96     struct atmTrafficDescParamEntry *atmVclRxTrafficPtr;
97     struct atmTrafficDescParamEntry *atmVclTxTrafficPtr;
98     unsigned char atmVccAalType;
99     unsigned int atmVccAal5TxSduSize;
100     unsigned int atmVccAal5RxSduSize;
101     int atmVccAal5Encap;
102     int atmVclRowStatus;
103     int atmVclCastType;
104     int atmVclConnKind;
105     struct list_head list;
106     int flags;
107}atmVclEntry;
108
109
110typedef union union_atmptrs {
111    struct atmIfConfEntry *atmIfConfEntry_ptr;
112    struct atmTrafficDescParamEntry *atmTrafficDescParamEntry_ptr;
113    struct atmVclEntry *atmVclEntry_ptr;
114}union_atmptrs;
115
116/* ATM Character device major number */
117#define ATM_MEI_MAJOR 107
118
119/* Protocol Constants */
120#define IFX_PROTO_RAW 0
121#define IFX_PROTO_BR2684 1
122#define IFX_PROTO_PPPOATM 2
123#define IFX_PROTO_CLIP 3
124
125/* IOCTL Command Set for ATM-MIB */
126#define GET_ATM_IF_CONF_DATA 0x0AB0
127#define SET_ATM_IF_CONF_DATA 0x0AB1
128
129#define SET_ATM_QOS_DATA 0x0BC0
130
131#define GET_ATM_VCL_DATA 0x0CD0
132#define SET_ATM_VCL_DATA 0x0CD1
133
134#define FIND_VCC_IN_KERNEL 0x0DE0
135
136/* User defined flags for VCL Table */
137#define ATMVCCAAL5CPCSTRANSMITSDUSIZE 9
138#define ATMVCCAAL5CPCSRECEIVESDUSIZE 10
139
140#endif /* CONFIG_IFX_ATM_MIB || IFX_CONFIG_SNMP_ATM_MIB */
141
142#endif //AMAZON_ATM_MIB_H
143

Archive Download this file



interactive