[PATCH net-next 3/3] net: drop unused LLC-related includes
flat view
COLD17d
IN NET-NEXT
From: Jakub Kicinski <kuba@kernel.org>
Date: 2026-09-28 19:08:09
Also in:
linux-mips, loongarch
Subsystem:
ethernet bridge, llc (802.2), networking [general], openvswitch, the rest · Maintainers:
Nikolay Aleksandrov, Ido Schimmel, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Aaron Conole, Eelco Chaudron, Ilya Maximets, Linus Torvalds
Queued in net-next as 0b934eb6b142 on 2026-10-01.
The bridge and the openvswitch code include <net/llc.h>, <net/llc_pdu.h> and <linux/llc.h> without using anything out of them. parse_ethertype() is the one exception: it wants LLC_SAP_SNAP, which comes from the uAPI header <linux/llc.h> pulls in, so flow.c keeps that one. The LLC core has leftovers of its own - slab, string, interrupt and net_namespace - which it has not used in a long time. None of this is new, the type 2 removal has just shrunk the LLC headers enough to make it easy to see. Signed-off-by: Jakub Kicinski <kuba@kernel.org> --- net/bridge/br.c | 2 -- net/llc/llc_core.c | 3 --- net/llc/llc_input.c | 2 -- net/openvswitch/flow.c | 1 - net/openvswitch/flow_netlink.c | 2 -- net/openvswitch/flow_table.c | 2 -- net/openvswitch/vport-netdev.c | 1 - 7 files changed, 13 deletions(-)
diff --git a/net/bridge/br.c b/net/bridge/br.c
index 09a120b3b76c..c602d6305997 100644
--- a/net/bridge/br.c
+++ b/net/bridge/br.c@@ -12,8 +12,6 @@ #include <linux/netdevice.h> #include <linux/etherdevice.h> #include <linux/init.h> -#include <linux/llc.h> -#include <net/llc.h> #include <net/stp.h> #include <net/switchdev.h>
diff --git a/net/llc/llc_core.c b/net/llc/llc_core.c
index cde6a0b1509e..eafc57ac903d 100644
--- a/net/llc/llc_core.c
+++ b/net/llc/llc_core.c@@ -7,13 +7,10 @@ */ #include <linux/module.h> -#include <linux/interrupt.h> #include <linux/if_ether.h> #include <linux/netdevice.h> #include <linux/slab.h> -#include <linux/string.h> #include <linux/init.h> -#include <net/net_namespace.h> #include <net/llc.h> static LIST_HEAD(llc_sap_list);
diff --git a/net/llc/llc_input.c b/net/llc/llc_input.c
index a8730c54b5c2..6bb4275a8518 100644
--- a/net/llc/llc_input.c
+++ b/net/llc/llc_input.c@@ -6,8 +6,6 @@ * 2001-2003 by Arnaldo Carvalho de Melo <acme@conectiva.com.br> */ #include <linux/netdevice.h> -#include <linux/slab.h> -#include <net/net_namespace.h> #include <net/llc.h> #include <net/llc_pdu.h>
diff --git a/net/openvswitch/flow.c b/net/openvswitch/flow.c
index 868d9fdf3afd..1c4f3a079044 100644
--- a/net/openvswitch/flow.c
+++ b/net/openvswitch/flow.c@@ -8,7 +8,6 @@ #include <linux/etherdevice.h> #include <linux/if_ether.h> #include <linux/if_vlan.h> -#include <net/llc_pdu.h> #include <linux/kernel.h> #include <linux/jhash.h> #include <linux/jiffies.h>
diff --git a/net/openvswitch/flow_netlink.c b/net/openvswitch/flow_netlink.c
index d8079dee700e..de0053f701b3 100644
--- a/net/openvswitch/flow_netlink.c
+++ b/net/openvswitch/flow_netlink.c@@ -12,11 +12,9 @@ #include <linux/etherdevice.h> #include <linux/if_ether.h> #include <linux/if_vlan.h> -#include <net/llc_pdu.h> #include <linux/kernel.h> #include <linux/jhash.h> #include <linux/jiffies.h> -#include <linux/llc.h> #include <linux/module.h> #include <linux/in.h> #include <linux/rcupdate.h>
diff --git a/net/openvswitch/flow_table.c b/net/openvswitch/flow_table.c
index 1e0f9d193eb0..93d36f66e2ac 100644
--- a/net/openvswitch/flow_table.c
+++ b/net/openvswitch/flow_table.c@@ -11,11 +11,9 @@ #include <linux/etherdevice.h> #include <linux/if_ether.h> #include <linux/if_vlan.h> -#include <net/llc_pdu.h> #include <linux/kernel.h> #include <linux/jhash.h> #include <linux/jiffies.h> -#include <linux/llc.h> #include <linux/module.h> #include <linux/in.h> #include <linux/rcupdate.h>
diff --git a/net/openvswitch/vport-netdev.c b/net/openvswitch/vport-netdev.c
index 44808cd0fcff..7daea2e44dfa 100644
--- a/net/openvswitch/vport-netdev.c
+++ b/net/openvswitch/vport-netdev.c@@ -9,7 +9,6 @@ #include <linux/if_bridge.h> #include <linux/if_vlan.h> #include <linux/kernel.h> -#include <linux/llc.h> #include <linux/rtnetlink.h> #include <linux/skbuff.h> #include <linux/openvswitch.h>
--
2.55.0