]> git.karo-electronics.de Git - karo-tx-linux.git/commit
[S390] fix possible deadlock in gmap_map_segment
authorCarsten Otte <cotte@de.ibm.com>
Mon, 10 Oct 2011 14:59:13 +0000 (16:59 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Mon, 10 Oct 2011 14:58:57 +0000 (16:58 +0200)
commit6e69cd0def2268f1cda6ee0254e9754742473c10
tree973693fbbde435fc87f2ce0645599427728b08dc
parent6958be21e013d2c0aa8469013db694acc9857a81
[S390] fix possible deadlock in gmap_map_segment

Fix possible deadlock reported by lockdep:
qemu-system-s39/2963 is trying to acquire lock:
(&mm->mmap_sem){++++++}, at: gmap_alloc_table+0x9c/0x120
but task is already holding lock:
(&mm->mmap_sem){++++++}, at: gmap_map_segment+0xa6/0x27c

Actually gmap_alloc_table is the only called in gmap_map_segment with
mmap_sem held, thus it's safe to simply remove the inner lock.

Signed-off-by: Carsten Otte <cotte@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/mm/pgtable.c