patch-2.4.0-test3 linux/fs/coda/symlink.c

Next file: linux/fs/coda/upcall.c
Previous file: linux/fs/coda/psdev.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.0-test2/linux/fs/coda/symlink.c linux/fs/coda/symlink.c
@@ -14,6 +14,7 @@
 #include <linux/stat.h>
 #include <linux/errno.h>
 #include <linux/locks.h>
+#include <linux/smp_lock.h>
 
 #include <linux/coda.h>
 #include <linux/coda_linux.h>
@@ -30,10 +31,12 @@
 	unsigned int len = PAGE_SIZE;
 	char *p = (char*)kmap(page);
 
+	lock_kernel();
         cnp = ITOC(inode);
 	coda_vfs_stat.follow_link++;
 
 	error = venus_readlink(inode->i_sb, &(cnp->c_fid), p, &len);
+	unlock_kernel();
 	if (error)
 		goto fail;
 	SetPageUptodate(page);

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