patch-1.3.32 linux/fs/nfs/inode.c

Next file: linux/fs/nfs/rpcsock.c
Previous file: linux/fs/nfs/Makefile
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.31/linux/fs/nfs/inode.c linux/fs/nfs/inode.c
@@ -59,6 +59,7 @@
 void nfs_put_super(struct super_block *sb)
 {
 	close_fp(sb->u.nfs_sb.s_server.file);
+	rpc_closesock(sb->u.nfs_sb.s_server.rsock);
 	lock_super(sb);
 	sb->s_dev = 0;
 	unlock_super(sb);
@@ -162,6 +163,12 @@
 	  memcpy((char *)&(server->toaddr),(char *)(&data->addr),sizeof(server->toaddr));
 	}
 	/* End of JSP NFS patch */
+
+	if ((server->rsock = rpc_makesock(filp)) == NULL) {
+		printk("NFS: cannot create RPC socket.\n");
+		MOD_DEC_USE_COUNT;
+		return NULL;
+	}
 
 	sb->u.nfs_sb.s_root = data->root;
 	unlock_super(sb);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this