faults.cc (13896:5a827a65bd1d) | faults.cc (14091:090449e74135) |
---|---|
1/* 2 * Copyright (c) 2010, 2012-2014, 2016-2018 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 1202 unchanged lines hidden (view full) --- 1211 ((source >= ArmFault::AccessFlagLL) && 1212 (source < ArmFault::AccessFlagLL + 4)) || 1213 ((source >= ArmFault::DomainLL) && 1214 (source < ArmFault::DomainLL + 4)) || 1215 ((source >= ArmFault::PermissionLL) && 1216 (source < ArmFault::PermissionLL + 4)); 1217} 1218 | 1/* 2 * Copyright (c) 2010, 2012-2014, 2016-2018 ARM Limited 3 * All rights reserved 4 * 5 * The license below extends only to copyright in the software and shall 6 * not be construed as granting a license to any other intellectual 7 * property including but not limited to intellectual property relating 8 * to a hardware implementation of the functionality of the software --- 1202 unchanged lines hidden (view full) --- 1211 ((source >= ArmFault::AccessFlagLL) && 1212 (source < ArmFault::AccessFlagLL + 4)) || 1213 ((source >= ArmFault::DomainLL) && 1214 (source < ArmFault::DomainLL + 4)) || 1215 ((source >= ArmFault::PermissionLL) && 1216 (source < ArmFault::PermissionLL + 4)); 1217} 1218 |
1219template<class T> 1220bool 1221AbortFault<T>::getFaultVAddr(Addr &va) const 1222{ 1223 va = (stage2 ? OVAddr : faultAddr); 1224 return true; 1225} 1226 |
|
1219ExceptionClass 1220PrefetchAbort::ec(ThreadContext *tc) const 1221{ 1222 if (to64) { 1223 // AArch64 1224 if (toEL == fromEL) 1225 return EC_PREFETCH_ABORT_CURR_EL; 1226 else --- 386 unchanged lines hidden (view full) --- 1613template class AbortFault<PrefetchAbort>; 1614template class AbortFault<DataAbort>; 1615template class AbortFault<VirtualDataAbort>; 1616 1617 1618IllegalInstSetStateFault::IllegalInstSetStateFault() 1619{} 1620 | 1227ExceptionClass 1228PrefetchAbort::ec(ThreadContext *tc) const 1229{ 1230 if (to64) { 1231 // AArch64 1232 if (toEL == fromEL) 1233 return EC_PREFETCH_ABORT_CURR_EL; 1234 else --- 386 unchanged lines hidden (view full) --- 1621template class AbortFault<PrefetchAbort>; 1622template class AbortFault<DataAbort>; 1623template class AbortFault<VirtualDataAbort>; 1624 1625 1626IllegalInstSetStateFault::IllegalInstSetStateFault() 1627{} 1628 |
1629bool 1630getFaultVAddr(Fault fault, Addr &va) 1631{ 1632 auto arm_fault = dynamic_cast<ArmFault *>(fault.get()); |
|
1621 | 1633 |
1634 if (arm_fault) { 1635 return arm_fault->getFaultVAddr(va); 1636 } else { 1637 auto pgt_fault = dynamic_cast<GenericPageTableFault *>(fault.get()); 1638 if (pgt_fault) { 1639 va = pgt_fault->getFaultVAddr(); 1640 return true; 1641 } 1642 1643 auto align_fault = dynamic_cast<GenericAlignmentFault *>(fault.get()); 1644 if (align_fault) { 1645 va = align_fault->getFaultVAddr(); 1646 return true; 1647 } 1648 1649 // Return false since it's not an address triggered exception 1650 return false; 1651 } 1652} 1653 |
|
1622} // namespace ArmISA | 1654} // namespace ArmISA |