[SPARC64]: Fix section-mismatch errors in solaris emul module.
[linux-2.6/linux-acpi-2.6/ibm-acpi-2.6.git] / net / dccp / sysctl.c
blob38bc157876f3b29104b858b1d122193f31573cd3
1 /*
2 * net/dccp/sysctl.c
4 * An implementation of the DCCP protocol
5 * Arnaldo Carvalho de Melo <acme@mandriva.com>
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License v2
9 * as published by the Free Software Foundation.
12 #include <linux/mm.h>
13 #include <linux/sysctl.h>
14 #include "feat.h"
16 #ifndef CONFIG_SYSCTL
17 #error This file should not be compiled without CONFIG_SYSCTL defined
18 #endif
20 static struct ctl_table dccp_default_table[] = {
22 .ctl_name = NET_DCCP_DEFAULT_SEQ_WINDOW,
23 .procname = "seq_window",
24 .data = &dccp_feat_default_sequence_window,
25 .maxlen = sizeof(dccp_feat_default_sequence_window),
26 .mode = 0644,
27 .proc_handler = proc_dointvec,
30 .ctl_name = NET_DCCP_DEFAULT_RX_CCID,
31 .procname = "rx_ccid",
32 .data = &dccp_feat_default_rx_ccid,
33 .maxlen = sizeof(dccp_feat_default_rx_ccid),
34 .mode = 0644,
35 .proc_handler = proc_dointvec,
38 .ctl_name = NET_DCCP_DEFAULT_TX_CCID,
39 .procname = "tx_ccid",
40 .data = &dccp_feat_default_tx_ccid,
41 .maxlen = sizeof(dccp_feat_default_tx_ccid),
42 .mode = 0644,
43 .proc_handler = proc_dointvec,
46 .ctl_name = NET_DCCP_DEFAULT_ACK_RATIO,
47 .procname = "ack_ratio",
48 .data = &dccp_feat_default_ack_ratio,
49 .maxlen = sizeof(dccp_feat_default_ack_ratio),
50 .mode = 0644,
51 .proc_handler = proc_dointvec,
54 .ctl_name = NET_DCCP_DEFAULT_SEND_ACKVEC,
55 .procname = "send_ackvec",
56 .data = &dccp_feat_default_send_ack_vector,
57 .maxlen = sizeof(dccp_feat_default_send_ack_vector),
58 .mode = 0644,
59 .proc_handler = proc_dointvec,
62 .ctl_name = NET_DCCP_DEFAULT_SEND_NDP,
63 .procname = "send_ndp",
64 .data = &dccp_feat_default_send_ndp_count,
65 .maxlen = sizeof(dccp_feat_default_send_ndp_count),
66 .mode = 0644,
67 .proc_handler = proc_dointvec,
69 { .ctl_name = 0, }
72 static struct ctl_table dccp_table[] = {
74 .ctl_name = NET_DCCP_DEFAULT,
75 .procname = "default",
76 .mode = 0555,
77 .child = dccp_default_table,
79 { .ctl_name = 0, },
82 static struct ctl_table dccp_dir_table[] = {
84 .ctl_name = NET_DCCP,
85 .procname = "dccp",
86 .mode = 0555,
87 .child = dccp_table,
89 { .ctl_name = 0, },
92 static struct ctl_table dccp_root_table[] = {
94 .ctl_name = CTL_NET,
95 .procname = "net",
96 .mode = 0555,
97 .child = dccp_dir_table,
99 { .ctl_name = 0, },
102 static struct ctl_table_header *dccp_table_header;
104 int __init dccp_sysctl_init(void)
106 dccp_table_header = register_sysctl_table(dccp_root_table, 1);
108 return dccp_table_header != NULL ? 0 : -ENOMEM;
111 void dccp_sysctl_exit(void)
113 if (dccp_table_header != NULL) {
114 unregister_sysctl_table(dccp_table_header);
115 dccp_table_header = NULL;