]> git.itanic.dy.fi Git - linux-stable/commitdiff
docs: bridge: Add kAPI/uAPI fields
authorHangbin Liu <liuhangbin@gmail.com>
Fri, 1 Dec 2023 08:19:44 +0000 (16:19 +0800)
committerPaolo Abeni <pabeni@redhat.com>
Tue, 5 Dec 2023 09:48:00 +0000 (10:48 +0100)
Add kAPI/uAPI field for bridge doc. Update struct net_bridge_vlan
comments to fix doc build warning.

Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: Hangbin Liu <liuhangbin@gmail.com>
Acked-by: Nikolay Aleksandrov <razor@blackwall.org>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Documentation/networking/bridge.rst
net/bridge/br_private.h

index 6ad8b42b2c50edb934635a580fca639ab552533b..a717563eaa157ac3f6e63dc309c82e1fbb86a680 100644 (file)
@@ -14,6 +14,39 @@ at the data link layer (Layer 2) of the OSI (Open Systems Interconnection)
 model. The purpose of a bridge is to filter and forward frames between
 different segments based on the destination MAC (Media Access Control) address.
 
+Bridge kAPI
+===========
+
+Here are some core structures of bridge code. Note that the kAPI is *unstable*,
+and can be changed at any time.
+
+.. kernel-doc:: net/bridge/br_private.h
+   :identifiers: net_bridge_vlan
+
+Bridge uAPI
+===========
+
+Modern Linux bridge uAPI is accessed via Netlink interface. You can find
+below files where the bridge and bridge port netlink attributes are defined.
+
+Bridge netlink attributes
+-------------------------
+
+.. kernel-doc:: include/uapi/linux/if_link.h
+   :doc: Bridge enum definition
+
+Bridge port netlink attributes
+------------------------------
+
+.. kernel-doc:: include/uapi/linux/if_link.h
+   :doc: Bridge port enum definition
+
+Bridge sysfs
+------------
+
+The sysfs interface is deprecated and should not be extended if new
+options are added.
+
 FAQ
 ===
 
index 6b7f36769d0327e912ca5b6d4c6b7877c07156b4..051ea81864ac38600683f65abebe6f8a44559225 100644 (file)
@@ -186,6 +186,7 @@ enum {
  * struct net_bridge_vlan - per-vlan entry
  *
  * @vnode: rhashtable member
+ * @tnode: rhashtable member
  * @vid: VLAN id
  * @flags: bridge vlan flags
  * @priv_flags: private (in-kernel) bridge vlan flags
@@ -196,6 +197,7 @@ enum {
  * @refcnt: if MASTER flag set, this is bumped for each port referencing it
  * @brvlan: if MASTER flag unset, this points to the global per-VLAN context
  *          for this VLAN entry
+ * @tinfo: bridge tunnel info
  * @br_mcast_ctx: if MASTER flag set, this is the global vlan multicast context
  * @port_mcast_ctx: if MASTER flag unset, this is the per-port/vlan multicast
  *                  context