aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPaul Selkirk <paul@psgd.org>2015-04-28 18:01:56 -0400
committerPaul Selkirk <paul@psgd.org>2015-04-28 18:01:56 -0400
commit4a0c59617c582ef3f0e558067f913309db772f75 (patch)
treea6a0fbfe8d39397b6daba00e746e8d92dc7b62b4 /src
parent4fcba84b5d05ee335b816f7098cfbe62f549218c (diff)
Remove the delayed read for EIM (see core/platform/novena commit 2f58e8f).
Diffstat (limited to 'src')
-rw-r--r--src/rtl/avalanche_entropy.v25
1 files changed, 10 insertions, 15 deletions
diff --git a/src/rtl/avalanche_entropy.v b/src/rtl/avalanche_entropy.v
index af04c91..3774f27 100644
--- a/src/rtl/avalanche_entropy.v
+++ b/src/rtl/avalanche_entropy.v
@@ -94,8 +94,7 @@ module avalanche_entropy(
//----------------------------------------------------------------
// Registers including update variables and write enable.
//----------------------------------------------------------------
- reg [31 : 0] read_data_hold_reg;
- reg [31 : 0] read_data_hold_new;
+ reg [31 : 0] tmp_read_data;
reg enable_reg;
reg enable_new;
@@ -113,7 +112,7 @@ module avalanche_entropy(
//----------------------------------------------------------------
// Concurrent connectivity for ports etc.
//----------------------------------------------------------------
- assign read_data = read_data_hold_reg;
+ assign read_data = tmp_read_data;
assign error = tmp_error;
assign security_error = 0;
@@ -148,14 +147,10 @@ module avalanche_entropy(
begin
if (!reset_n)
begin
- read_data_hold_reg <= 32'h00000000;
enable_reg <= 1;
end
else
begin
- if (cs)
- read_data_hold_reg <= read_data_hold_new;
-
if (enable_we)
enable_reg <= enable_new;
end
@@ -167,7 +162,7 @@ module avalanche_entropy(
//----------------------------------------------------------------
always @*
begin : api_logic
- read_data_hold_new = 32'h00000000;
+ tmp_read_data = 32'h00000000;
tmp_error = 1'b0;
enable_new = 0;
enable_we = 0;
@@ -195,37 +190,37 @@ module avalanche_entropy(
case (address)
ADDR_NAME0:
begin
- read_data_hold_new = CORE_NAME0;
+ tmp_read_data = CORE_NAME0;
end
ADDR_NAME1:
begin
- read_data_hold_new = CORE_NAME1;
+ tmp_read_data = CORE_NAME1;
end
ADDR_VERSION:
begin
- read_data_hold_new = CORE_VERSION;
+ tmp_read_data = CORE_VERSION;
end
ADDR_CTRL:
begin
- read_data_hold_new = {31'h00000000, enable_reg};
+ tmp_read_data = {31'h00000000, enable_reg};
end
ADDR_STATUS:
begin
- read_data_hold_new = {31'h00000000, entropy_valid};
+ tmp_read_data = {31'h00000000, entropy_valid};
end
ADDR_ENTROPY:
begin
- read_data_hold_new = entropy_data;
+ tmp_read_data = entropy_data;
end
ADDR_DELTA:
begin
- read_data_hold_new = delta;
+ tmp_read_data = delta;
end
default: