diff options
-rw-r--r-- | net/ax25/sysctl_net_ax25.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/net/ax25/sysctl_net_ax25.c b/net/ax25/sysctl_net_ax25.c index f597987b2424..f288fc4aef9b 100644 --- a/net/ax25/sysctl_net_ax25.c +++ b/net/ax25/sysctl_net_ax25.c | |||
@@ -36,6 +36,7 @@ static struct ctl_path ax25_path[] = { | |||
36 | { .procname = "ax25", .ctl_name = NET_AX25, }, | 36 | { .procname = "ax25", .ctl_name = NET_AX25, }, |
37 | { } | 37 | { } |
38 | }; | 38 | }; |
39 | |||
39 | static const ctl_table ax25_param_table[] = { | 40 | static const ctl_table ax25_param_table[] = { |
40 | { | 41 | { |
41 | .ctl_name = NET_AX25_IP_DEFAULT_MODE, | 42 | .ctl_name = NET_AX25_IP_DEFAULT_MODE, |
@@ -167,6 +168,7 @@ static const ctl_table ax25_param_table[] = { | |||
167 | .extra1 = &min_proto, | 168 | .extra1 = &min_proto, |
168 | .extra2 = &max_proto | 169 | .extra2 = &max_proto |
169 | }, | 170 | }, |
171 | #ifdef CONFIG_AX25_DAMA_SLAVE | ||
170 | { | 172 | { |
171 | .ctl_name = NET_AX25_DAMA_SLAVE_TIMEOUT, | 173 | .ctl_name = NET_AX25_DAMA_SLAVE_TIMEOUT, |
172 | .procname = "dama_slave_timeout", | 174 | .procname = "dama_slave_timeout", |
@@ -177,6 +179,8 @@ static const ctl_table ax25_param_table[] = { | |||
177 | .extra1 = &min_ds_timeout, | 179 | .extra1 = &min_ds_timeout, |
178 | .extra2 = &max_ds_timeout | 180 | .extra2 = &max_ds_timeout |
179 | }, | 181 | }, |
182 | #endif | ||
183 | |||
180 | { .ctl_name = 0 } /* that's all, folks! */ | 184 | { .ctl_name = 0 } /* that's all, folks! */ |
181 | }; | 185 | }; |
182 | 186 | ||
@@ -210,16 +214,6 @@ void ax25_register_sysctl(void) | |||
210 | ax25_table[n].procname = ax25_dev->dev->name; | 214 | ax25_table[n].procname = ax25_dev->dev->name; |
211 | ax25_table[n].mode = 0555; | 215 | ax25_table[n].mode = 0555; |
212 | 216 | ||
213 | #ifndef CONFIG_AX25_DAMA_SLAVE | ||
214 | /* | ||
215 | * We do not wish to have a representation of this parameter | ||
216 | * in /proc/sys/ when configured *not* to include the | ||
217 | * AX.25 DAMA slave code, do we? | ||
218 | */ | ||
219 | |||
220 | child[AX25_VALUES_DS_TIMEOUT].procname = NULL; | ||
221 | #endif | ||
222 | |||
223 | child[AX25_MAX_VALUES].ctl_name = 0; /* just in case... */ | 217 | child[AX25_MAX_VALUES].ctl_name = 0; /* just in case... */ |
224 | 218 | ||
225 | for (k = 0; k < AX25_MAX_VALUES; k++) | 219 | for (k = 0; k < AX25_MAX_VALUES; k++) |