operatingsystem.cc revision 8229
15795Ssaidi@eecs.umich.edu/* 25795Ssaidi@eecs.umich.edu * Copyright (c) 2009 The Regents of The University of Michigan 35795Ssaidi@eecs.umich.edu * All rights reserved. 45795Ssaidi@eecs.umich.edu * 55795Ssaidi@eecs.umich.edu * Redistribution and use in source and binary forms, with or without 65795Ssaidi@eecs.umich.edu * modification, are permitted provided that the following conditions are 75795Ssaidi@eecs.umich.edu * met: redistributions of source code must retain the above copyright 85795Ssaidi@eecs.umich.edu * notice, this list of conditions and the following disclaimer; 95795Ssaidi@eecs.umich.edu * redistributions in binary form must reproduce the above copyright 105795Ssaidi@eecs.umich.edu * notice, this list of conditions and the following disclaimer in the 115795Ssaidi@eecs.umich.edu * documentation and/or other materials provided with the distribution; 125795Ssaidi@eecs.umich.edu * neither the name of the copyright holders nor the names of its 135795Ssaidi@eecs.umich.edu * contributors may be used to endorse or promote products derived from 145795Ssaidi@eecs.umich.edu * this software without specific prior written permission. 155795Ssaidi@eecs.umich.edu * 165795Ssaidi@eecs.umich.edu * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 175795Ssaidi@eecs.umich.edu * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 185795Ssaidi@eecs.umich.edu * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 195795Ssaidi@eecs.umich.edu * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 205795Ssaidi@eecs.umich.edu * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 215795Ssaidi@eecs.umich.edu * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 225795Ssaidi@eecs.umich.edu * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 235795Ssaidi@eecs.umich.edu * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 245795Ssaidi@eecs.umich.edu * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 255795Ssaidi@eecs.umich.edu * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 265795Ssaidi@eecs.umich.edu * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 275795Ssaidi@eecs.umich.edu * 285795Ssaidi@eecs.umich.edu * Authors: Ali Saidi 295795Ssaidi@eecs.umich.edu */ 305795Ssaidi@eecs.umich.edu 315795Ssaidi@eecs.umich.edu 328229Snate@binkert.org#include "base/misc.hh" 335795Ssaidi@eecs.umich.edu#include "kern/operatingsystem.hh" 345795Ssaidi@eecs.umich.edu 355795Ssaidi@eecs.umich.eduint 365795Ssaidi@eecs.umich.eduOperatingSystem::openSpecialFile(std::string path, LiveProcess *process, ThreadContext *tc) 375795Ssaidi@eecs.umich.edu{ 385795Ssaidi@eecs.umich.edu warn("Attempting to open special file: %s. Ignorning. Simulation may" 395795Ssaidi@eecs.umich.edu " take un-expected code path or be non-deterministic until proper" 405795Ssaidi@eecs.umich.edu " handling is implemented.\n", path.c_str()); 415795Ssaidi@eecs.umich.edu return -1; 425795Ssaidi@eecs.umich.edu} 435795Ssaidi@eecs.umich.edu 445795Ssaidi@eecs.umich.edu 45