You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
net: netlink: virtual tap device management
Similarly to the networking receive path with ptype_all taps, we add the possibility to register netdevices that are for ARPHRD_NETLINK to the netlink subsystem, so that those can be used for netlink analyzers resp. debuggers. We do not offer a direct callback function as out-of-tree modules could do crap with it. Instead, a netdevice must be registered properly and only receives a clone, managed by the netlink layer. Symbols are exported as GPL-only. Signed-off-by: Daniel Borkmann <dborkman@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
77e2af0312
commit
bcbde0d449
@@ -145,4 +145,14 @@ static inline int netlink_dump_start(struct sock *ssk, struct sk_buff *skb,
|
||||
return __netlink_dump_start(ssk, skb, nlh, control);
|
||||
}
|
||||
|
||||
struct netlink_tap {
|
||||
struct net_device *dev;
|
||||
struct module *module;
|
||||
struct list_head list;
|
||||
};
|
||||
|
||||
extern int netlink_add_tap(struct netlink_tap *nt);
|
||||
extern int __netlink_remove_tap(struct netlink_tap *nt);
|
||||
extern int netlink_remove_tap(struct netlink_tap *nt);
|
||||
|
||||
#endif /* __LINUX_NETLINK_H */
|
||||
|
||||
Reference in New Issue
Block a user