projects
/
gem5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a5ea52b
)
ARM: Implement a badMode function that says whether a mode is legal.
author
Gabe Black
<gblack@eecs.umich.edu>
Wed, 2 Jun 2010 17:58:11 +0000
(12:58 -0500)
committer
Gabe Black
<gblack@eecs.umich.edu>
Wed, 2 Jun 2010 17:58:11 +0000
(12:58 -0500)
src/arch/arm/types.hh
patch
|
blob
|
history
diff --git
a/src/arch/arm/types.hh
b/src/arch/arm/types.hh
index e99a00435f5c90edb0de3e2db6aa73987912c730..2fe4f4aa76411e19986ea2e7cd5979240c9672be 100644
(file)
--- a/
src/arch/arm/types.hh
+++ b/
src/arch/arm/types.hh
@@
-234,6
+234,24
@@
namespace ArmISA
MODE_SYSTEM = 31
};
+ static inline bool
+ badMode(OperatingMode mode)
+ {
+ switch (mode) {
+ case MODE_USER:
+ case MODE_FIQ:
+ case MODE_IRQ:
+ case MODE_SVC:
+ case MODE_MON:
+ case MODE_ABORT:
+ case MODE_UNDEFINED:
+ case MODE_SYSTEM:
+ return false;
+ default:
+ return true;
+ }
+ }
+
struct CoreSpecific {
// Empty for now on the ARM
};