From 03f5fdd3a2929f40f0b27368c640f0f7a878fd1e Mon Sep 17 00:00:00 2001 From: Fugang Duan Date: Tue, 27 Nov 2012 17:44:19 +0800 Subject: [PATCH] ENGR00235090 FEC: Workaround for FEC RX hang with stress test When do Ethernet UDP stress overnight test with abundance of data transmission, RX path may hang-on. Dump the RX BD, found all BD "Empty" bit is cleared, which means CPU read BD status is not right and waiting here. Change BD memroy attribute from Normal to strongly ordered: changes the memory attribute of C=0, B=0 instead of C=0, B=1. Apply the change, the issue cannot be reproduced. Signed-off-by: Fugang Duan --- drivers/net/fec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/fec.c b/drivers/net/fec.c index db48dfda84e2..6fafd9152d0b 100755 --- a/drivers/net/fec.c +++ b/drivers/net/fec.c @@ -1503,7 +1503,7 @@ static int fec_enet_init(struct net_device *ndev) int i; /* Allocate memory for buffer descriptors. */ - cbd_base = dma_alloc_coherent(NULL, BUFDES_SIZE, &fep->bd_dma, + cbd_base = dma_alloc_noncacheable(NULL, BUFDES_SIZE, &fep->bd_dma, GFP_KERNEL); if (!cbd_base) { printk("FEC: allocate descriptor memory failed?\n"); -- 2.39.5