Merge branch 'topic/omap3isp' of git://git.kernel.org/pub/scm/linux/kernel/git/mcheha...
[linux-2.6-block.git] / include / uapi / linux / packet_diag.h
CommitLineData
96ec6327
PE
1#ifndef __PACKET_DIAG_H__
2#define __PACKET_DIAG_H__
3
4#include <linux/types.h>
5
6struct packet_diag_req {
7 __u8 sdiag_family;
8 __u8 sdiag_protocol;
9 __u16 pad;
10 __u32 pdiag_ino;
11 __u32 pdiag_show;
12 __u32 pdiag_cookie[2];
13};
14
8a360be0 15#define PACKET_SHOW_INFO 0x00000001 /* Basic packet_sk information */
eea68e2f 16#define PACKET_SHOW_MCLIST 0x00000002 /* A set of packet_diag_mclist-s */
16f01365 17#define PACKET_SHOW_RING_CFG 0x00000004 /* Rings configuration parameters */
fff3321d 18#define PACKET_SHOW_FANOUT 0x00000008
76d0eeb1 19#define PACKET_SHOW_MEMINFO 0x00000010
e8d9612c 20#define PACKET_SHOW_FILTER 0x00000020
8a360be0 21
96ec6327
PE
22struct packet_diag_msg {
23 __u8 pdiag_family;
24 __u8 pdiag_type;
25 __u16 pdiag_num;
26
27 __u32 pdiag_ino;
28 __u32 pdiag_cookie[2];
29};
30
8a360be0 31enum {
31e20bad 32 /* PACKET_DIAG_NONE, standard nl API requires this attribute! */
8a360be0 33 PACKET_DIAG_INFO,
eea68e2f 34 PACKET_DIAG_MCLIST,
16f01365
PE
35 PACKET_DIAG_RX_RING,
36 PACKET_DIAG_TX_RING,
fff3321d 37 PACKET_DIAG_FANOUT,
62641903 38 PACKET_DIAG_UID,
76d0eeb1 39 PACKET_DIAG_MEMINFO,
e8d9612c 40 PACKET_DIAG_FILTER,
8a360be0 41
ae5fc987 42 __PACKET_DIAG_MAX,
8a360be0
PE
43};
44
ae5fc987
AV
45#define PACKET_DIAG_MAX (__PACKET_DIAG_MAX - 1)
46
8a360be0
PE
47struct packet_diag_info {
48 __u32 pdi_index;
49 __u32 pdi_version;
50 __u32 pdi_reserve;
51 __u32 pdi_copy_thresh;
52 __u32 pdi_tstamp;
53 __u32 pdi_flags;
54
55#define PDI_RUNNING 0x1
56#define PDI_AUXDATA 0x2
57#define PDI_ORIGDEV 0x4
58#define PDI_VNETHDR 0x8
59#define PDI_LOSS 0x10
60};
61
eea68e2f
PE
62struct packet_diag_mclist {
63 __u32 pdmc_index;
64 __u32 pdmc_count;
65 __u16 pdmc_type;
66 __u16 pdmc_alen;
67 __u8 pdmc_addr[MAX_ADDR_LEN];
68};
69
16f01365
PE
70struct packet_diag_ring {
71 __u32 pdr_block_size;
72 __u32 pdr_block_nr;
73 __u32 pdr_frame_size;
74 __u32 pdr_frame_nr;
75 __u32 pdr_retire_tmo;
76 __u32 pdr_sizeof_priv;
77 __u32 pdr_features;
78};
79
96ec6327 80#endif