From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Christoph Egger" Subject: Re: [PATCH][ELF] Correct space calculation for symtab when BSD_SYMTAB=yes Date: Thu, 2 Aug 2007 18:52:49 +0200 Message-ID: <200708021852.49573.Christoph.Egger@amd.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On Thursday 02 August 2007 15:21:34 Keir Fraser wrote: > On 2/8/07 13:26, "Christoph Egger" wrote: > >> What do the virtual addresses of the symtab/strtab sections have to > >> do with their location in the final address space, after loading? And > >> since you pack the sections into the domain address space in > >> elf_xen_dom_load_binary(), should you not simply sum the sizes of the > >> sections, then sstart=3Dvirt_kend and send=3Dsstart+size_sum, rather t= han > >> taking max(end addresses in elf image) minus min(start addresses in elf > >> image). > > > > You're right. Attached is a patch, which does it that way. > > Please try changeset 15679 in the -unstable staging tree. It's less code > and also fixed up to work with the domU domain builder too. Except it's n= ot > actually been tested with a bsd_symtab guest kernel. It shouldn't need mo= re > than a few lines of fixing to get it working though, if that. > > -- Keir I tested this both with a Dom0 and DomU guest domain. It works! Thanks a lot. Christoph =2D-=20 AMD Saxony, Dresden, Germany Operating System Research Center Legal Information: AMD Saxony Limited Liability Company & Co. KG Sitz (Gesch=E4ftsanschrift): Wilschdorfer Landstr. 101, 01109 Dresden, Deutschland Registergericht Dresden: HRA 4896 vertretungsberechtigter Komplement=E4r: AMD Saxony LLC (Sitz Wilmington, Delaware, USA) Gesch=E4ftsf=FChrer der AMD Saxony LLC: Dr. Hans-R. Deppe, Thomas McCoy