Commit 0eba52da authored by Davidlohr Bueso's avatar Davidlohr Bueso Committed by Sasha Levin
Browse files

ipc,shm: move BUG_ON check into shm_lock



[ Upstream commit c5c8975b ]

Upon every shm_lock call, we BUG_ON if an error was returned, indicating
racing either in idr or in shm_destroy.  Move this logic into the locking.

[akpm@linux-foundation.org: simplify code]
Signed-off-by: default avatarDavidlohr Bueso <dbueso@suse.de>
Cc: Manfred Spraul <manfred@colorfullife.com>
Cc: Davidlohr Bueso <dave@stgolabs.net>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>

Signed-off-by: default avatarSasha Levin <sasha.levin@oracle.com>
parent aff5e598
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment