aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Austein <sra@hactrn.net>2015-09-23 21:12:29 -0400
committerRob Austein <sra@hactrn.net>2015-09-23 21:12:29 -0400
commit6f5bf9065d49b7829ddd76b502e4034c745cdec2 (patch)
tree6cf306cecc3830dca8ce6f6d2ce0231c182dc8b2
parent026fc461d9791bc360036f1269d0f6d61c45d179 (diff)
MODEXPS6_ADDR_BASE goes away under the new scheme.
-rw-r--r--sw/cryptech.h24
1 files changed, 12 insertions, 12 deletions
diff --git a/sw/cryptech.h b/sw/cryptech.h
index 8a7361f..5426359 100644
--- a/sw/cryptech.h
+++ b/sw/cryptech.h
@@ -402,30 +402,30 @@ in order to map it into a 16-bit address space.
// Experimental ModexpS6 core.
// XXX AT THE SAME CORE PREFIX - YOU CAN'T HAVE BOTH AT THE SAME TIME
-#define MODEXPS6_ADDR_BASE SEGMENT_OFFSET_MATH + (0x00 * CORE_SIZE)
-#define MODEXPS6_ADDR_NAME0 MODEXPS6_ADDR_BASE + ADDR_NAME0
-#define MODEXPS6_ADDR_NAME1 MODEXPS6_ADDR_BASE + ADDR_NAME1
-#define MODEXPS6_ADDR_VERSION MODEXPS6_ADDR_BASE + ADDR_VERSION
-#define MODEXPS6_ADDR_CTRL MODEXPS6_ADDR_BASE + ADDR_CTRL
+// Well, under the old scheme, anyway, remains to be seen with the new scheme
+#define MODEXPS6_ADDR_NAME0 ADDR_NAME0
+#define MODEXPS6_ADDR_NAME1 ADDR_NAME1
+#define MODEXPS6_ADDR_VERSION ADDR_VERSION
+#define MODEXPS6_ADDR_CTRL ADDR_CTRL
#define MODEXPS6_CTRL_INIT_BIT 1
#define MODEXPS6_CTRL_NEXT_BIT 2
-#define MODEXPS6_ADDR_STATUS MODEXPS6_ADDR_BASE + ADDR_STATUS
+#define MODEXPS6_ADDR_STATUS ADDR_STATUS
/* 4096-bit operands are stored as 128 words of 32 bits */
#define MODEXPS6_OPERAND_SIZE 4096/32
-#define MODEXPS6_ADDR_REGISTERS MODEXPS6_ADDR_BASE + 0*MODEXPS6_OPERAND_SIZE
-#define MODEXPS6_ADDR_OPERANDS MODEXPS6_ADDR_BASE + 4*MODEXPS6_OPERAND_SIZE
+#define MODEXPS6_ADDR_REGISTERS 0 * MODEXPS6_OPERAND_SIZE
+#define MODEXPS6_ADDR_OPERANDS 4 * MODEXPS6_OPERAND_SIZE
#define MODEXPS6_ADDR_MODE MODEXPS6_ADDR_REGISTERS + 0x10
#define MODEXPS6_ADDR_MODULUS_WIDTH MODEXPS6_ADDR_REGISTERS + 0x11
#define MODEXPS6_ADDR_EXPONENT_WIDTH MODEXPS6_ADDR_REGISTERS + 0x12
/* addresses of block memories for operands */
-#define MODEXPS6_ADDR_MODULUS MODEXPS6_ADDR_OPERANDS + 0*MODEXPS6_OPERAND_SIZE
-#define MODEXPS6_ADDR_MESSAGE MODEXPS6_ADDR_OPERANDS + 1*MODEXPS6_OPERAND_SIZE
-#define MODEXPS6_ADDR_EXPONENT MODEXPS6_ADDR_OPERANDS + 2*MODEXPS6_OPERAND_SIZE
-#define MODEXPS6_ADDR_RESULT MODEXPS6_ADDR_OPERANDS + 3*MODEXPS6_OPERAND_SIZE
+#define MODEXPS6_ADDR_MODULUS MODEXPS6_ADDR_OPERANDS + 0 * MODEXPS6_OPERAND_SIZE
+#define MODEXPS6_ADDR_MESSAGE MODEXPS6_ADDR_OPERANDS + 1 * MODEXPS6_OPERAND_SIZE
+#define MODEXPS6_ADDR_EXPONENT MODEXPS6_ADDR_OPERANDS + 2 * MODEXPS6_OPERAND_SIZE
+#define MODEXPS6_ADDR_RESULT MODEXPS6_ADDR_OPERANDS + 3 * MODEXPS6_OPERAND_SIZE
#define MODEXPS6_NAME0 "mode"
#define MODEXPS6_NAME1 "xps6"