chiark / gitweb /
sd-netlink: drop NETLINK_TYPE_META
[elogind.git] / src / libsystemd / sd-netlink / netlink-types.h
index 1bb1b21da948cfb93c8a9cf64c429268cdf31b35..d64229546417c568fb67499dc31707c018e6e88d 100644 (file)
@@ -23,7 +23,6 @@
 
 enum {
         NETLINK_TYPE_UNSPEC,
-        NETLINK_TYPE_META,
         NETLINK_TYPE_U8,                        /* NLA_U8 */
         NETLINK_TYPE_U16,                       /* NLA_U16 */
         NETLINK_TYPE_U32,                       /* NLA_U32 */
@@ -53,18 +52,12 @@ struct NLTypeSystemUnion {
         const NLTypeSystem *type_systems;
 };
 
-struct NLTypeSystem {
-        uint16_t max;
-        const NLType *types;
-};
-
-struct NLType {
-        uint16_t type;
-        size_t size;
-        const NLTypeSystem *type_system;
-        const NLTypeSystemUnion *type_system_union;
-};
+uint16_t type_get_type(const NLType *type);
+size_t type_get_size(const NLType *type);
+void type_get_type_system(const NLType *type, const NLTypeSystem **ret);
+void type_get_type_system_union(const NLType *type, const NLTypeSystemUnion **ret);
 
+uint16_t type_system_get_count(const NLTypeSystem *type_system);
 int type_system_get_type(const NLTypeSystem *type_system, const NLType **ret, uint16_t type);
 int type_system_get_type_system(const NLTypeSystem *type_system, const NLTypeSystem **ret, uint16_t type);
 int type_system_get_type_system_union(const NLTypeSystem *type_system, const NLTypeSystemUnion **ret, uint16_t type);