hc
2024-05-10 23fa18eaa71266feff7ba8d83022d9e1cc83c65a
kernel/include/linux/if_team.h
....@@ -1,11 +1,7 @@
1
+/* SPDX-License-Identifier: GPL-2.0-or-later */
12 /*
23 * include/linux/if_team.h - Network team device driver header
34 * Copyright (c) 2011 Jiri Pirko <jpirko@redhat.com>
4
- *
5
- * This program is free software; you can redistribute it and/or modify
6
- * it under the terms of the GNU General Public License as published by
7
- * the Free Software Foundation; either version 2 of the License, or
8
- * (at your option) any later version.
95 */
106 #ifndef _LINUX_IF_TEAM_H_
117 #define _LINUX_IF_TEAM_H_
....@@ -71,7 +67,7 @@
7167 u16 queue_id;
7268 struct list_head qom_list; /* node in queue override mapping list */
7369 struct rcu_head rcu;
74
- long mode_priv[0];
70
+ long mode_priv[];
7571 };
7672
7773 static inline struct team_port *team_port_get_rcu(const struct net_device *dev)
....@@ -106,10 +102,7 @@
106102 static inline void team_netpoll_send_skb(struct team_port *port,
107103 struct sk_buff *skb)
108104 {
109
- struct netpoll *np = port->np;
110
-
111
- if (np)
112
- netpoll_send_skb(np, skb);
105
+ netpoll_send_skb(port->np, skb);
113106 }
114107 #else
115108 static inline void team_netpoll_send_skb(struct team_port *port,
....@@ -196,6 +189,8 @@
196189 struct net_device *dev; /* associated netdevice */
197190 struct team_pcpu_stats __percpu *pcpu_stats;
198191
192
+ const struct header_ops *header_ops_cache;
193
+
199194 struct mutex lock; /* used for overall locking, e.g. port lists write */
200195
201196 /*
....@@ -215,6 +210,7 @@
215210 bool queue_override_enabled;
216211 struct list_head *qom_lists; /* array of queue override mapping lists */
217212 bool port_mtu_change_allowed;
213
+ bool notifier_ctx;
218214 struct {
219215 unsigned int count;
220216 unsigned int interval; /* in ms */
....@@ -227,6 +223,7 @@
227223 atomic_t count_pending;
228224 struct delayed_work dw;
229225 } mcast_rejoin;
226
+ struct lock_class_key team_lock_key;
230227 long mode_priv[TEAM_MODE_PRIV_LONGS];
231228 };
232229