faults.cc (3603:714467743f9b) | faults.cc (3628:b562d6fc3893) |
---|---|
1/* 2 * Copyright (c) 2003-2005 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 579 unchanged lines hidden (view full) --- 588 tc->setMiscReg(MISCREG_TL, MaxTL); 589 tc->setMiscReg(MISCREG_TT, trapType()); 590 tc->setMiscRegWithEffect(MISCREG_GL, MaxGL); 591 592 //Turn on pef, set everything else to 0 593 tc->setMiscReg(MISCREG_PSTATE, 1 << 4); 594 595 //Turn on red and hpriv, set everything else to 0 | 1/* 2 * Copyright (c) 2003-2005 The Regents of The University of Michigan 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions are 7 * met: redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer; --- 579 unchanged lines hidden (view full) --- 588 tc->setMiscReg(MISCREG_TL, MaxTL); 589 tc->setMiscReg(MISCREG_TT, trapType()); 590 tc->setMiscRegWithEffect(MISCREG_GL, MaxGL); 591 592 //Turn on pef, set everything else to 0 593 tc->setMiscReg(MISCREG_PSTATE, 1 << 4); 594 595 //Turn on red and hpriv, set everything else to 0 |
596 tc->setMiscReg(MISCREG_HPSTATE, (1 << 5) | (1 << 2)); | 596 MiscReg HPSTATE = tc->readMiscReg(MISCREG_HPSTATE); 597 //HPSTATE.red = 1 598 HPSTATE |= (1 << 5); 599 //HPSTATE.hpriv = 1 600 HPSTATE |= (1 << 2); 601 //HPSTATE.ibe = 0 602 HPSTATE &= ~(1 << 10); 603 //HPSTATE.tlz = 0 604 HPSTATE &= ~(1 << 0); 605 tc->setMiscReg(MISCREG_HPSTATE, HPSTATE); |
597 598 //The tick register is unreadable by nonprivileged software 599 tc->setMiscReg(MISCREG_TICK, 1ULL << 63); 600 601 Addr PC, NPC; 602 getREDVector(trapType(), PC, NPC); 603 tc->setPC(PC); 604 tc->setNextPC(NPC); --- 83 unchanged lines hidden --- | 606 607 //The tick register is unreadable by nonprivileged software 608 tc->setMiscReg(MISCREG_TICK, 1ULL << 63); 609 610 Addr PC, NPC; 611 getREDVector(trapType(), PC, NPC); 612 tc->setPC(PC); 613 tc->setNextPC(NPC); --- 83 unchanged lines hidden --- |