[Cryptech-Commits] [test/novena_base] 01/02: More attempts at getting the addresss decoder to work...

git at cryptech.is git at cryptech.is
Tue Feb 3 20:42:42 UTC 2015


This is an automated email from the git hooks/post-receive script.

joachim at secworks.se pushed a commit to branch sha256_core
in repository test/novena_base.

commit 8bcab15be72dc172cbb06c05407f6778ea3190ad
Author: Joachim Strömbergson <joachim at secworks.se>
Date:   Tue Feb 3 05:18:36 2015 +0100

    More attempts at getting the addresss decoder to work...
---
 rtl/src/verilog/core_selector.v | 32 +++++++++++++++-----------------
 1 file changed, 15 insertions(+), 17 deletions(-)

diff --git a/rtl/src/verilog/core_selector.v b/rtl/src/verilog/core_selector.v
index 4d3a218..a18bfe6 100644
--- a/rtl/src/verilog/core_selector.v
+++ b/rtl/src/verilog/core_selector.v
@@ -48,28 +48,26 @@ module core_selector
 	 input wire [31 : 0]  write_data
 	);
 
-//  parameter SHA256_BASE = 6'h14;
-//  wire is_sha256 = ~(sys_eim_addr[13:8] ^ SHA256_BASE);
-//  wire sha256_cs = (is_sha256 & sys_eim_rd) | (is_sha256 & sys_eim_wr);
-
   localparam SHA256_BASE_ADDR = 6'h14;
   wire access_sha256 = (sys_eim_addr[13 : 8] == SHA256_BASE_ADDR) ? 1'b1 : 1'b0;
-  wire read_access   = sys_eim_wr & access_sha256;
-  wire write_access  = sys_eim_rd & access_sha256;
+  wire read_access   = sys_eim_rd & access_sha256;
+  wire write_access  = sys_eim_wr & access_sha256;
   wire select = read_access | write_access;
 
-  sha256 sha256_inst(
-                     .clk(sys_clk),
-                     .reset_n(~sys_rst),
-
-                     .cs(select),
-                     .we(write_access),
+  assign read_data = (sys_eim_rd) ? 32'hdeadbeef : 32'haa55aa55;
 
-                     .address(sys_eim_addr[7 : 0]),
-                     .write_data(write_data),
-                     .read_data(read_data),
-                     .error()
-                    );
+//  sha256 sha256_inst(
+//                     .clk(sys_clk),
+//                     .reset_n(~sys_rst),
+//
+//                     .cs(select),
+//                     .we(write_access),
+//
+//                     .address(sys_eim_addr[7 : 0]),
+//                     .write_data(write_data),
+//                     .read_data(read_data),
+//                     .error()
+//                    );
 
 endmodule
 



More information about the Commits mailing list