From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1944) id 8F89D3846446; Wed, 26 Oct 2022 15:16:33 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8F89D3846446 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1666797393; bh=xL/pM0vX8fV6M/3zDsPaB9uY30rqUUoS1wDy8+bySh8=; h=From:To:Subject:Date:From; b=K+U8Qwp3iHqvC/iNBvSvmGZKTq9vfK3T/osx5bl45gSLIoMPakwY0Gw/cUBNva4Ll LfnxerLwVtCEW84jK9m6SPvYqusT5E7Y9emwhZy6CD4X8Wh1onpoTu92nZq2Rhydj3 BbzgnhDxTH33TJLja0vMNn9gxXWq0dqg40/6cmbY= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Szabolcs Nagy To: glibc-cvs@sourceware.org Subject: [glibc/arm/morello/main] cheri: elf: elfptr_t l_map_start in link_map struct X-Act-Checkin: glibc X-Git-Author: Szabolcs Nagy X-Git-Refname: refs/heads/arm/morello/main X-Git-Oldrev: 9d21cfb0aab80482e00b878a371b9e03eab5a74c X-Git-Newrev: 6b86cb6bf1a61f52c03f466742ebebcc746853aa Message-Id: <20221026151633.8F89D3846446@sourceware.org> Date: Wed, 26 Oct 2022 15:16:33 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=6b86cb6bf1a61f52c03f466742ebebcc746853aa commit 6b86cb6bf1a61f52c03f466742ebebcc746853aa Author: Szabolcs Nagy Date: Thu Apr 7 13:18:48 2022 +0100 cheri: elf: elfptr_t l_map_start in link_map struct Use a capability for the load segment start that covers all load segments so pointers can be derived from it. It should have RX permission and a separate capability used for writable pointers. Diff: --- include/link.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/include/link.h b/include/link.h index 0ac82d7c77..7632ae33d3 100644 --- a/include/link.h +++ b/include/link.h @@ -252,7 +252,8 @@ struct link_map /* Start and finish of memory map for this object. l_map_start need not be the same as l_addr. */ - ElfW(Addr) l_map_start, l_map_end; + elfptr_t l_map_start; + ElfW(Addr) l_map_end; /* End of the executable part of the mapping. */ ElfW(Addr) l_text_end;