patch-2.3.15 linux/net/ipx/af_spx.c

Next file: linux/net/irda/af_irda.c
Previous file: linux/net/ipx/af_ipx.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.14/linux/net/ipx/af_spx.c linux/net/ipx/af_spx.c
@@ -36,10 +36,9 @@
 #include <asm/uaccess.h>
 #include <linux/uio.h>
 #include <linux/unistd.h>
-#include <linux/firewall.h>
 
 static struct proto_ops *ipx_operations;
-static struct proto_ops spx_operations;
+static struct proto_ops spx_ops;
 static __u16  connids;
 
 /* Functions needed for SPX connection start up */
@@ -96,7 +95,7 @@
 	switch(sock->type)
         {
                 case SOCK_SEQPACKET:
-			sock->ops = &spx_operations;
+			sock->ops = &spx_ops;
 			break;
 		default:
 			sk_free(sk);
@@ -149,7 +148,7 @@
 }
 
 /* Release an SPX socket */
-static int spx_release(struct socket *sock, struct socket *peer)
+static int spx_release(struct socket *sock)
 {
  	struct sock *sk = sock->sk;
 	struct spx_opt *pdata = &sk->tp_pinfo.af_spx;
@@ -208,10 +207,6 @@
         struct sk_buff *skb;
 	int err;
 
-	if(newsock->sk != NULL)
-		spx_destroy_socket(newsock->sk);
-        newsock->sk = NULL;
-
 	if(sock->sk == NULL)
 		return (-EINVAL);
 	sk = sock->sk;
@@ -847,9 +842,8 @@
 	return (err);
 }
 
-static struct proto_ops spx_operations = {
+static struct proto_ops SOCKOPS_WRAPPED(spx_ops) = {
         PF_IPX,
-        sock_no_dup,
         spx_release,
         spx_bind,
         spx_connect,
@@ -864,8 +858,13 @@
 	spx_getsockopt,
         sock_no_fcntl,
         spx_sendmsg,
-        spx_recvmsg
+        spx_recvmsg,
+	sock_no_mmap
 };
+
+#include <linux/smp_lock.h>
+SOCKOPS_WRAP(spx, PF_IPX);
+
 
 static struct net_proto_family spx_family_ops=
 {

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)