xref: /aosp_15_r20/external/libnl/include/netlink/genl/family.h (revision 4dc78e53d49367fa8e61b07018507c90983a077d)
1 /* SPDX-License-Identifier: LGPL-2.1-only */
2 /*
3  * Copyright (c) 2003-2012 Thomas Graf <[email protected]>
4  */
5 
6 #ifndef NETLINK_GENL_FAMILY_H_
7 #define NETLINK_GENL_FAMILY_H_
8 
9 #include <netlink/netlink.h>
10 #include <netlink/cache.h>
11 
12 #ifdef __cplusplus
13 extern "C" {
14 #endif
15 
16 struct genl_family;
17 
18 extern struct genl_family *	genl_family_alloc(void);
19 extern void			genl_family_put(struct genl_family *);
20 
21 extern unsigned int		genl_family_get_id(struct genl_family *);
22 extern void			genl_family_set_id(struct genl_family *, unsigned int);
23 extern char *			genl_family_get_name(struct genl_family *);
24 extern void			genl_family_set_name(struct genl_family *, const char *);
25 extern uint8_t			genl_family_get_version(struct genl_family *);
26 extern void			genl_family_set_version(struct genl_family *, uint8_t);
27 extern uint32_t			genl_family_get_hdrsize(struct genl_family *);
28 extern void			genl_family_set_hdrsize(struct genl_family *, uint32_t);
29 extern uint32_t			genl_family_get_maxattr(struct genl_family *);
30 extern void			genl_family_set_maxattr(struct genl_family *, uint32_t);
31 
32 extern int			genl_family_add_op(struct genl_family *, int, int);
33 extern int 			genl_family_add_grp(struct genl_family *, uint32_t ,
34 						    const char *);
35 
36 
37 #ifdef __cplusplus
38 }
39 #endif
40 
41 #endif
42