blob: 6655bf993d9c21aae92945b2279c59e3b8104861 [file] [log] [blame]
Ben Cheng655a7c02013-10-16 16:09:24 -07001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 *** To edit the content of this header, modify the corresponding
11 *** source file (e.g. under external/kernel-headers/original/) then
12 *** run bionic/libc/kernel/tools/update_all.py
13 ***
14 *** Any manual change here will be lost the next time this script will
15 *** be run. You've been warned!
16 ***
17 ****************************************************************************
18 ****************************************************************************/
19#ifndef X25_KERNEL_H
20#define X25_KERNEL_H
21#include <linux/types.h>
22#include <linux/socket.h>
Ben Cheng655a7c02013-10-16 16:09:24 -070023#define SIOCX25GSUBSCRIP (SIOCPROTOPRIVATE + 0)
24#define SIOCX25SSUBSCRIP (SIOCPROTOPRIVATE + 1)
25#define SIOCX25GFACILITIES (SIOCPROTOPRIVATE + 2)
26#define SIOCX25SFACILITIES (SIOCPROTOPRIVATE + 3)
Ben Cheng655a7c02013-10-16 16:09:24 -070027#define SIOCX25GCALLUSERDATA (SIOCPROTOPRIVATE + 4)
28#define SIOCX25SCALLUSERDATA (SIOCPROTOPRIVATE + 5)
29#define SIOCX25GCAUSEDIAG (SIOCPROTOPRIVATE + 6)
30#define SIOCX25SCUDMATCHLEN (SIOCPROTOPRIVATE + 7)
Ben Cheng655a7c02013-10-16 16:09:24 -070031#define SIOCX25CALLACCPTAPPRV (SIOCPROTOPRIVATE + 8)
32#define SIOCX25SENDCALLACCPT (SIOCPROTOPRIVATE + 9)
33#define SIOCX25GDTEFACILITIES (SIOCPROTOPRIVATE + 10)
34#define SIOCX25SDTEFACILITIES (SIOCPROTOPRIVATE + 11)
Ben Cheng655a7c02013-10-16 16:09:24 -070035#define SIOCX25SCAUSEDIAG (SIOCPROTOPRIVATE + 12)
36#define X25_QBITINCL 1
37#define X25_PS16 4
38#define X25_PS32 5
Ben Cheng655a7c02013-10-16 16:09:24 -070039#define X25_PS64 6
40#define X25_PS128 7
41#define X25_PS256 8
42#define X25_PS512 9
Ben Cheng655a7c02013-10-16 16:09:24 -070043#define X25_PS1024 10
44#define X25_PS2048 11
45#define X25_PS4096 12
46struct x25_address {
Tao Baod7db5942015-01-28 10:07:51 -080047 char x25_addr[16];
Ben Cheng655a7c02013-10-16 16:09:24 -070048};
49struct sockaddr_x25 {
Tao Baod7db5942015-01-28 10:07:51 -080050 __kernel_sa_family_t sx25_family;
Tao Baod7db5942015-01-28 10:07:51 -080051 struct x25_address sx25_addr;
Ben Cheng655a7c02013-10-16 16:09:24 -070052};
53struct x25_subscrip_struct {
Tao Baod7db5942015-01-28 10:07:51 -080054 char device[200 - sizeof(unsigned long)];
Tao Baod7db5942015-01-28 10:07:51 -080055 unsigned long global_facil_mask;
56 unsigned int extended;
Ben Cheng655a7c02013-10-16 16:09:24 -070057};
58#define X25_MASK_REVERSE 0x01
Ben Cheng655a7c02013-10-16 16:09:24 -070059#define X25_MASK_THROUGHPUT 0x02
60#define X25_MASK_PACKET_SIZE 0x04
61#define X25_MASK_WINDOW_SIZE 0x08
62#define X25_MASK_CALLING_AE 0x10
Ben Cheng655a7c02013-10-16 16:09:24 -070063#define X25_MASK_CALLED_AE 0x20
64struct x25_route_struct {
Tao Baod7db5942015-01-28 10:07:51 -080065 struct x25_address address;
66 unsigned int sigdigits;
Tao Baod7db5942015-01-28 10:07:51 -080067 char device[200];
Ben Cheng655a7c02013-10-16 16:09:24 -070068};
69struct x25_facilities {
Tao Baod7db5942015-01-28 10:07:51 -080070 unsigned int winsize_in, winsize_out;
Tao Baod7db5942015-01-28 10:07:51 -080071 unsigned int pacsize_in, pacsize_out;
72 unsigned int throughput;
73 unsigned int reverse;
Ben Cheng655a7c02013-10-16 16:09:24 -070074};
Ben Cheng655a7c02013-10-16 16:09:24 -070075struct x25_dte_facilities {
Tao Baod7db5942015-01-28 10:07:51 -080076 __u16 delay_cumul;
77 __u16 delay_target;
78 __u16 delay_max;
Tao Baod7db5942015-01-28 10:07:51 -080079 __u8 min_throughput;
80 __u8 expedited;
81 __u8 calling_len;
82 __u8 called_len;
Tao Baod7db5942015-01-28 10:07:51 -080083 __u8 calling_ae[20];
84 __u8 called_ae[20];
Ben Cheng655a7c02013-10-16 16:09:24 -070085};
86struct x25_calluserdata {
Tao Baod7db5942015-01-28 10:07:51 -080087 unsigned int cudlength;
88 unsigned char cuddata[128];
Ben Cheng655a7c02013-10-16 16:09:24 -070089};
90struct x25_causediag {
Tao Baod7db5942015-01-28 10:07:51 -080091 unsigned char cause;
92 unsigned char diagnostic;
Ben Cheng655a7c02013-10-16 16:09:24 -070093};
94struct x25_subaddr {
Tao Baod7db5942015-01-28 10:07:51 -080095 unsigned int cudmatchlength;
Ben Cheng655a7c02013-10-16 16:09:24 -070096};
97#endif