Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ipc/sem.c: update sem_otime for all operations
In commit 0a2b9d4 ("ipc/sem.c: move wake_up_process out of the spinlock section"), the update of semaphore's sem_otime(last semop time) was moved to one central position (do_smart_update). But since do_smart_update() is only called for operations that modify the array, this means that wait-for-zero semops do not update sem_otime anymore. The fix is simple: Non-alter operations must update sem_otime. [[email protected]: coding-style fixes] Signed-off-by: Manfred Spraul <[email protected]> Reported-by: Jia He <[email protected]> Tested-by: Jia He <[email protected]> Cc: Davidlohr Bueso <[email protected]> Cc: Mike Galbraith <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
- Loading branch information