aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/udp.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@mandriva.com>2006-03-21 01:48:35 -0500
committerDavid S. Miller <davem@davemloft.net>2006-03-21 01:48:35 -0500
commit543d9cfeec4d58ad3fd974db5531b06b6b95deb4 (patch)
treeb5f79a92ec01b4a97f26d48cae11566498641822 /net/ipv4/udp.c
parentf94691acf9df35d5cd828373e35391bdc4a3fde6 (diff)
[NET]: Identation & other cleanups related to compat_[gs]etsockopt cset
No code changes, just tidying up, in some cases moving EXPORT_SYMBOLs to just after the function exported, etc. Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/udp.c')
-rw-r--r--net/ipv4/udp.c48
1 files changed, 23 insertions, 25 deletions
diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c
index 0b0721bd45c6..3f93292b0ad8 100644
--- a/net/ipv4/udp.c
+++ b/net/ipv4/udp.c
@@ -1263,11 +1263,10 @@ static int udp_setsockopt(struct sock *sk, int level, int optname,
1263 1263
1264#ifdef CONFIG_COMPAT 1264#ifdef CONFIG_COMPAT
1265static int compat_udp_setsockopt(struct sock *sk, int level, int optname, 1265static int compat_udp_setsockopt(struct sock *sk, int level, int optname,
1266 char __user *optval, int optlen) 1266 char __user *optval, int optlen)
1267{ 1267{
1268 if (level != SOL_UDP) 1268 if (level != SOL_UDP)
1269 return compat_ip_setsockopt(sk, level, 1269 return compat_ip_setsockopt(sk, level, optname, optval, optlen);
1270 optname, optval, optlen);
1271 return do_udp_setsockopt(sk, level, optname, optval, optlen); 1270 return do_udp_setsockopt(sk, level, optname, optval, optlen);
1272} 1271}
1273#endif 1272#endif
@@ -1316,11 +1315,10 @@ static int udp_getsockopt(struct sock *sk, int level, int optname,
1316 1315
1317#ifdef CONFIG_COMPAT 1316#ifdef CONFIG_COMPAT
1318static int compat_udp_getsockopt(struct sock *sk, int level, int optname, 1317static int compat_udp_getsockopt(struct sock *sk, int level, int optname,
1319 char __user *optval, int __user *optlen) 1318 char __user *optval, int __user *optlen)
1320{ 1319{
1321 if (level != SOL_UDP) 1320 if (level != SOL_UDP)
1322 return compat_ip_getsockopt(sk, level, 1321 return compat_ip_getsockopt(sk, level, optname, optval, optlen);
1323 optname, optval, optlen);
1324 return do_udp_getsockopt(sk, level, optname, optval, optlen); 1322 return do_udp_getsockopt(sk, level, optname, optval, optlen);
1325} 1323}
1326#endif 1324#endif
@@ -1372,27 +1370,27 @@ unsigned int udp_poll(struct file *file, struct socket *sock, poll_table *wait)
1372} 1370}
1373 1371
1374struct proto udp_prot = { 1372struct proto udp_prot = {
1375 .name = "UDP", 1373 .name = "UDP",
1376 .owner = THIS_MODULE, 1374 .owner = THIS_MODULE,
1377 .close = udp_close, 1375 .close = udp_close,
1378 .connect = ip4_datagram_connect, 1376 .connect = ip4_datagram_connect,
1379 .disconnect = udp_disconnect, 1377 .disconnect = udp_disconnect,
1380 .ioctl = udp_ioctl, 1378 .ioctl = udp_ioctl,
1381 .destroy = udp_destroy_sock, 1379 .destroy = udp_destroy_sock,
1382 .setsockopt = udp_setsockopt, 1380 .setsockopt = udp_setsockopt,
1383 .getsockopt = udp_getsockopt, 1381 .getsockopt = udp_getsockopt,
1382 .sendmsg = udp_sendmsg,
1383 .recvmsg = udp_recvmsg,
1384 .sendpage = udp_sendpage,
1385 .backlog_rcv = udp_queue_rcv_skb,
1386 .hash = udp_v4_hash,
1387 .unhash = udp_v4_unhash,
1388 .get_port = udp_v4_get_port,
1389 .obj_size = sizeof(struct udp_sock),
1384#ifdef CONFIG_COMPAT 1390#ifdef CONFIG_COMPAT
1385 .compat_setsockopt = compat_udp_setsockopt, 1391 .compat_setsockopt = compat_udp_setsockopt,
1386 .compat_getsockopt = compat_udp_getsockopt, 1392 .compat_getsockopt = compat_udp_getsockopt,
1387#endif 1393#endif
1388 .sendmsg = udp_sendmsg,
1389 .recvmsg = udp_recvmsg,
1390 .sendpage = udp_sendpage,
1391 .backlog_rcv = udp_queue_rcv_skb,
1392 .hash = udp_v4_hash,
1393 .unhash = udp_v4_unhash,
1394 .get_port = udp_v4_get_port,
1395 .obj_size = sizeof(struct udp_sock),
1396}; 1394};
1397 1395
1398/* ------------------------------------------------------------------------ */ 1396/* ------------------------------------------------------------------------ */