diff options
author | Felix Fietkau <nbd@openwrt.org> | 2015-04-13 17:32:33 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2015-04-13 17:32:33 +0000 |
commit | 402c9a689ecc7e6d32913ae7161ceb038a27e848 (patch) | |
tree | 900605bee0d7fea650f2d96394db47796afaa9f4 /target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch | |
parent | aef07fb7c85d795a3f1b36fb831d6b76617f3768 (diff) | |
download | upstream-402c9a689ecc7e6d32913ae7161ceb038a27e848.tar.gz upstream-402c9a689ecc7e6d32913ae7161ceb038a27e848.tar.bz2 upstream-402c9a689ecc7e6d32913ae7161ceb038a27e848.zip |
kernel: sync bgmac changes with latest upstream submission
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@45420 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch')
-rw-r--r-- | target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch b/target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch index fa45a43686..89e1a32368 100644 --- a/target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch +++ b/target/linux/generic/patches-3.18/077-08-bgmac-add-check-for-oversized-packets.patch @@ -11,15 +11,14 @@ Signed-off-by: Felix Fietkau <nbd@openwrt.org> --- a/drivers/net/ethernet/broadcom/bgmac.c +++ b/drivers/net/ethernet/broadcom/bgmac.c -@@ -422,6 +422,14 @@ static int bgmac_dma_rx_read(struct bgma +@@ -428,6 +428,13 @@ static int bgmac_dma_rx_read(struct bgma break; } + if (len > BGMAC_RX_ALLOC_SIZE) { + bgmac_err(bgmac, "Found oversized packet at slot %d, DMA issue!\n", + ring->start); -+ rx->len = cpu_to_le16(0xdead); -+ rx->flags = cpu_to_le16(0xbeef); ++ kfree(buf); + break; + } + |