[PATCH] ipw2100: Fix setting txpower failed problem
[linux-2.6/mini2440.git] / include / linux / x25.h
blob16d44931afa04b84b6d5e87a5fdd191474af1cb9
1 /*
2 * These are the public elements of the Linux kernel X.25 implementation.
4 * History
5 * mar/20/00 Daniela Squassoni Disabling/enabling of facilities
6 * negotiation.
7 * apr/02/05 Shaun Pereira Selective sub address matching with
8 * call user data
9 */
11 #ifndef X25_KERNEL_H
12 #define X25_KERNEL_H
14 #define SIOCX25GSUBSCRIP (SIOCPROTOPRIVATE + 0)
15 #define SIOCX25SSUBSCRIP (SIOCPROTOPRIVATE + 1)
16 #define SIOCX25GFACILITIES (SIOCPROTOPRIVATE + 2)
17 #define SIOCX25SFACILITIES (SIOCPROTOPRIVATE + 3)
18 #define SIOCX25GCALLUSERDATA (SIOCPROTOPRIVATE + 4)
19 #define SIOCX25SCALLUSERDATA (SIOCPROTOPRIVATE + 5)
20 #define SIOCX25GCAUSEDIAG (SIOCPROTOPRIVATE + 6)
21 #define SIOCX25SCUDMATCHLEN (SIOCPROTOPRIVATE + 7)
22 #define SIOCX25CALLACCPTAPPRV (SIOCPROTOPRIVATE + 8)
23 #define SIOCX25SENDCALLACCPT (SIOCPROTOPRIVATE + 9)
26 * Values for {get,set}sockopt.
28 #define X25_QBITINCL 1
31 * X.25 Packet Size values.
33 #define X25_PS16 4
34 #define X25_PS32 5
35 #define X25_PS64 6
36 #define X25_PS128 7
37 #define X25_PS256 8
38 #define X25_PS512 9
39 #define X25_PS1024 10
40 #define X25_PS2048 11
41 #define X25_PS4096 12
44 * An X.121 address, it is held as ASCII text, null terminated, up to 15
45 * digits and a null terminator.
47 struct x25_address {
48 char x25_addr[16];
52 * Linux X.25 Address structure, used for bind, and connect mostly.
54 struct sockaddr_x25 {
55 sa_family_t sx25_family; /* Must be AF_X25 */
56 struct x25_address sx25_addr; /* X.121 Address */
60 * DTE/DCE subscription options.
62 * As this is missing lots of options, user should expect major
63 * changes of this structure in 2.5.x which might break compatibilty.
64 * The somewhat ugly dimension 200-sizeof() is needed to maintain
65 * backward compatibility.
67 struct x25_subscrip_struct {
68 char device[200-sizeof(unsigned long)];
69 unsigned long global_facil_mask; /* 0 to disable negotiation */
70 unsigned int extended;
73 /* values for above global_facil_mask */
75 #define X25_MASK_REVERSE 0x01
76 #define X25_MASK_THROUGHPUT 0x02
77 #define X25_MASK_PACKET_SIZE 0x04
78 #define X25_MASK_WINDOW_SIZE 0x08
83 * Routing table control structure.
85 struct x25_route_struct {
86 struct x25_address address;
87 unsigned int sigdigits;
88 char device[200];
92 * Facilities structure.
94 struct x25_facilities {
95 unsigned int winsize_in, winsize_out;
96 unsigned int pacsize_in, pacsize_out;
97 unsigned int throughput;
98 unsigned int reverse;
102 * Call User Data structure.
104 struct x25_calluserdata {
105 unsigned int cudlength;
106 unsigned char cuddata[128];
110 * Call clearing Cause and Diagnostic structure.
112 struct x25_causediag {
113 unsigned char cause;
114 unsigned char diagnostic;
118 * Further optional call user data match length selection
120 struct x25_subaddr {
121 unsigned int cudmatchlength;
124 #endif