aboutsummaryrefslogtreecommitdiffstats
path: root/recipes-kernel/linux/linux-xlnx/zx3-zynq7/0006-xilinx_emacps-Set-the-maximum-frame-reception-size-t.patch
blob: 4e81c5304a295780327c05452636ead11f08712d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
From 117e4a311d0004aa3d5a285cb4e57e5bdd3bb644 Mon Sep 17 00:00:00 2001
From: David Andrey <david.andrey@netmodule.com>
Date: Tue, 1 Jul 2014 10:08:44 +0200
Subject: [PATCH 6/7] xilinx_emacps: Set the maximum frame reception size to
 1536

To make it possible for the driver to receive packets > 1518,
the mode 1536RXEN is now set in the MAC configuration.

Signed-off-by: Stefan Eichenberger <stefan.eichenberger@netmodule.com>
---
 drivers/net/ethernet/xilinx/xilinx_emacps.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/ethernet/xilinx/xilinx_emacps.c b/drivers/net/ethernet/xilinx/xilinx_emacps.c
index a08be55..0ca989e 100644
--- a/drivers/net/ethernet/xilinx/xilinx_emacps.c
+++ b/drivers/net/ethernet/xilinx/xilinx_emacps.c
@@ -281,6 +281,7 @@ MDC_DIV_64, MDC_DIV_96, MDC_DIV_128, MDC_DIV_224 };
 #define XEMACPS_NWCFG_1000_MASK		0x00000400 /* Gigbit mode */
 #define XEMACPS_NWCFG_EXTADDRMATCHEN_MASK	0x00000200
 /* External address match enable */
+#define XEMACPS_NWCFG_1536RXEN		0x00000100 /* Receive 1536 Byte frames */
 #define XEMACPS_NWCFG_UCASTHASHEN_MASK	0x00000080 /* Receive unicast hash
						frames */
 #define XEMACPS_NWCFG_MCASTHASHEN_MASK	0x00000040 /* Receive multicast hash
@@ -1819,6 +1820,7 @@ static void xemacps_init_hw(struct net_local *lp)
	regval |= XEMACPS_NWCFG_PAUSEEN_MASK;
	regval |= XEMACPS_NWCFG_100_MASK;
	regval |= XEMACPS_NWCFG_HDRXEN_MASK;
+	regval |= XEMACPS_NWCFG_1536RXEN;

	regval |= (MDC_DIV_224 << XEMACPS_NWCFG_MDC_SHIFT_MASK);
	if (lp->ndev->flags & IFF_PROMISC)	/* copy all */
--
1.7.10.4