Commit 9ff12a3d authored by Lucas Russo's avatar Lucas Russo

modules/pcie/*: fix DDR depth generic by importing from ipcores_pkg

The previous DDR depth was hardcoded as 30,
which is right for kc705 board, but not for
AFC.

This fixes that by using the ipcores_pkg
definitions which are respective to the
DDR definitions of the used board.

This should help github issue #45,
but in my tests it didn't solve it
just yet. Nonethless, this was wrong
anyway.
parent 28d21f3a
......@@ -10,6 +10,9 @@ library IEEE;
use IEEE.STD_LOGIC_1164.all;
use IEEE.STD_LOGIC_ARITH.all;
library work;
use work.ipcores_pkg.all;
package abb64Package is
-- Declare constants
......@@ -106,7 +109,11 @@ package abb64Package is
-- 8192 Mb= 1024MB : 30
-- 16384 Mb= 2048MB : 31
-- 32768 Mb= 4096MB : 32
constant C_DDR_IAWIDTH : integer range 24 to 32 := 30;
-- Get correct nubmer of DDR bit address from ipcores_pkg,
-- that contains definitions for the specific board we're
-- synthesizing against
constant C_DDR_IAWIDTH : integer range 24 to 32 := C_DDR_ADDR_WIDTH;
--- Block RAM address bus width. Variation requires BRAM core regeneration.
constant C_PRAM_AWIDTH : integer range 8 to 29 := 29;
......@@ -367,7 +374,7 @@ package abb64Package is
-- Bit range of Wishbone address in Channel Buffer word
constant C_CHBUF_WB_BIT_BOT : integer := C_CHANNEL_BUF_WIDTH-C_WB_AWIDTH; --97;
constant C_CHBUF_WB_BIT_TOP : integer := C_CHANNEL_BUF_WIDTH-1; --127;
------------------------------------------------------------------------
-- TX Mem Reader channel bit definitions
constant C_TXMEM_TLAST_BIT : integer := C_DBUS_WIDTH;
......@@ -737,7 +744,7 @@ package body abb64Package is
else
return tkeep_in;
end if;
assert tkeep_in'length = 4 or tkeep_in'length = 8
report "tkeep length must be 4 or 8"
severity failure;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment