summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Graf <tgraf@suug.ch>2010-11-11 15:38:53 (GMT)
committerThomas Graf <tgraf@suug.ch>2010-11-11 15:38:53 (GMT)
commit12b82e4f6f7eb52d249534b85f4634263567cd84 (patch)
treee8f10f30b63223f60bcee9c6f648ec48df4d182a
parent67aeb7474f3242bf9dc2e43b860643aa1da41a6e (diff)
downloadlibnl-12b82e4f6f7eb52d249534b85f4634263567cd84.zip
libnl-12b82e4f6f7eb52d249534b85f4634263567cd84.tar.gz
libnl-12b82e4f6f7eb52d249534b85f4634263567cd84.tar.bz2
link/api: Improve API documentation.
-rw-r--r--include/netlink/route/link/api.h13
-rw-r--r--lib/route/link/api.c18
-rw-r--r--lib/route/link/bridge.c10
-rw-r--r--lib/route/link/vlan.c2
4 files changed, 26 insertions, 17 deletions
diff --git a/include/netlink/route/link/api.h b/include/netlink/route/link/api.h
index 42c00d9..8222e23 100644
--- a/include/netlink/route/link/api.h
+++ b/include/netlink/route/link/api.h
@@ -19,16 +19,16 @@ extern "C" {
#endif
/**
- * @ingroup link_info
+ * @ingroup link_api
*
- * Link info operations
+ * Available operations to modules implementing a link info type.
*/
struct rtnl_link_info_ops
{
- /** Name of operations, must match name on kernel side */
+ /** Name of link info type, must match name on kernel side */
char * io_name;
- /** Reference count (internal, do not use) */
+ /** Reference count, DO NOT MODIFY */
int io_refcnt;
/** Called to assign an info type to a link.
@@ -69,6 +69,11 @@ extern int rtnl_link_register_info(struct rtnl_link_info_ops *);
extern int rtnl_link_unregister_info(struct rtnl_link_info_ops *);
+/**
+ * @ingroup link_api
+ *
+ * Available operations to modules implementing a link address family.
+ */
struct rtnl_link_af_ops
{
/** The address family this operations set implements */
diff --git a/lib/route/link/api.c b/lib/route/link/api.c
index 1830fe3..b1608e3 100644
--- a/lib/route/link/api.c
+++ b/lib/route/link/api.c
@@ -11,8 +11,8 @@
/**
* @ingroup link
- * @defgroup link_info Link Info API
- * @brief
+ * @defgroup link_API Link Modules API
+ * @brief API for modules implementing specific link types/semantics.
*
* @par 1) Registering/Unregistering a new link info type
* @code
@@ -59,6 +59,11 @@ static struct rtnl_link_info_ops *__rtnl_link_info_ops_lookup(const char *name)
}
/**
+ * @name Link Info Modules
+ * @{
+ */
+
+/**
* Return operations of a specific link info type
* @arg name Name of link info type.
*
@@ -147,6 +152,13 @@ int rtnl_link_unregister_info(struct rtnl_link_info_ops *ops)
return -NLE_OPNOTSUPP;
}
+/** @} */
+
+/**
+ * @name Link Address Family Modules
+ * @{
+ */
+
static struct rtnl_link_af_ops *af_ops[AF_MAX];
/**
@@ -242,3 +254,5 @@ int rtnl_link_af_unregister(struct rtnl_link_af_ops *ops)
/** @} */
+/** @} */
+
diff --git a/lib/route/link/bridge.c b/lib/route/link/bridge.c
index 4e4da58..32fd38f 100644
--- a/lib/route/link/bridge.c
+++ b/lib/route/link/bridge.c
@@ -9,14 +9,6 @@
* Copyright (c) 2010 Thomas Graf <tgraf@suug.ch>
*/
-/**
- * @ingroup link
- * @defgroup link_bridge Bridge Specifics
- * @brief
- *
- * @{
- */
-
#include <netlink-local.h>
#include <netlink/netlink.h>
#include <netlink/attr.h>
@@ -89,5 +81,3 @@ static void __exit bridge_exit(void)
{
rtnl_link_af_unregister(&bridge_ops);
}
-
-/** @} */
diff --git a/lib/route/link/vlan.c b/lib/route/link/vlan.c
index a76cb83..da3ae49 100644
--- a/lib/route/link/vlan.c
+++ b/lib/route/link/vlan.c
@@ -10,7 +10,7 @@
*/
/**
- * @ingroup link_info
+ * @ingroup link_api
* @defgroup vlan VLAN
* @brief
*