blob: 1d7ef4a834e91129dd6886dc6cadd273189346a9 [file] [log] [blame]
Elliott Hughes180edef2023-11-02 00:08:05 +00001/*
2 * This file is auto-generated. Modifications will be lost.
3 *
4 * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/
5 * for more information.
6 */
Ben Cheng655a7c02013-10-16 16:09:24 -07007#ifndef __PACKET_DIAG_H__
8#define __PACKET_DIAG_H__
9#include <linux/types.h>
10struct packet_diag_req {
Tao Baod7db5942015-01-28 10:07:51 -080011 __u8 sdiag_family;
12 __u8 sdiag_protocol;
13 __u16 pad;
14 __u32 pdiag_ino;
Tao Baod7db5942015-01-28 10:07:51 -080015 __u32 pdiag_show;
16 __u32 pdiag_cookie[2];
Ben Cheng655a7c02013-10-16 16:09:24 -070017};
18#define PACKET_SHOW_INFO 0x00000001
Ben Cheng655a7c02013-10-16 16:09:24 -070019#define PACKET_SHOW_MCLIST 0x00000002
20#define PACKET_SHOW_RING_CFG 0x00000004
21#define PACKET_SHOW_FANOUT 0x00000008
22#define PACKET_SHOW_MEMINFO 0x00000010
Ben Cheng655a7c02013-10-16 16:09:24 -070023#define PACKET_SHOW_FILTER 0x00000020
24struct packet_diag_msg {
Tao Baod7db5942015-01-28 10:07:51 -080025 __u8 pdiag_family;
26 __u8 pdiag_type;
Tao Baod7db5942015-01-28 10:07:51 -080027 __u16 pdiag_num;
28 __u32 pdiag_ino;
29 __u32 pdiag_cookie[2];
Ben Cheng655a7c02013-10-16 16:09:24 -070030};
Ben Cheng655a7c02013-10-16 16:09:24 -070031enum {
Tao Baod7db5942015-01-28 10:07:51 -080032 PACKET_DIAG_INFO,
33 PACKET_DIAG_MCLIST,
34 PACKET_DIAG_RX_RING,
Tao Baod7db5942015-01-28 10:07:51 -080035 PACKET_DIAG_TX_RING,
36 PACKET_DIAG_FANOUT,
37 PACKET_DIAG_UID,
38 PACKET_DIAG_MEMINFO,
Tao Baod7db5942015-01-28 10:07:51 -080039 PACKET_DIAG_FILTER,
40 __PACKET_DIAG_MAX,
Ben Cheng655a7c02013-10-16 16:09:24 -070041};
42#define PACKET_DIAG_MAX (__PACKET_DIAG_MAX - 1)
Ben Cheng655a7c02013-10-16 16:09:24 -070043struct packet_diag_info {
Tao Baod7db5942015-01-28 10:07:51 -080044 __u32 pdi_index;
45 __u32 pdi_version;
46 __u32 pdi_reserve;
Tao Baod7db5942015-01-28 10:07:51 -080047 __u32 pdi_copy_thresh;
48 __u32 pdi_tstamp;
49 __u32 pdi_flags;
Ben Cheng655a7c02013-10-16 16:09:24 -070050#define PDI_RUNNING 0x1
Ben Cheng655a7c02013-10-16 16:09:24 -070051#define PDI_AUXDATA 0x2
52#define PDI_ORIGDEV 0x4
53#define PDI_VNETHDR 0x8
54#define PDI_LOSS 0x10
Ben Cheng655a7c02013-10-16 16:09:24 -070055};
56struct packet_diag_mclist {
Tao Baod7db5942015-01-28 10:07:51 -080057 __u32 pdmc_index;
58 __u32 pdmc_count;
Tao Baod7db5942015-01-28 10:07:51 -080059 __u16 pdmc_type;
60 __u16 pdmc_alen;
Christopher Ferris525ce912017-07-26 13:12:53 -070061 __u8 pdmc_addr[32];
Ben Cheng655a7c02013-10-16 16:09:24 -070062};
Ben Cheng655a7c02013-10-16 16:09:24 -070063struct packet_diag_ring {
Tao Baod7db5942015-01-28 10:07:51 -080064 __u32 pdr_block_size;
65 __u32 pdr_block_nr;
66 __u32 pdr_frame_size;
Tao Baod7db5942015-01-28 10:07:51 -080067 __u32 pdr_frame_nr;
68 __u32 pdr_retire_tmo;
69 __u32 pdr_sizeof_priv;
70 __u32 pdr_features;
Ben Cheng655a7c02013-10-16 16:09:24 -070071};
72#endif