Commit 9e1c1f90 authored by Ivan Kokshaysky's avatar Ivan Kokshaysky Committed by Richard Henderson

[PATCH] alpha osf_shmat lock

From Jeff.Wiedemeier@hp.com:

Remove redundant lock in osf_shmat (sys_shmat locks already);
redundant lock has been seen to cause livelock in some workloads.
parent cd7f3f67
...@@ -465,18 +465,13 @@ osf_shmat(int shmid, void *shmaddr, int shmflg) ...@@ -465,18 +465,13 @@ osf_shmat(int shmid, void *shmaddr, int shmflg)
unsigned long raddr; unsigned long raddr;
long err; long err;
lock_kernel();
err = sys_shmat(shmid, shmaddr, shmflg, &raddr); err = sys_shmat(shmid, shmaddr, shmflg, &raddr);
if (err)
goto out;
/* /*
* This works because all user-level addresses are * This works because all user-level addresses are
* non-negative longs! * non-negative longs!
*/ */
err = raddr; return err ? err : (long)raddr;
out:
unlock_kernel();
return err;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment