Repository navigation
Expand file tree
/
Copy pathlinux-libc-headers-atm-vbr.patch
More file actions
75 lines (71 loc) · 3.18 KB
/
Copy pathlinux-libc-headers-atm-vbr.patch
File metadata and controls
75 lines (71 loc) · 3.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
--- linux-3.7/include/uapi/linux/atm.h.orig 2012-12-11 04:30:57.000000000 +0100
+++ linux-3.7/include/uapi/linux/atm.h 2012-12-12 21:23:41.327635859 +0100
@@ -70,7 +70,7 @@
/* connection identifier range; socket must be
bound or connected */
#define SO_ATMQOS __SO_ENCODE(SOL_ATM,2,struct atm_qos)
- /* Quality of Service setting */
+ /* Quality of Service setting (with vbr support) */
#define SO_ATMSAP __SO_ENCODE(SOL_ATM,3,struct atm_sap)
/* Service Access Point */
#define SO_ATMPVC __SO_ENCODE(SOL_ATM,4,struct sockaddr_atmpvc)
@@ -126,9 +126,11 @@
#define ATM_NONE 0 /* no traffic */
#define ATM_UBR 1
#define ATM_CBR 2
-#define ATM_VBR 3
+#define ATM_VBR_NRT 3
+#define ATM_VBR ATM_VBR_NRT /* for backward compatibility */
#define ATM_ABR 4
#define ATM_ANYCLASS 5 /* compatible with everything */
+#define ATM_VBR_RT 6
#define ATM_MAX_PCR -1 /* maximum available PCR */
@@ -139,6 +141,11 @@
int min_pcr; /* minimum PCR in cells per second */
int max_cdv; /* maximum CDV in microseconds */
int max_sdu; /* maximum SDU in bytes */
+
+ /* extra params for VBR */
+ int scr; /* sustained rate in cells per second */
+ int mbs; /* maximum burst size (MBS) in cells */
+
/* extra params for ABR */
unsigned int icr; /* Initial Cell Rate (24-bit) */
unsigned int tbe; /* Transient Buffer Exposure (24-bit) */
@@ -238,4 +245,38 @@
typedef unsigned short atm_backend_t;
+
+struct atm_trafprm_compat {
+ unsigned char traffic_class; /* traffic class (ATM_UBR, ...) */
+ int max_pcr; /* maximum PCR in cells per second */
+ int pcr; /* desired PCR in cells per second */
+ int min_pcr; /* minimum PCR in cells per second */
+ int max_cdv; /* maximum CDV in microseconds */
+ int max_sdu; /* maximum SDU in bytes */
+ /* extra params for ABR */
+ unsigned int icr; /* Initial Cell Rate (24-bit) */
+ unsigned int tbe; /* Transient Buffer Exposure (24-bit) */
+ unsigned int frtt : 24; /* Fixed Round Trip Time (24-bit) */
+ unsigned int rif : 4; /* Rate Increment Factor (4-bit) */
+ unsigned int rdf : 4; /* Rate Decrease Factor (4-bit) */
+ unsigned int nrm_pres :1; /* nrm present bit */
+ unsigned int trm_pres :1; /* rm present bit */
+ unsigned int adtf_pres :1; /* adtf present bit */
+ unsigned int cdf_pres :1; /* cdf present bit*/
+ unsigned int nrm :3; /* Max # of Cells for each forward RM cell (3-bit) */
+ unsigned int trm :3; /* Time between forward RM cells (3-bit) */
+ unsigned int adtf :10; /* ACR Decrease Time Factor (10-bit) */
+ unsigned int cdf :3; /* Cutoff Decrease Factor (3-bit) */
+ unsigned int spare :9; /* spare bits */
+};
+
+struct atm_qos_compat {
+ struct atm_trafprm_compat txtp; /* parameters in TX direction */
+ struct atm_trafprm_compat rxtp __ATM_API_ALIGN;
+ /* parameters in RX direction */
+ unsigned char aal __ATM_API_ALIGN;
+};
+
+#define SO_ATMQOS_COMPAT __SO_ENCODE(SOL_ATM,2,struct atm_qos_compat)
+ /* Quality of Service setting (no vbr support) */
#endif /* _UAPI_LINUX_ATM_H */