Skip to content

Commit 03860ef

Browse files
committed
ia64: simplify one-level sysctl registration for kdump_ctl_table
There is no need to declare an extra tables to just create directory, this can be easily be done with a prefix path with register_sysctl(). Simplify this registration. Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
1 parent 3d51cd8 commit 03860ef

File tree

1 file changed

+1
-10
lines changed

1 file changed

+1
-10
lines changed

arch/ia64/kernel/crash.c

+1-10
Original file line numberDiff line numberDiff line change
@@ -234,15 +234,6 @@ static struct ctl_table kdump_ctl_table[] = {
234234
},
235235
{ }
236236
};
237-
238-
static struct ctl_table sys_table[] = {
239-
{
240-
.procname = "kernel",
241-
.mode = 0555,
242-
.child = kdump_ctl_table,
243-
},
244-
{ }
245-
};
246237
#endif
247238

248239
static int
@@ -257,7 +248,7 @@ machine_crash_setup(void)
257248
if((ret = register_die_notifier(&kdump_init_notifier_nb)) != 0)
258249
return ret;
259250
#ifdef CONFIG_SYSCTL
260-
register_sysctl_table(sys_table);
251+
register_sysctl("kernel", kdump_ctl_table);
261252
#endif
262253
return 0;
263254
}

0 commit comments

Comments
 (0)