From 2ff1847823b26e681a690cc00096a864576319d6 Mon Sep 17 00:00:00 2001 From: devi priya Date: Thu, 8 Sep 2022 12:52:01 +0530 Subject: [PATCH] drivers: net: ipq9574: Removing the additional rx buffer allocation During long run tests on image download in u-boot, EDMA crash was observed as the SKB buffer address returned by the RX descriptor was corrupted and was pointing to an invalid address: clean_rx: p: 14 c: 0 skb: 61763b10 WARN: src_info_type:0x0. Drop skb:61763b10 The reason for corruption seems to be the RX buffer allocation that was happening twice before initiating the EDMA for the next transaction. This change removes the additional allocation of the Rx buffer which is not needed. Change-Id: I919024df8131fe87640ecc0d481b61012742efbf Signed-off-by: devi priya --- drivers/net/ipq9574/ipq9574_edma.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/ipq9574/ipq9574_edma.c b/drivers/net/ipq9574/ipq9574_edma.c index 6bdeeb9d08..56605bc186 100644 --- a/drivers/net/ipq9574/ipq9574_edma.c +++ b/drivers/net/ipq9574/ipq9574_edma.c @@ -249,7 +249,6 @@ uint32_t ipq9574_edma_clean_rx(struct ipq9574_edma_common_info *c_info, int pkt_length; int rx = CONFIG_SYS_RX_ETH_BUFFER; u16 cleaned_count = 0; - struct ipq9574_edma_hw *ehw = &c_info->hw; pr_debug("%s: rxdesc_ring->id = %d\n", __func__, rxdesc_ring->id); /* @@ -322,7 +321,6 @@ next_rx_desc: } if (cleaned_count) { - ipq9574_edma_alloc_rx_buffer(ehw, rxdesc_ring->rxfill); ipq9574_edma_reg_write(IPQ9574_EDMA_REG_RXDESC_CONS_IDX( rxdesc_ring->id), cons_idx); }