Re: [PATCH net-next v2 01/13] net: Introduce struct ndo_fdb_parms

From
Petr Machata <petrm@nvidia.com>
Date
2026-12-01 18:12:56
Also in
bridge, linux-kselftest
Reply to
netdev-bot+sashiko@kernel.org, 2026-12-01
netdev-bot+sashiko@kernel.org writes:
quoted
+/**
+ * struct ndo_fdb_parms - parameters for ndo_fdb_{add,del,get}
+ * @dev: device the FDB entry is added to, deleted from or looked up on
+ * @addr: MAC address of the FDB entry
+ * @vid: VLAN ID of the FDB entry, 0 if none
+ * @flags: netlink message flags (NLM_F_*) of the request
+ */
[Severity: Low]
Does the @flags description match how the struct is filled in for del and
get?

The kernel-doc says the struct carries the parameters for all three
callbacks. It describes @flags as the NLM_F_* flags of the request,
without limiting that to add. Only rtnl_fdb_add() sets the field:
...
Could either .flags = nlh->nlmsg_flags be set in rtnl_fdb_del() and
rtnl_fdb_get(), or @flags be documented as valid only for ndo_fdb_add?
It could, but it seemed like overkill, which is why I didn't do it.
Thread (25 messages) 25 messages, 3 authors, last reply 1d ago
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help