diff options
author | YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> | 2007-02-09 09:25:09 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-02-11 02:20:00 -0500 |
commit | 5f8f59d6641a3726985593f3e52430daa90c7933 (patch) | |
tree | 6f00c19b414285b3d5d494a383ea0b8e806d51d9 /net/netrom/af_netrom.c | |
parent | 746fac4dcd82864c6ecd85d3f09cc173db9b1870 (diff) |
[NET] NETROM: Fix whitespace errors.
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/netrom/af_netrom.c')
-rw-r--r-- | net/netrom/af_netrom.c | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c index 43bbe2c9e49a..799b76806bc3 100644 --- a/net/netrom/af_netrom.c +++ b/net/netrom/af_netrom.c | |||
@@ -110,7 +110,7 @@ static int nr_device_event(struct notifier_block *this, unsigned long event, voi | |||
110 | 110 | ||
111 | nr_kill_by_device(dev); | 111 | nr_kill_by_device(dev); |
112 | nr_rt_device_down(dev); | 112 | nr_rt_device_down(dev); |
113 | 113 | ||
114 | return NOTIFY_DONE; | 114 | return NOTIFY_DONE; |
115 | } | 115 | } |
116 | 116 | ||
@@ -137,7 +137,7 @@ static struct sock *nr_find_listener(ax25_address *addr) | |||
137 | sk_for_each(s, node, &nr_list) | 137 | sk_for_each(s, node, &nr_list) |
138 | if (!ax25cmp(&nr_sk(s)->source_addr, addr) && | 138 | if (!ax25cmp(&nr_sk(s)->source_addr, addr) && |
139 | s->sk_state == TCP_LISTEN) { | 139 | s->sk_state == TCP_LISTEN) { |
140 | bh_lock_sock(s); | 140 | bh_lock_sock(s); |
141 | goto found; | 141 | goto found; |
142 | } | 142 | } |
143 | s = NULL; | 143 | s = NULL; |
@@ -157,7 +157,7 @@ static struct sock *nr_find_socket(unsigned char index, unsigned char id) | |||
157 | spin_lock_bh(&nr_list_lock); | 157 | spin_lock_bh(&nr_list_lock); |
158 | sk_for_each(s, node, &nr_list) { | 158 | sk_for_each(s, node, &nr_list) { |
159 | struct nr_sock *nr = nr_sk(s); | 159 | struct nr_sock *nr = nr_sk(s); |
160 | 160 | ||
161 | if (nr->my_index == index && nr->my_id == id) { | 161 | if (nr->my_index == index && nr->my_id == id) { |
162 | bh_lock_sock(s); | 162 | bh_lock_sock(s); |
163 | goto found; | 163 | goto found; |
@@ -181,10 +181,10 @@ static struct sock *nr_find_peer(unsigned char index, unsigned char id, | |||
181 | spin_lock_bh(&nr_list_lock); | 181 | spin_lock_bh(&nr_list_lock); |
182 | sk_for_each(s, node, &nr_list) { | 182 | sk_for_each(s, node, &nr_list) { |
183 | struct nr_sock *nr = nr_sk(s); | 183 | struct nr_sock *nr = nr_sk(s); |
184 | 184 | ||
185 | if (nr->your_index == index && nr->your_id == id && | 185 | if (nr->your_index == index && nr->your_id == id && |
186 | !ax25cmp(&nr->dest_addr, dest)) { | 186 | !ax25cmp(&nr->dest_addr, dest)) { |
187 | bh_lock_sock(s); | 187 | bh_lock_sock(s); |
188 | goto found; | 188 | goto found; |
189 | } | 189 | } |
190 | } | 190 | } |
@@ -341,17 +341,17 @@ static int nr_getsockopt(struct socket *sock, int level, int optname, | |||
341 | struct sock *sk = sock->sk; | 341 | struct sock *sk = sock->sk; |
342 | struct nr_sock *nr = nr_sk(sk); | 342 | struct nr_sock *nr = nr_sk(sk); |
343 | int val = 0; | 343 | int val = 0; |
344 | int len; | 344 | int len; |
345 | 345 | ||
346 | if (level != SOL_NETROM) | 346 | if (level != SOL_NETROM) |
347 | return -ENOPROTOOPT; | 347 | return -ENOPROTOOPT; |
348 | 348 | ||
349 | if (get_user(len, optlen)) | 349 | if (get_user(len, optlen)) |
350 | return -EFAULT; | 350 | return -EFAULT; |
351 | 351 | ||
352 | if (len < 0) | 352 | if (len < 0) |
353 | return -EINVAL; | 353 | return -EINVAL; |
354 | 354 | ||
355 | switch (optname) { | 355 | switch (optname) { |
356 | case NETROM_T1: | 356 | case NETROM_T1: |
357 | val = nr->t1 / HZ; | 357 | val = nr->t1 / HZ; |
@@ -537,7 +537,7 @@ static int nr_release(struct socket *sock) | |||
537 | break; | 537 | break; |
538 | } | 538 | } |
539 | 539 | ||
540 | sock->sk = NULL; | 540 | sock->sk = NULL; |
541 | release_sock(sk); | 541 | release_sock(sk); |
542 | sock_put(sk); | 542 | sock_put(sk); |
543 | 543 | ||
@@ -644,7 +644,7 @@ static int nr_connect(struct socket *sock, struct sockaddr *uaddr, | |||
644 | return -EISCONN; /* No reconnect on a seqpacket socket */ | 644 | return -EISCONN; /* No reconnect on a seqpacket socket */ |
645 | } | 645 | } |
646 | 646 | ||
647 | sk->sk_state = TCP_CLOSE; | 647 | sk->sk_state = TCP_CLOSE; |
648 | sock->state = SS_UNCONNECTED; | 648 | sock->state = SS_UNCONNECTED; |
649 | 649 | ||
650 | if (addr_len != sizeof(struct sockaddr_ax25) && addr_len != sizeof(struct full_sockaddr_ax25)) { | 650 | if (addr_len != sizeof(struct sockaddr_ax25) && addr_len != sizeof(struct full_sockaddr_ax25)) { |
@@ -710,7 +710,7 @@ static int nr_connect(struct socket *sock, struct sockaddr *uaddr, | |||
710 | release_sock(sk); | 710 | release_sock(sk); |
711 | return -EINPROGRESS; | 711 | return -EINPROGRESS; |
712 | } | 712 | } |
713 | 713 | ||
714 | /* | 714 | /* |
715 | * A Connect Ack with Choke or timeout or failed routing will go to | 715 | * A Connect Ack with Choke or timeout or failed routing will go to |
716 | * closed. | 716 | * closed. |
@@ -848,7 +848,7 @@ static int nr_getname(struct socket *sock, struct sockaddr *uaddr, | |||
848 | int nr_rx_frame(struct sk_buff *skb, struct net_device *dev) | 848 | int nr_rx_frame(struct sk_buff *skb, struct net_device *dev) |
849 | { | 849 | { |
850 | struct sock *sk; | 850 | struct sock *sk; |
851 | struct sock *make; | 851 | struct sock *make; |
852 | struct nr_sock *nr_make; | 852 | struct nr_sock *nr_make; |
853 | ax25_address *src, *dest, *user; | 853 | ax25_address *src, *dest, *user; |
854 | unsigned short circuit_index, circuit_id; | 854 | unsigned short circuit_index, circuit_id; |
@@ -1258,10 +1258,10 @@ static void *nr_info_next(struct seq_file *seq, void *v, loff_t *pos) | |||
1258 | { | 1258 | { |
1259 | ++*pos; | 1259 | ++*pos; |
1260 | 1260 | ||
1261 | return (v == SEQ_START_TOKEN) ? sk_head(&nr_list) | 1261 | return (v == SEQ_START_TOKEN) ? sk_head(&nr_list) |
1262 | : sk_next((struct sock *)v); | 1262 | : sk_next((struct sock *)v); |
1263 | } | 1263 | } |
1264 | 1264 | ||
1265 | static void nr_info_stop(struct seq_file *seq, void *v) | 1265 | static void nr_info_stop(struct seq_file *seq, void *v) |
1266 | { | 1266 | { |
1267 | spin_unlock_bh(&nr_list_lock); | 1267 | spin_unlock_bh(&nr_list_lock); |
@@ -1291,7 +1291,7 @@ static int nr_info_show(struct seq_file *seq, void *v) | |||
1291 | 1291 | ||
1292 | seq_printf(seq, "%-9s ", ax2asc(buf, &nr->user_addr)); | 1292 | seq_printf(seq, "%-9s ", ax2asc(buf, &nr->user_addr)); |
1293 | seq_printf(seq, "%-9s ", ax2asc(buf, &nr->dest_addr)); | 1293 | seq_printf(seq, "%-9s ", ax2asc(buf, &nr->dest_addr)); |
1294 | seq_printf(seq, | 1294 | seq_printf(seq, |
1295 | "%-9s %-3s %02X/%02X %02X/%02X %2d %3d %3d %3d %3lu/%03lu %2lu/%02lu %3lu/%03lu %3lu/%03lu %2d/%02d %3d %5d %5d %ld\n", | 1295 | "%-9s %-3s %02X/%02X %02X/%02X %2d %3d %3d %3d %3lu/%03lu %2lu/%02lu %3lu/%03lu %3lu/%03lu %2d/%02d %3d %5d %5d %ld\n", |
1296 | ax2asc(buf, &nr->source_addr), | 1296 | ax2asc(buf, &nr->source_addr), |
1297 | devname, | 1297 | devname, |
@@ -1329,12 +1329,12 @@ static struct seq_operations nr_info_seqops = { | |||
1329 | .stop = nr_info_stop, | 1329 | .stop = nr_info_stop, |
1330 | .show = nr_info_show, | 1330 | .show = nr_info_show, |
1331 | }; | 1331 | }; |
1332 | 1332 | ||
1333 | static int nr_info_open(struct inode *inode, struct file *file) | 1333 | static int nr_info_open(struct inode *inode, struct file *file) |
1334 | { | 1334 | { |
1335 | return seq_open(file, &nr_info_seqops); | 1335 | return seq_open(file, &nr_info_seqops); |
1336 | } | 1336 | } |
1337 | 1337 | ||
1338 | static struct file_operations nr_info_fops = { | 1338 | static struct file_operations nr_info_fops = { |
1339 | .owner = THIS_MODULE, | 1339 | .owner = THIS_MODULE, |
1340 | .open = nr_info_open, | 1340 | .open = nr_info_open, |
@@ -1415,7 +1415,7 @@ static int __init nr_proto_init(void) | |||
1415 | printk(KERN_ERR "NET/ROM: nr_proto_init - unable to allocate device structure\n"); | 1415 | printk(KERN_ERR "NET/ROM: nr_proto_init - unable to allocate device structure\n"); |
1416 | goto fail; | 1416 | goto fail; |
1417 | } | 1417 | } |
1418 | 1418 | ||
1419 | dev->base_addr = i; | 1419 | dev->base_addr = i; |
1420 | if (register_netdev(dev)) { | 1420 | if (register_netdev(dev)) { |
1421 | printk(KERN_ERR "NET/ROM: nr_proto_init - unable to register network device\n"); | 1421 | printk(KERN_ERR "NET/ROM: nr_proto_init - unable to register network device\n"); |
@@ -1430,7 +1430,7 @@ static int __init nr_proto_init(void) | |||
1430 | printk(KERN_ERR "NET/ROM: nr_proto_init - unable to register socket family\n"); | 1430 | printk(KERN_ERR "NET/ROM: nr_proto_init - unable to register socket family\n"); |
1431 | goto fail; | 1431 | goto fail; |
1432 | } | 1432 | } |
1433 | 1433 | ||
1434 | register_netdevice_notifier(&nr_dev_notifier); | 1434 | register_netdevice_notifier(&nr_dev_notifier); |
1435 | 1435 | ||
1436 | ax25_register_pid(&nr_pid); | 1436 | ax25_register_pid(&nr_pid); |