]> git.sur5r.net Git - u-boot/commitdiff
net: zynq: Allocate BD_SPACE in connection to RX_BUF
authorMichal Simek <michal.simek@xilinx.com>
Mon, 17 Aug 2015 07:45:53 +0000 (09:45 +0200)
committerMichal Simek <michal.simek@xilinx.com>
Thu, 19 Nov 2015 12:50:09 +0000 (13:50 +0100)
BD_SEPRN_SPACE should not have hard coded value and it will be
calculated based on the number of buffer descriptors that we
would like to use.

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Acked-by: Joe Hershberger <joe.hershberger@ni.com>
drivers/net/zynq_gem.c

index 41ac8295dbed13d61b1ab600eecbf38f1943840c..875738abb25a388aa711e80293e18f08abb969a8 100644 (file)
@@ -145,7 +145,7 @@ struct emac_bd {
  */
 #define BD_SPACE       0x100000
 /* BD separation space */
-#define BD_SEPRN_SPACE 64
+#define BD_SEPRN_SPACE (RX_BUF * sizeof(struct emac_bd))
 
 /* Initialized, rxbd_current, rx_first_buf must be 0 after init */
 struct zynq_gem_priv {