hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/fs/dlm/netlink.c
....@@ -1,9 +1,6 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Copyright (C) 2007 Red Hat, Inc. All rights reserved.
3
- *
4
- * This copyrighted material is made available to anyone wishing to use,
5
- * modify, copy, or redistribute it subject to the terms and conditions
6
- * of the GNU General Public License v.2.
74 */
85
96 #include <net/genetlink.h>
....@@ -65,9 +62,10 @@
6562 return 0;
6663 }
6764
68
-static const struct genl_ops dlm_nl_ops[] = {
65
+static const struct genl_small_ops dlm_nl_ops[] = {
6966 {
7067 .cmd = DLM_CMD_HELLO,
68
+ .validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
7169 .doit = user_cmd,
7270 },
7371 };
....@@ -75,8 +73,8 @@
7573 static struct genl_family family __ro_after_init = {
7674 .name = DLM_GENL_NAME,
7775 .version = DLM_GENL_VERSION,
78
- .ops = dlm_nl_ops,
79
- .n_ops = ARRAY_SIZE(dlm_nl_ops),
76
+ .small_ops = dlm_nl_ops,
77
+ .n_small_ops = ARRAY_SIZE(dlm_nl_ops),
8078 .module = THIS_MODULE,
8179 };
8280
....@@ -115,7 +113,7 @@
115113
116114 void dlm_timeout_warn(struct dlm_lkb *lkb)
117115 {
118
- struct sk_buff *uninitialized_var(send_skb);
116
+ struct sk_buff *send_skb;
119117 struct dlm_lock_data *data;
120118 size_t size;
121119 int rv;