Commit f429cd37 authored by Eric W. Biederman's avatar Eric W. Biederman Committed by Linus Torvalds

sysctl: properly register the irda binary sysctl numbers

Grumble.  These numbers should have been in sysctl.h from the beginning if we
ever expected anyone to use them.  Oh well put them there now so we can find
them and make maintenance easier.
Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
Acked-by: default avatarSamuel Ortiz <samuel@sortiz.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent c65f9239
...@@ -238,6 +238,7 @@ enum ...@@ -238,6 +238,7 @@ enum
NET_LLC=18, NET_LLC=18,
NET_NETFILTER=19, NET_NETFILTER=19,
NET_DCCP=20, NET_DCCP=20,
NET_IRDA=412,
}; };
/* /proc/sys/kernel/random */ /* /proc/sys/kernel/random */
...@@ -795,6 +796,25 @@ enum { ...@@ -795,6 +796,25 @@ enum {
NET_BRIDGE_NF_FILTER_PPPOE_TAGGED = 5, NET_BRIDGE_NF_FILTER_PPPOE_TAGGED = 5,
}; };
/* proc/sys/net/irda */
enum {
NET_IRDA_DISCOVERY=1,
NET_IRDA_DEVNAME=2,
NET_IRDA_DEBUG=3,
NET_IRDA_FAST_POLL=4,
NET_IRDA_DISCOVERY_SLOTS=5,
NET_IRDA_DISCOVERY_TIMEOUT=6,
NET_IRDA_SLOT_TIMEOUT=7,
NET_IRDA_MAX_BAUD_RATE=8,
NET_IRDA_MIN_TX_TURN_TIME=9,
NET_IRDA_MAX_TX_DATA_SIZE=10,
NET_IRDA_MAX_TX_WINDOW=11,
NET_IRDA_MAX_NOREPLY_TIME=12,
NET_IRDA_WARN_NOREPLY_TIME=13,
NET_IRDA_LAP_KEEPALIVE_TIME=14,
};
/* CTL_FS names: */ /* CTL_FS names: */
enum enum
{ {
......
...@@ -31,12 +31,6 @@ ...@@ -31,12 +31,6 @@
#include <net/irda/irda.h> /* irda_debug */ #include <net/irda/irda.h> /* irda_debug */
#include <net/irda/irias_object.h> #include <net/irda/irias_object.h>
#define NET_IRDA 412 /* Random number */
enum { DISCOVERY=1, DEVNAME, DEBUG, FAST_POLL, DISCOVERY_SLOTS,
DISCOVERY_TIMEOUT, SLOT_TIMEOUT, MAX_BAUD_RATE, MIN_TX_TURN_TIME,
MAX_TX_DATA_SIZE, MAX_TX_WINDOW, MAX_NOREPLY_TIME, WARN_NOREPLY_TIME,
LAP_KEEPALIVE_TIME };
extern int sysctl_discovery; extern int sysctl_discovery;
extern int sysctl_discovery_slots; extern int sysctl_discovery_slots;
extern int sysctl_discovery_timeout; extern int sysctl_discovery_timeout;
...@@ -94,7 +88,7 @@ static int do_devname(ctl_table *table, int write, struct file *filp, ...@@ -94,7 +88,7 @@ static int do_devname(ctl_table *table, int write, struct file *filp,
/* One file */ /* One file */
static ctl_table irda_table[] = { static ctl_table irda_table[] = {
{ {
.ctl_name = DISCOVERY, .ctl_name = NET_IRDA_DISCOVERY,
.procname = "discovery", .procname = "discovery",
.data = &sysctl_discovery, .data = &sysctl_discovery,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -102,7 +96,7 @@ static ctl_table irda_table[] = { ...@@ -102,7 +96,7 @@ static ctl_table irda_table[] = {
.proc_handler = &proc_dointvec .proc_handler = &proc_dointvec
}, },
{ {
.ctl_name = DEVNAME, .ctl_name = NET_IRDA_DEVNAME,
.procname = "devname", .procname = "devname",
.data = sysctl_devname, .data = sysctl_devname,
.maxlen = 65, .maxlen = 65,
...@@ -112,7 +106,7 @@ static ctl_table irda_table[] = { ...@@ -112,7 +106,7 @@ static ctl_table irda_table[] = {
}, },
#ifdef CONFIG_IRDA_DEBUG #ifdef CONFIG_IRDA_DEBUG
{ {
.ctl_name = DEBUG, .ctl_name = NET_IRDA_DEBUG,
.procname = "debug", .procname = "debug",
.data = &irda_debug, .data = &irda_debug,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -122,7 +116,7 @@ static ctl_table irda_table[] = { ...@@ -122,7 +116,7 @@ static ctl_table irda_table[] = {
#endif #endif
#ifdef CONFIG_IRDA_FAST_RR #ifdef CONFIG_IRDA_FAST_RR
{ {
.ctl_name = FAST_POLL, .ctl_name = NET_IRDA_FAST_POLL,
.procname = "fast_poll_increase", .procname = "fast_poll_increase",
.data = &sysctl_fast_poll_increase, .data = &sysctl_fast_poll_increase,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -131,7 +125,7 @@ static ctl_table irda_table[] = { ...@@ -131,7 +125,7 @@ static ctl_table irda_table[] = {
}, },
#endif #endif
{ {
.ctl_name = DISCOVERY_SLOTS, .ctl_name = NET_IRDA_DISCOVERY_SLOTS,
.procname = "discovery_slots", .procname = "discovery_slots",
.data = &sysctl_discovery_slots, .data = &sysctl_discovery_slots,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -142,7 +136,7 @@ static ctl_table irda_table[] = { ...@@ -142,7 +136,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_discovery_slots .extra2 = &max_discovery_slots
}, },
{ {
.ctl_name = DISCOVERY_TIMEOUT, .ctl_name = NET_IRDA_DISCOVERY_TIMEOUT,
.procname = "discovery_timeout", .procname = "discovery_timeout",
.data = &sysctl_discovery_timeout, .data = &sysctl_discovery_timeout,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -150,7 +144,7 @@ static ctl_table irda_table[] = { ...@@ -150,7 +144,7 @@ static ctl_table irda_table[] = {
.proc_handler = &proc_dointvec .proc_handler = &proc_dointvec
}, },
{ {
.ctl_name = SLOT_TIMEOUT, .ctl_name = NET_IRDA_SLOT_TIMEOUT,
.procname = "slot_timeout", .procname = "slot_timeout",
.data = &sysctl_slot_timeout, .data = &sysctl_slot_timeout,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -161,7 +155,7 @@ static ctl_table irda_table[] = { ...@@ -161,7 +155,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_slot_timeout .extra2 = &max_slot_timeout
}, },
{ {
.ctl_name = MAX_BAUD_RATE, .ctl_name = NET_IRDA_MAX_BAUD_RATE,
.procname = "max_baud_rate", .procname = "max_baud_rate",
.data = &sysctl_max_baud_rate, .data = &sysctl_max_baud_rate,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -172,7 +166,7 @@ static ctl_table irda_table[] = { ...@@ -172,7 +166,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_max_baud_rate .extra2 = &max_max_baud_rate
}, },
{ {
.ctl_name = MIN_TX_TURN_TIME, .ctl_name = NET_IRDA_MIN_TX_TURN_TIME,
.procname = "min_tx_turn_time", .procname = "min_tx_turn_time",
.data = &sysctl_min_tx_turn_time, .data = &sysctl_min_tx_turn_time,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -183,7 +177,7 @@ static ctl_table irda_table[] = { ...@@ -183,7 +177,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_min_tx_turn_time .extra2 = &max_min_tx_turn_time
}, },
{ {
.ctl_name = MAX_TX_DATA_SIZE, .ctl_name = NET_IRDA_MAX_TX_DATA_SIZE,
.procname = "max_tx_data_size", .procname = "max_tx_data_size",
.data = &sysctl_max_tx_data_size, .data = &sysctl_max_tx_data_size,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -194,7 +188,7 @@ static ctl_table irda_table[] = { ...@@ -194,7 +188,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_max_tx_data_size .extra2 = &max_max_tx_data_size
}, },
{ {
.ctl_name = MAX_TX_WINDOW, .ctl_name = NET_IRDA_MAX_TX_WINDOW,
.procname = "max_tx_window", .procname = "max_tx_window",
.data = &sysctl_max_tx_window, .data = &sysctl_max_tx_window,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -205,7 +199,7 @@ static ctl_table irda_table[] = { ...@@ -205,7 +199,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_max_tx_window .extra2 = &max_max_tx_window
}, },
{ {
.ctl_name = MAX_NOREPLY_TIME, .ctl_name = NET_IRDA_MAX_NOREPLY_TIME,
.procname = "max_noreply_time", .procname = "max_noreply_time",
.data = &sysctl_max_noreply_time, .data = &sysctl_max_noreply_time,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -216,7 +210,7 @@ static ctl_table irda_table[] = { ...@@ -216,7 +210,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_max_noreply_time .extra2 = &max_max_noreply_time
}, },
{ {
.ctl_name = WARN_NOREPLY_TIME, .ctl_name = NET_IRDA_WARN_NOREPLY_TIME,
.procname = "warn_noreply_time", .procname = "warn_noreply_time",
.data = &sysctl_warn_noreply_time, .data = &sysctl_warn_noreply_time,
.maxlen = sizeof(int), .maxlen = sizeof(int),
...@@ -227,7 +221,7 @@ static ctl_table irda_table[] = { ...@@ -227,7 +221,7 @@ static ctl_table irda_table[] = {
.extra2 = &max_warn_noreply_time .extra2 = &max_warn_noreply_time
}, },
{ {
.ctl_name = LAP_KEEPALIVE_TIME, .ctl_name = NET_IRDA_LAP_KEEPALIVE_TIME,
.procname = "lap_keepalive_time", .procname = "lap_keepalive_time",
.data = &sysctl_lap_keepalive_time, .data = &sysctl_lap_keepalive_time,
.maxlen = sizeof(int), .maxlen = sizeof(int),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment