Merge tag 'sched_ext-for-6.12-rc1-fixes-1' of git://git.kernel.org/pub/scm/linux...
[linux-block.git] / fs / coda / sysctl.c
CommitLineData
b2441318 1// SPDX-License-Identifier: GPL-2.0
1da177e4
LT
2/*
3 * Sysctl operations for Coda filesystem
4 * Original version: (C) 1996 P. Braam and M. Callahan
5 * Rewritten for Linux 2.1. (C) 1997 Carnegie Mellon University
6 *
7 * Carnegie Mellon encourages users to contribute improvements to
8 * the Coda project. Contact Peter Braam (coda@cs.cmu.edu).
1da177e4
LT
9 */
10
1da177e4 11#include <linux/sysctl.h>
1da177e4 12
3cf01f28 13#include "coda_int.h"
1da177e4
LT
14
15static struct ctl_table_header *fs_table_header;
16
a88bbbee 17static struct ctl_table coda_table[] = {
fd6065b4 18 {
fd6065b4
EB
19 .procname = "timeout",
20 .data = &coda_timeout,
21 .maxlen = sizeof(int),
22 .mode = 0644,
6d456111 23 .proc_handler = proc_dointvec
fd6065b4
EB
24 },
25 {
fd6065b4
EB
26 .procname = "hard",
27 .data = &coda_hard,
28 .maxlen = sizeof(int),
29 .mode = 0644,
6d456111 30 .proc_handler = proc_dointvec
fd6065b4 31 },
fd6065b4 32 {
fd6065b4
EB
33 .procname = "fake_statfs",
34 .data = &coda_fake_statfs,
35 .maxlen = sizeof(int),
36 .mode = 0600,
6d456111 37 .proc_handler = proc_dointvec
fd6065b4 38 },
1da177e4
LT
39};
40
1da177e4
LT
41void coda_sysctl_init(void)
42{
1da177e4 43 if ( !fs_table_header )
1119aaa8 44 fs_table_header = register_sysctl("coda", coda_table);
1da177e4
LT
45}
46
3cf01f28 47void coda_sysctl_clean(void)
1da177e4 48{
1da177e4
LT
49 if ( fs_table_header ) {
50 unregister_sysctl_table(fs_table_header);
51 fs_table_header = NULL;
52 }
1da177e4 53}