android_kernel_oneplus_msm8998/include/uapi/linux/sockev.h
Harout Hedeshian 274f3cfdd0 net: sockev: Initial Commit
Added module which subscribes to socket notifier events. Notifier events
are then converted to a multicast netlink message for user space
applications to consume.

CRs-Fixed:  626021
Change-Id: Id5c6808d972b69f5f065d7fba9094e75c6ad0b2c
Signed-off-by: Harout Hedeshian <harouth@codeaurora.org>
[subashab@codeaurora.org: resolve trivial merge conflicts]
Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
2016-03-22 11:09:38 -07:00

31 lines
724 B
C

#ifndef _SOCKEV_H_
#define _SOCKEV_H_
#include <linux/types.h>
#include <linux/netlink.h>
#include <linux/socket.h>
enum sknetlink_groups {
SKNLGRP_UNICAST,
SKNLGRP_SOCKEV,
__SKNLGRP_MAX
};
#define SOCKEV_STR_MAX 32
/********************************************************************
* Socket operation messages
****/
struct sknlsockevmsg {
__u8 event[SOCKEV_STR_MAX];
__u32 pid; /* (struct task_struct*)->pid */
__u16 skfamily; /* (struct socket*)->sk->sk_family */
__u8 skstate; /* (struct socket*)->sk->sk_state */
__u8 skprotocol; /* (struct socket*)->sk->sk_protocol */
__u16 sktype; /* (struct socket*)->sk->sk_type */
__u64 skflags; /* (struct socket*)->sk->sk_flags */
};
#endif /* _SOCKEV_H_ */