Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
Platform-independent core collection
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
14
Issues
14
List
Board
Labels
Milestones
Merge Requests
5
Merge Requests
5
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Platform-independent core collection
Commits
9058f930
Commit
9058f930
authored
Jun 04, 2019
by
A. Hahn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wishbone_pkg: cleaned up f_sdb_auto_device and f_sdb_auto_device functions
parent
320a0bc7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
39 additions
and
9 deletions
+39
-9
wishbone_pkg.vhd
modules/wishbone/wishbone_pkg.vhd
+39
-9
No files found.
modules/wishbone/wishbone_pkg.vhd
View file @
9058f930
...
...
@@ -227,13 +227,15 @@ package wishbone_pkg is
function
f_sdb_extract_synthesis
(
sdb_record
:
t_sdb_record
)
return
t_sdb_synthesis
;
-- Automatic crossbar mapping functions
function
f_sdb_auto_device
(
device
:
t_sdb_device
;
enable
:
boolean
:
=
true
;
name
:
string
:
=
""
)
return
t_sdb_record
;
function
f_sdb_auto_bridge
(
bridge
:
t_sdb_bridge
;
enable
:
boolean
:
=
true
;
name
:
string
:
=
""
)
return
t_sdb_record
;
function
f_sdb_auto_msi
(
msi
:
t_sdb_msi
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
;
function
f_sdb_auto_layout
(
records
:
t_sdb_record_array
)
return
t_sdb_record_array
;
function
f_sdb_auto_layout
(
slaves
:
t_sdb_record_array
;
masters
:
t_sdb_record_array
)
return
t_sdb_record_array
;
function
f_sdb_auto_sdb
(
records
:
t_sdb_record_array
)
return
t_wishbone_address
;
function
f_sdb_auto_sdb
(
slaves
:
t_sdb_record_array
;
masters
:
t_sdb_record_array
)
return
t_wishbone_address
;
function
f_sdb_auto_device
(
device
:
t_sdb_device
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
;
function
f_sdb_auto_bridge
(
bridge
:
t_sdb_bridge
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
;
function
f_sdb_auto_device_with_name
(
device
:
t_sdb_device
;
enable
:
boolean
:
=
true
;
name
:
string
:
=
""
)
return
t_sdb_record
;
function
f_sdb_auto_bridge_with_name
(
bridge
:
t_sdb_bridge
;
enable
:
boolean
:
=
true
;
name
:
string
:
=
""
)
return
t_sdb_record
;
function
f_sdb_auto_msi
(
msi
:
t_sdb_msi
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
;
function
f_sdb_auto_layout
(
records
:
t_sdb_record_array
)
return
t_sdb_record_array
;
function
f_sdb_auto_layout
(
slaves
:
t_sdb_record_array
;
masters
:
t_sdb_record_array
)
return
t_sdb_record_array
;
function
f_sdb_auto_sdb
(
records
:
t_sdb_record_array
)
return
t_wishbone_address
;
function
f_sdb_auto_sdb
(
slaves
:
t_sdb_record_array
;
masters
:
t_sdb_record_array
)
return
t_wishbone_address
;
-- For internal use by the crossbar
function
f_sdb_bus_end
(
g_wraparound
:
boolean
;
g_layout
:
t_sdb_record_array
;
g_sdb_addr
:
t_wishbone_address
;
msi
:
boolean
)
return
unsigned
;
...
...
@@ -1472,6 +1474,20 @@ package body wishbone_pkg is
function
f_sdb_auto_device
(
device
:
t_sdb_device
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
is
constant
c_zero
:
t_wishbone_address
:
=
(
others
=>
'0'
);
variable
v_empty
:
t_sdb_record
:
=
(
others
=>
'0'
);
begin
v_empty
(
7
downto
0
)
:
=
x"f1"
;
if
enable
then
return
f_sdb_embed_device
(
device
,
c_zero
);
else
return
v_empty
;
end
if
;
end
f_sdb_auto_device
;
function
f_sdb_auto_device_with_name
(
device
:
t_sdb_device
;
enable
:
boolean
:
=
true
;
name
:
string
:
=
""
)
return
t_sdb_record
is
constant
c_zero
:
t_wishbone_address
:
=
(
others
=>
'0'
);
variable
v_device
:
t_sdb_device
:
=
device
;
...
...
@@ -1485,10 +1501,24 @@ package body wishbone_pkg is
v_empty
:
=
f_sdb_embed_device
(
v_device
,
c_zero
);
end
if
;
return
v_empty
;
end
f_sdb_auto_device
;
end
f_sdb_auto_device
_with_name
;
function
f_sdb_auto_bridge
(
bridge
:
t_sdb_bridge
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
is
constant
c_zero
:
t_wishbone_address
:
=
(
others
=>
'0'
);
variable
v_empty
:
t_sdb_record
:
=
(
others
=>
'0'
);
begin
v_empty
(
7
downto
0
)
:
=
x"f2"
;
if
enable
then
return
f_sdb_embed_bridge
(
bridge
,
c_zero
);
else
return
v_empty
;
end
if
;
end
f_sdb_auto_bridge
;
function
f_sdb_auto_bridge_with_name
(
bridge
:
t_sdb_bridge
;
enable
:
boolean
:
=
true
;
name
:
string
:
=
""
)
return
t_sdb_record
is
constant
c_zero
:
t_wishbone_address
:
=
(
others
=>
'0'
);
variable
v_bridge
:
t_sdb_bridge
:
=
bridge
;
...
...
@@ -1502,7 +1532,7 @@ package body wishbone_pkg is
v_empty
:
=
f_sdb_embed_bridge
(
v_bridge
,
c_zero
);
end
if
;
return
v_empty
;
end
f_sdb_auto_bridge
;
end
f_sdb_auto_bridge
_with_name
;
function
f_sdb_auto_msi
(
msi
:
t_sdb_msi
;
enable
:
boolean
:
=
true
)
return
t_sdb_record
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment