summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/netlink-local.h8
-rw-r--r--include/netlink/cache.h2
2 files changed, 2 insertions, 8 deletions
diff --git a/include/netlink-local.h b/include/netlink-local.h
index 2bfae3e..b891d8c 100644
--- a/include/netlink-local.h
+++ b/include/netlink-local.h
@@ -117,14 +117,6 @@ extern int __str2flags(const char *, const struct trans_tbl *, size_t);
extern void dump_from_ops(struct nl_object *, struct nl_dump_params *);
-static inline struct nl_cache *dp_cache(struct nl_object *obj)
-{
- if (obj->ce_cache == NULL)
- return nl_cache_mngt_require(obj->ce_ops->oo_name);
-
- return obj->ce_cache;
-}
-
static inline int nl_cb_call(struct nl_cb *cb, int type, struct nl_msg *msg)
{
return cb->cb_set[type](msg, cb->cb_args[type]);
diff --git a/include/netlink/cache.h b/include/netlink/cache.h
index f193c76..ac03842 100644
--- a/include/netlink/cache.h
+++ b/include/netlink/cache.h
@@ -52,6 +52,7 @@ extern struct nl_cache * nl_cache_clone(struct nl_cache *);
extern void nl_cache_clear(struct nl_cache *);
extern void nl_cache_get(struct nl_cache *);
extern void nl_cache_free(struct nl_cache *);
+extern void nl_cache_put(struct nl_cache *cache);
/* Cache modification */
extern int nl_cache_add(struct nl_cache *,
@@ -118,6 +119,7 @@ extern int nl_cache_mngt_unregister(struct nl_cache_ops *);
extern void nl_cache_mngt_provide(struct nl_cache *);
extern void nl_cache_mngt_unprovide(struct nl_cache *);
extern struct nl_cache * nl_cache_mngt_require(const char *);
+extern struct nl_cache * nl_cache_mngt_require_safe(const char *);
extern struct nl_cache * __nl_cache_mngt_require(const char *);
struct nl_cache_mngr;