a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * DBGPlugInCommonELF - Common code for dealing with ELF images.
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * Copyright (C) 2008-2010 Oracle Corporation
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * available from http://www.virtualbox.org. This file is free software;
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * you can redistribute it and/or modify it under the terms of the GNU
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * General Public License (GPL) as published by the Free Software
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
6ec4e1827eab6a424d672ef0e5a17b065e52db20vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync/*******************************************************************************
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync* Header Files *
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync*******************************************************************************/
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync#define LOG_GROUP LOG_GROUP_DBGF ///@todo add new log group.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync/*******************************************************************************
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync* Structures and Typedefs *
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync*******************************************************************************/
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync /** The segment load address. */
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync /** The last address in the segment. */
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync /** The segment index. */
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * Links the segments of the module into the address space.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * @returns VBox status code on failure.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * @param hAs The address space.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * @param hMod The module.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * @param paSegs Array of segment indexes and load addresses.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * @param cSegs The number of segments in the array.
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsyncstatic int dbgDiggerCommonLinkElfSegs(RTDBGAS hAs, RTDBGMOD hMod, PDBGDIGGERELFSEG paSegs, uint32_t cSegs)
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync int rc = RTDbgAsModuleLinkSeg(hAs, hMod, paSegs[i].iSeg, paSegs[i].uLoadAddr, RTDBGASLINK_FLAGS_REPLACE);
a33af978add1a03aab11b2895f441af5cb2a11a6vboxsync * Instantiate the code templates for dealing with the two ELF versions.