From beac84a0a235bee80d5b769aeaf16b41a8f51831 Mon Sep 17 00:00:00 2001 From: Sasha Levin Date: Thu, 12 Sep 2019 18:54:11 -0400 Subject: [PATCH] fixes for 4.4 Signed-off-by: Sasha Levin --- ...ne-down-the-tx-ring-unsupported-spew.patch | 36 +++++++++++++++++++ queue-4.4/series | 1 + 2 files changed, 37 insertions(+) create mode 100644 queue-4.4/af_packet-tone-down-the-tx-ring-unsupported-spew.patch diff --git a/queue-4.4/af_packet-tone-down-the-tx-ring-unsupported-spew.patch b/queue-4.4/af_packet-tone-down-the-tx-ring-unsupported-spew.patch new file mode 100644 index 00000000000..3a9ad3aa668 --- /dev/null +++ b/queue-4.4/af_packet-tone-down-the-tx-ring-unsupported-spew.patch @@ -0,0 +1,36 @@ +From 394fb5f87ec8f0428db509d1690a2242bd3f27d3 Mon Sep 17 00:00:00 2001 +From: Dave Jones +Date: Mon, 4 Apr 2016 15:11:50 -0400 +Subject: af_packet: tone down the Tx-ring unsupported spew. + +[ Upstream commit 6ae81ced378820c4c6434b1dedba14a7122df310 ] + +Trinity and other fuzzers can hit this WARN on far too easily, +resulting in a tainted kernel that hinders automated fuzzing. + +Replace it with a rate-limited printk. + +Signed-off-by: Dave Jones +Acked-by: Daniel Borkmann +Signed-off-by: David S. Miller +Signed-off-by: Sasha Levin +--- + net/packet/af_packet.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/net/packet/af_packet.c b/net/packet/af_packet.c +index 5d8988185c591..0dd9fc3f57e87 100644 +--- a/net/packet/af_packet.c ++++ b/net/packet/af_packet.c +@@ -4176,7 +4176,7 @@ static int packet_set_ring(struct sock *sk, union tpacket_req_u *req_u, + + /* Opening a Tx-ring is NOT supported in TPACKET_V3 */ + if (!closing && tx_ring && (po->tp_version > TPACKET_V2)) { +- WARN(1, "Tx-ring is not supported.\n"); ++ net_warn_ratelimited("Tx-ring is not supported.\n"); + goto out; + } + +-- +2.20.1 + diff --git a/queue-4.4/series b/queue-4.4/series index b824e8010c7..e98fe4bfe74 100644 --- a/queue-4.4/series +++ b/queue-4.4/series @@ -5,3 +5,4 @@ vhost-test-fix-build-for-vhost-test.patch scripts-decode_stacktrace-match-basepath-using-shell.patch clk-s2mps11-add-used-attribute-to-s2mps11_dt_match.patch x86-boot-remove-multiple-copy-of-static-function-sanitize_boot_params.patch +af_packet-tone-down-the-tx-ring-unsupported-spew.patch -- 2.47.3