Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
EtherBone Core
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Projects
EtherBone Core
Commits
6fe92011
There was an error fetching the commit references. Please try again later.
Commit
6fe92011
authored
11 years ago
by
Wesley W. Terpstra
Browse files
Options
Downloads
Patches
Plain Diff
eb2: don't push zeros on writes; leave that to the fsm using pass
parent
b25d5868
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
hdl/eb_slave_core/eb_wbm_fifo.vhd
+33
-15
33 additions, 15 deletions
hdl/eb_slave_core/eb_wbm_fifo.vhd
with
33 additions
and
15 deletions
hdl/eb_slave_core/eb_wbm_fifo.vhd
+
33
−
15
View file @
6fe92011
...
...
@@ -55,13 +55,17 @@ architecture rtl of eb_wbm_fifo is
constant
c_size
:
natural
:
=
256
;
constant
c_depth
:
natural
:
=
f_ceil_log2
(
c_size
);
signal
r_timeout
:
unsigned
(
20
downto
0
);
signal
r_inflight
:
unsigned
(
c_depth
-1
downto
0
);
signal
r_full
:
std_logic
;
signal
r_errreg
:
std_logic_vector
(
63
downto
0
);
signal
s_wb_i_rdy
:
std_logic
;
signal
s_mux_dat
:
std_logic_vector
(
31
downto
0
);
signal
s_mux_we
:
std_logic
;
signal
r_timeout
:
unsigned
(
20
downto
0
);
signal
r_inflight
:
unsigned
(
c_depth
-1
downto
0
);
signal
r_full
:
std_logic
;
signal
r_errreg
:
std_logic_vector
(
63
downto
0
);
signal
s_wb_i_rdy
:
std_logic
;
signal
s_fifo_pop
:
std_logic
;
signal
s_fifo_we
:
std_logic
;
signal
s_fifo_empty
:
std_logic
;
signal
s_fifo_dat
:
std_logic_vector
(
31
downto
0
);
signal
r_cache_empty
:
std_logic
;
signal
r_cache_dat
:
std_logic_vector
(
31
downto
0
);
begin
...
...
@@ -95,7 +99,7 @@ begin
elsif
rising_edge
(
clk_i
)
then
if
fsm_wb_i
.
stb
=
'1'
then
busy_o
<=
'1'
;
if
mux
_pop
_i
=
'1'
then
if
s_fifo
_pop
=
'1'
then
r_inflight
<=
r_inflight
;
else
r_inflight
<=
r_inflight
+
1
;
...
...
@@ -105,7 +109,7 @@ begin
busy_o
<=
'0'
;
end
if
;
if
mux
_pop
_i
=
'1'
then
if
s_fifo
_pop
=
'1'
then
r_inflight
<=
r_inflight
-
1
;
else
r_inflight
<=
r_inflight
;
...
...
@@ -135,9 +139,9 @@ begin
w_full_o
=>
open
,
w_push_i
=>
s_wb_i_rdy
,
w_dat_i
=>
wb_i
.
dat
,
r_empty_o
=>
mux
_empty
_o
,
r_pop_i
=>
mux
_pop
_i
,
r_dat_o
=>
s_
mux
_dat
);
r_empty_o
=>
s_fifo
_empty
,
r_pop_i
=>
s_fifo
_pop
,
r_dat_o
=>
s_
fifo
_dat
);
reqfifo
:
eb_fifo
generic
map
(
...
...
@@ -150,9 +154,23 @@ begin
w_push_i
=>
fsm_wb_i
.
stb
,
w_dat_i
(
0
)
=>
fsm_wb_i
.
we
,
r_empty_o
=>
open
,
r_pop_i
=>
mux
_pop
_i
,
r_dat_o
(
0
)
=>
s_
mux
_we
);
r_pop_i
=>
s_fifo
_pop
,
r_dat_o
(
0
)
=>
s_
fifo
_we
);
mux_dat_o
<=
s_mux_dat
when
s_mux_we
=
'0'
else
(
others
=>
'0'
);
s_fifo_pop
<=
not
s_fifo_empty
and
(
r_cache_empty
or
mux_pop_i
);
skip_writes
:
process
(
rstn_i
,
clk_i
)
is
begin
if
rstn_i
=
'0'
then
r_cache_empty
<=
'1'
;
r_cache_dat
<=
(
others
=>
'0'
);
elsif
rising_edge
(
clk_i
)
then
r_cache_empty
<=
s_fifo_empty
or
s_fifo_we
;
r_cache_dat
<=
s_fifo_dat
;
end
if
;
end
process
;
mux_empty_o
<=
r_cache_empty
;
mux_dat_o
<=
r_cache_dat
;
end
rtl
;
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment