blob: 0f863319507e3152e5046a4d31ba3824a67281e4 [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 _UAPI__LINUX_GENERIC_NETLINK_H
20#define _UAPI__LINUX_GENERIC_NETLINK_H
21#include <linux/types.h>
22#include <linux/netlink.h>
Ben Cheng655a7c02013-10-16 16:09:24 -070023#define GENL_NAMSIZ 16
24#define GENL_MIN_ID NLMSG_MIN_TYPE
25#define GENL_MAX_ID 1023
26struct genlmsghdr {
Tao Baod7db5942015-01-28 10:07:51 -080027 __u8 cmd;
28 __u8 version;
29 __u16 reserved;
Ben Cheng655a7c02013-10-16 16:09:24 -070030};
Ben Cheng655a7c02013-10-16 16:09:24 -070031#define GENL_HDRLEN NLMSG_ALIGN(sizeof(struct genlmsghdr))
32#define GENL_ADMIN_PERM 0x01
33#define GENL_CMD_CAP_DO 0x02
34#define GENL_CMD_CAP_DUMP 0x04
Ben Cheng655a7c02013-10-16 16:09:24 -070035#define GENL_CMD_CAP_HASPOL 0x08
Christopher Ferris106b3a82016-08-24 12:15:38 -070036#define GENL_UNS_ADMIN_PERM 0x10
Ben Cheng655a7c02013-10-16 16:09:24 -070037#define GENL_ID_CTRL NLMSG_MIN_TYPE
Christopher Ferris106b3a82016-08-24 12:15:38 -070038#define GENL_ID_VFS_DQUOT (NLMSG_MIN_TYPE + 1)
Christopher Ferris38062f92014-07-09 15:33:25 -070039#define GENL_ID_PMCRAID (NLMSG_MIN_TYPE + 2)
Christopher Ferris48af7cb2017-02-21 12:35:09 -080040#define GENL_START_ALLOC (NLMSG_MIN_TYPE + 3)
Christopher Ferris38062f92014-07-09 15:33:25 -070041enum {
Tao Baod7db5942015-01-28 10:07:51 -080042 CTRL_CMD_UNSPEC,
Christopher Ferris106b3a82016-08-24 12:15:38 -070043 CTRL_CMD_NEWFAMILY,
Tao Baod7db5942015-01-28 10:07:51 -080044 CTRL_CMD_DELFAMILY,
45 CTRL_CMD_GETFAMILY,
46 CTRL_CMD_NEWOPS,
Christopher Ferris106b3a82016-08-24 12:15:38 -070047 CTRL_CMD_DELOPS,
Tao Baod7db5942015-01-28 10:07:51 -080048 CTRL_CMD_GETOPS,
49 CTRL_CMD_NEWMCAST_GRP,
50 CTRL_CMD_DELMCAST_GRP,
Christopher Ferris106b3a82016-08-24 12:15:38 -070051 CTRL_CMD_GETMCAST_GRP,
Christopher Ferris8177cdf2020-08-03 11:53:55 -070052 CTRL_CMD_GETPOLICY,
Tao Baod7db5942015-01-28 10:07:51 -080053 __CTRL_CMD_MAX,
Ben Cheng655a7c02013-10-16 16:09:24 -070054};
Ben Cheng655a7c02013-10-16 16:09:24 -070055#define CTRL_CMD_MAX (__CTRL_CMD_MAX - 1)
Christopher Ferris106b3a82016-08-24 12:15:38 -070056enum {
Tao Baod7db5942015-01-28 10:07:51 -080057 CTRL_ATTR_UNSPEC,
58 CTRL_ATTR_FAMILY_ID,
59 CTRL_ATTR_FAMILY_NAME,
Christopher Ferris106b3a82016-08-24 12:15:38 -070060 CTRL_ATTR_VERSION,
Tao Baod7db5942015-01-28 10:07:51 -080061 CTRL_ATTR_HDRSIZE,
62 CTRL_ATTR_MAXATTR,
63 CTRL_ATTR_OPS,
Christopher Ferris106b3a82016-08-24 12:15:38 -070064 CTRL_ATTR_MCAST_GROUPS,
Christopher Ferris8177cdf2020-08-03 11:53:55 -070065 CTRL_ATTR_POLICY,
Christopher Ferris32ff3f82020-12-14 13:10:04 -080066 CTRL_ATTR_OP_POLICY,
67 CTRL_ATTR_OP,
Tao Baod7db5942015-01-28 10:07:51 -080068 __CTRL_ATTR_MAX,
Ben Cheng655a7c02013-10-16 16:09:24 -070069};
Ben Cheng655a7c02013-10-16 16:09:24 -070070#define CTRL_ATTR_MAX (__CTRL_ATTR_MAX - 1)
Christopher Ferris106b3a82016-08-24 12:15:38 -070071enum {
Tao Baod7db5942015-01-28 10:07:51 -080072 CTRL_ATTR_OP_UNSPEC,
73 CTRL_ATTR_OP_ID,
74 CTRL_ATTR_OP_FLAGS,
Christopher Ferris106b3a82016-08-24 12:15:38 -070075 __CTRL_ATTR_OP_MAX,
Ben Cheng655a7c02013-10-16 16:09:24 -070076};
77#define CTRL_ATTR_OP_MAX (__CTRL_ATTR_OP_MAX - 1)
Ben Cheng655a7c02013-10-16 16:09:24 -070078enum {
Christopher Ferris106b3a82016-08-24 12:15:38 -070079 CTRL_ATTR_MCAST_GRP_UNSPEC,
Tao Baod7db5942015-01-28 10:07:51 -080080 CTRL_ATTR_MCAST_GRP_NAME,
81 CTRL_ATTR_MCAST_GRP_ID,
82 __CTRL_ATTR_MCAST_GRP_MAX,
Christopher Ferris106b3a82016-08-24 12:15:38 -070083};
Christopher Ferris7447a1c2022-10-04 18:24:44 -070084#define CTRL_ATTR_MCAST_GRP_MAX (__CTRL_ATTR_MCAST_GRP_MAX - 1)
Christopher Ferris32ff3f82020-12-14 13:10:04 -080085enum {
86 CTRL_ATTR_POLICY_UNSPEC,
87 CTRL_ATTR_POLICY_DO,
88 CTRL_ATTR_POLICY_DUMP,
89 __CTRL_ATTR_POLICY_DUMP_MAX,
90 CTRL_ATTR_POLICY_DUMP_MAX = __CTRL_ATTR_POLICY_DUMP_MAX - 1
91};
Christopher Ferris7447a1c2022-10-04 18:24:44 -070092#define CTRL_ATTR_POLICY_MAX (__CTRL_ATTR_POLICY_DUMP_MAX - 1)
Ben Cheng655a7c02013-10-16 16:09:24 -070093#endif