kernel: fix more bgmac dma init/cleanup issues
[openwrt.git] / target / linux / generic / patches-3.18 / 077-12-bgmac-drop-ring-num_slots.patch
index 6709aaa..36acc19 100644 (file)
@@ -44,7 +44,7 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
 -      for (i = 0; i < ring->num_slots; i++) {
 +      for (i = 0; i < BGMAC_RX_RING_SLOTS; i++) {
                slot = &ring->slots[i];
-               if (!slot->buf)
+               if (!slot->dma_addr)
                        continue;
 @@ -543,7 +543,8 @@ static void bgmac_dma_rx_ring_free(struc
  }