From ba9c55b5554f447f1bbd02eae9a3f9aa57207394 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Fri, 15 Oct 2004 14:20:51 +0000 Subject: [PATCH] Sure, that bug waited *that* long to pop up. git-svn-id: file:///srv/svn/repos/haiku/trunk/current@9367 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kernel/core/arch/x86/arch_vm_translation_map.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/kernel/core/arch/x86/arch_vm_translation_map.c b/src/kernel/core/arch/x86/arch_vm_translation_map.c index 3eb03063fd..19674d890f 100755 --- a/src/kernel/core/arch/x86/arch_vm_translation_map.c +++ b/src/kernel/core/arch/x86/arch_vm_translation_map.c @@ -140,6 +140,7 @@ unlock_tmap(vm_translation_map *map) // we're about to release it for the last time flush_tmap(map); } + recursive_lock_unlock(&map->lock); return 0; } @@ -270,7 +271,7 @@ map_tmap(vm_translation_map *map, addr_t va, addr_t pa, uint32 attributes) // put it in the pgdir put_pgtable_in_pgdir(&pd[index], pgtable, attributes - | (attributes & B_KERNEL_PROTECTION ? B_KERNEL_WRITE_AREA : B_WRITE_AREA)); + | (attributes & B_USER_PROTECTION ? B_WRITE_AREA : B_KERNEL_WRITE_AREA)); // update any other page directories, if it maps kernel space if (index >= FIRST_KERNEL_PGDIR_ENT && index < (FIRST_KERNEL_PGDIR_ENT + NUM_KERNEL_PGDIR_ENTS))