patch-2.4.0-test6 linux/arch/sparc64/kernel/sys_sunos32.c
Next file: linux/arch/sparc64/kernel/traps.c
Previous file: linux/arch/sparc64/kernel/sys_sparc32.c
Back to the patch index
Back to the overall index
- Lines: 116
- Date:
Fri Aug 4 18:16:11 2000
- Orig file:
v2.4.0-test5/linux/arch/sparc64/kernel/sys_sunos32.c
- Orig date:
Fri Jul 14 12:12:08 2000
diff -u --recursive --new-file v2.4.0-test5/linux/arch/sparc64/kernel/sys_sunos32.c linux/arch/sparc64/kernel/sys_sunos32.c
@@ -1,4 +1,4 @@
-/* $Id: sys_sunos32.c,v 1.52 2000/07/10 20:57:35 davem Exp $
+/* $Id: sys_sunos32.c,v 1.53 2000/07/30 23:12:24 davem Exp $
* sys_sunos32.c: SunOS binary compatability layer on sparc64.
*
* Copyright (C) 1995, 1996, 1997 David S. Miller (davem@caip.rutgers.edu)
@@ -179,21 +179,18 @@
int error, oldbrk;
/* This should do it hopefully... */
- lock_kernel();
oldbrk = (int)current->mm->brk;
error = sunos_brk(((int) current->mm->brk) + increment);
if(!error)
error = oldbrk;
- unlock_kernel();
return error;
}
asmlinkage u32 sunos_sstk(int increment)
{
- lock_kernel();
printk("%s: Call to sunos_sstk(increment<%d>) is unsupported\n",
current->comm, increment);
- unlock_kernel();
+
return (u32)-1;
}
@@ -213,12 +210,13 @@
asmlinkage void sunos_vadvise(u32 strategy)
{
+ static int count = 0;
+
/* I wanna see who uses this... */
- lock_kernel();
- printk("%s: Advises us to use %s paging strategy\n",
- current->comm,
- strategy <= 3 ? vstrings[strategy] : "BOGUS");
- unlock_kernel();
+ if (count++ < 5)
+ printk("%s: Advises us to use %s paging strategy\n",
+ current->comm,
+ strategy <= 3 ? vstrings[strategy] : "BOGUS");
}
/* This just wants the soft limit (ie. rlim_cur element) of the RLIMIT_NOFILE
@@ -457,7 +455,6 @@
siginfo_t info;
static int cnt;
- lock_kernel();
regs = current->thread.kregs;
info.si_signo = SIGSYS;
info.si_errno = 0;
@@ -470,7 +467,6 @@
(int) regs->u_regs[UREG_G1]);
show_regs(regs);
}
- unlock_kernel();
return -ENOSYS;
}
@@ -726,7 +722,7 @@
if (!capable (CAP_SYS_ADMIN))
return -EPERM;
- lock_kernel();
+
/* We don't handle the integer fs type */
if ((flags & SMNT_NEWTYPE) == 0)
goto out;
@@ -772,7 +768,9 @@
ret = PTR_ERR(dev_fname);
if (IS_ERR(dev_fname))
goto out2;
+ lock_kernel();
ret = do_mount(dev_fname, dir_page, type_page, linux_flags, NULL);
+ unlock_kernel();
if (dev_fname)
putname(dev_fname);
out2:
@@ -780,7 +778,6 @@
out1:
putname(dir_page);
out:
- unlock_kernel();
return ret;
}
@@ -818,12 +815,7 @@
extern int kill_pg(int, int, int);
asmlinkage int sunos_killpg(int pgrp, int sig)
{
- int ret;
-
- lock_kernel();
- ret = kill_pg(pgrp, sig, 0);
- unlock_kernel();
- return ret;
+ return kill_pg(pgrp, sig, 0);
}
asmlinkage int sunos_audit(void)
@@ -836,9 +828,8 @@
{
u32 ret;
- lock_kernel();
ret = (((u32)idprom->id_machtype << 24) | ((u32)idprom->id_sernum));
- unlock_kernel();
+
return ret;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)