summaryrefslogtreecommitdiff
path: root/instruction.h
diff options
context:
space:
mode:
Diffstat (limited to 'instruction.h')
-rw-r--r--instruction.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/instruction.h b/instruction.h
index cf709dc..1992b6a 100644
--- a/instruction.h
+++ b/instruction.h
@@ -19,7 +19,7 @@
/* I-Type instruction */
struct i_type {
uint8_t op:6;
- uint16_t imm16;
+ uint16_t imm16:16;
uint8_t b:5;
uint8_t a:5;
} __packed;
@@ -194,6 +194,7 @@ enum {
/*
* Return values for instruction handlers
*/
+#define INSTR_UNIMPL -2 /* Unimplemented instruction */
#define INSTR_ERR -1 /* Error in instruction */
#define PC_INC_NORMAL 0 /* Normal PC increment after instruction */
#define PC_INC_BY_INSTR 1 /* PC got incremented by instruction */