vtophys.hh revision 2650
112598Snikos.nikoleris@arm.com/* 27090SN/A * Copyright (c) 2002-2005 The Regents of The University of Michigan 37090SN/A * All rights reserved. 47090SN/A * 57090SN/A * Redistribution and use in source and binary forms, with or without 67090SN/A * modification, are permitted provided that the following conditions are 77090SN/A * met: redistributions of source code must retain the above copyright 87090SN/A * notice, this list of conditions and the following disclaimer; 97090SN/A * redistributions in binary form must reproduce the above copyright 107090SN/A * notice, this list of conditions and the following disclaimer in the 117090SN/A * documentation and/or other materials provided with the distribution; 127090SN/A * neither the name of the copyright holders nor the names of its 134486SN/A * contributors may be used to endorse or promote products derived from 144486SN/A * this software without specific prior written permission. 154486SN/A * 164486SN/A * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 174486SN/A * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 184486SN/A * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 194486SN/A * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 204486SN/A * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 214486SN/A * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 224486SN/A * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 234486SN/A * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 244486SN/A * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 254486SN/A * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 264486SN/A * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 274486SN/A */ 284486SN/A 294486SN/A#ifndef __ARCH_SPARC_VTOPHYS_H__ 304486SN/A#define __ARCH_SPARC_VTOPHYS_H__ 314486SN/A 324486SN/A#include "arch/sparc/isa_traits.hh" 334486SN/A 344486SN/Aclass ExecContext; 354486SN/Aclass FunctionalPort; 364486SN/A 374486SN/Anamespace SparcISA { 384486SN/A 397584SAli.Saidi@arm.comPageTableEntry 407584SAli.Saidi@arm.comkernel_pte_lookup(FunctionalPort *mem, Addr ptbr, SparcISA::VAddr vaddr); 417754SWilliam.Wang@arm.com 4212472Sglenn.bergmans@arm.comAddr vtophys(Addr vaddr); 434486SN/AAddr vtophys(ExecContext *xc, Addr vaddr); 4412472Sglenn.bergmans@arm.com 453630SN/Avoid CopyOut(ExecContext *xc, void *dst, Addr src, size_t len); 463630SN/Avoid CopyIn(ExecContext *xc, Addr dst, void *src, size_t len); 4712472Sglenn.bergmans@arm.comvoid CopyStringOut(ExecContext *xc, char *dst, Addr vaddr, size_t maxlen); 4813665Sandreas.sandberg@arm.comvoid CopyStringIn(ExecContext *xc, char *src, Addr vaddr); 4913665Sandreas.sandberg@arm.com 5013665Sandreas.sandberg@arm.com}; 5113665Sandreas.sandberg@arm.com#endif // __ARCH_SPARC_VTOPHYS_H__ 5213665Sandreas.sandberg@arm.com 5313665Sandreas.sandberg@arm.com