From owner-p4-projects Wed Jun 19 0: 0:52 2002 Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id AFE3337B406; Wed, 19 Jun 2002 00:00:29 -0700 (PDT) Delivered-To: perforce@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 9ADDA37B40E for ; Wed, 19 Jun 2002 00:00:24 -0700 (PDT) Received: (from perforce@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g5J70O209509 for perforce@freebsd.org; Wed, 19 Jun 2002 00:00:24 -0700 (PDT) (envelope-from peter@freebsd.org) Date: Wed, 19 Jun 2002 00:00:24 -0700 (PDT) Message-Id: <200206190700.g5J70O209509@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: perforce set sender to peter@freebsd.org using -f From: Peter Wemm Subject: PERFORCE change 13143 for review To: Perforce Change Reviews Sender: owner-p4-projects@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG http://people.freebsd.org/~peter/p4db/chv.cgi?CH=13143 Change 13143 by peter@peter_ia64 on 2002/06/19 00:00:08 Do not pass 4K page offsets into VM. This causes the pmap_protect: unaligned addresses panics. XXX This is inadequate. We need to raise permissions here, not change them according to rounding. However, it seems to work because we load data after text, which raises the last parts to read/write. (MAP_PRIVATE makes this harmless) Affected files ... ... //depot/projects/ia64/sys/kern/imgact_elf.c#8 edit Differences ... ==== //depot/projects/ia64/sys/kern/imgact_elf.c#8 (text+ko) ==== @@ -414,10 +414,11 @@ } /* - * set it to the specified protection + * set it to the specified protection. + * XXX had better undo the damage from pasting over the cracks here! */ - vm_map_protect(&vmspace->vm_map, map_addr, map_addr + map_len, prot, - FALSE); + vm_map_protect(&vmspace->vm_map, trunc_page(map_addr), + round_page(map_addr + map_len), prot, FALSE); return error; } To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe p4-projects" in the body of the message