Added TODO regarding potential deadlock.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@24820 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold 2008-04-06 02:35:07 +00:00
parent d4016ffdbb
commit 9583c41d8a
1 changed files with 4 additions and 0 deletions

View File

@ -3700,6 +3700,10 @@ vm_page_fault(addr_t address, addr_t faultAddress, bool isWrite, bool isUser,
vm_area *area;
acquire_sem_etc(addressSpace->sem, READ_COUNT, 0, 0);
// TODO: The user_memcpy() below can cause a deadlock, if it causes a page
// fault and someone is already waiting for a write lock on the same address
// space. This thread will then try to acquire the semaphore again and will
// be queued after the writer.
area = vm_area_lookup(addressSpace, faultAddress);
dprintf("vm_page_fault: sending team \"%s\" 0x%lx SIGSEGV, ip %#lx (\"%s\" +%#lx)\n",