hc
2024-10-22 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5
kernel/net/802/psnap.c
....@@ -1,14 +1,10 @@
1
+// SPDX-License-Identifier: GPL-2.0-or-later
12 /*
23 * SNAP data link layer. Derived from 802.2
34 *
45 * Alan Cox <alan@lxorguk.ukuu.org.uk>,
56 * from the 802.2 layer by Greg Page.
67 * Merged in additions from Greg Page's psnap.c.
7
- *
8
- * This program is free software; you can redistribute it and/or
9
- * modify it under the terms of the GNU General Public License
10
- * as published by the Free Software Foundation; either version
11
- * 2 of the License, or (at your option) any later version.
128 */
139
1410 #include <linux/module.h>
....@@ -34,7 +30,7 @@
3430 {
3531 struct datalink_proto *proto = NULL, *p;
3632
37
- list_for_each_entry_rcu(p, &snap_list, node) {
33
+ list_for_each_entry_rcu(p, &snap_list, node, lockdep_is_held(&snap_lock)) {
3834 if (!memcmp(p->type, desc, 5)) {
3935 proto = p;
4036 break;