patch-2.4.21 linux-2.4.21/arch/alpha/kernel/osf_sys.c

Next file: linux-2.4.21/arch/alpha/kernel/pci.c
Previous file: linux-2.4.21/arch/alpha/kernel/machvec_impl.h
Back to the patch index
Back to the overall index

diff -urN linux-2.4.20/arch/alpha/kernel/osf_sys.c linux-2.4.21/arch/alpha/kernel/osf_sys.c
@@ -462,13 +462,8 @@
 
 asmlinkage int osf_swapon(const char *path, int flags, int lowat, int hiwat)
 {
-	int ret;
-
 	/* for now, simply ignore lowat and hiwat... */
-	lock_kernel();
-	ret = sys_swapon(path, flags);
-	unlock_kernel();
-	return ret;
+	return sys_swapon(path, flags);
 }
 
 asmlinkage unsigned long sys_getpagesize(void)
@@ -529,18 +524,13 @@
 	unsigned long raddr;
 	long err;
 
-	lock_kernel();
 	err = sys_shmat(shmid, shmaddr, shmflg, &raddr);
-	if (err)
-		goto out;
+
 	/*
 	 * This works because all user-level addresses are
 	 * non-negative longs!
 	 */
-	err = raddr;
-out:
-	unlock_kernel();
-	return err;
+	return err ? err : (long)raddr;
 }
 
 

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