13c8149a0f2eec2d1407aaca180b8ff0291a84595Dmitry V. Levin#ifndef STRACE_LINUX_INET_DIAG_H
23c8149a0f2eec2d1407aaca180b8ff0291a84595Dmitry V. Levin#define STRACE_LINUX_INET_DIAG_H
33c8149a0f2eec2d1407aaca180b8ff0291a84595Dmitry V. Levin
42f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin#define TCPDIAG_GETSOCK 18
52f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin#define DCCPDIAG_GETSOCK 19
62f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin
72f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin/* Socket identity */
82f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levinstruct inet_diag_sockid {
92f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint16_t idiag_sport;
102f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint16_t idiag_dport;
112f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_src[4];
122f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_dst[4];
132f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_if;
142f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_cookie[2];
152f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin};
162f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin
172f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin/* Request structure */
182f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levinstruct inet_diag_req_v2 {
192f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t sdiag_family;
202f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t sdiag_protocol;
212f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t idiag_ext;
222f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t pad;
232f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_states;
242f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	struct inet_diag_sockid id;
252f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin};
262f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin
272f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin/* Info structure */
282f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levinstruct inet_diag_msg {
292f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t idiag_family;
302f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t idiag_state;
312f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t idiag_timer;
322f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint8_t idiag_retrans;
332f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin
342f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	struct inet_diag_sockid id;
352f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin
362f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_expires;
372f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_rqueue;
382f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_wqueue;
392f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_uid;
402f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin	uint32_t idiag_inode;
412f6510c8a6a358ec00f56a491318181bc068a1fcDmitry V. Levin};
423c8149a0f2eec2d1407aaca180b8ff0291a84595Dmitry V. Levin
433c8149a0f2eec2d1407aaca180b8ff0291a84595Dmitry V. Levin#endif /* !STRACE_LINUX_INET_DIAG_H */
44