From a6b4ceb690290401af3d4393ced7e2f38bc09e4f Mon Sep 17 00:00:00 2001 From: Paul Gortmaker Date: Wed, 4 Jul 2018 11:14:32 -0400 Subject: net: tap: drop patch for 4.13+ Signed-off-by: Paul Gortmaker --- queue/series | 1 - queue/tap-free-skb-if-flags-error.patch | 55 --------------------------------- 2 files changed, 56 deletions(-) delete mode 100644 queue/tap-free-skb-if-flags-error.patch diff --git a/queue/series b/queue/series index 3c83c12..ef9b8d0 100644 --- a/queue/series +++ b/queue/series @@ -117,7 +117,6 @@ s390-qeth-fix-early-exit-from-error-path.patch s390-qeth-fix-GSO-throughput-regression.patch sit-update-frag_off-info.patch stmmac-reset-last-TSO-segment-size-after-device-open.patch -tap-free-skb-if-flags-error.patch tcp-add-tcp_v4_fill_cb-tcp_v4_restore_cb.patch tcp-dccp-block-bh-before-arming-time_wait-timer.patch tcp-remove-buggy-call-to-tcp_v6_restore_cb.patch diff --git a/queue/tap-free-skb-if-flags-error.patch b/queue/tap-free-skb-if-flags-error.patch deleted file mode 100644 index 388a5ae..0000000 --- a/queue/tap-free-skb-if-flags-error.patch +++ /dev/null @@ -1,55 +0,0 @@ -From 61d78537843e676e7f56ac6db333db0c0529b892 Mon Sep 17 00:00:00 2001 -From: Wei Xu -Date: Fri, 1 Dec 2017 05:10:38 -0500 -Subject: [PATCH] tap: free skb if flags error - -commit 61d78537843e676e7f56ac6db333db0c0529b892 upstream. - -tap_recvmsg() supports accepting skb by msg_control after -commit 3b4ba04acca8 ("tap: support receiving skb from msg_control"), -the skb if presented should be freed within the function, otherwise -it would be leaked. - -Signed-off-by: Wei Xu -Reported-by: Matthew Rosato -Acked-by: Michael S. Tsirkin -Signed-off-by: David S. Miller - -diff --git a/drivers/net/tap.c b/drivers/net/tap.c -index e9489b88407c..0a886fda0129 100644 ---- a/drivers/net/tap.c -+++ b/drivers/net/tap.c -@@ -829,8 +829,11 @@ static ssize_t tap_do_read(struct tap_queue *q, - DEFINE_WAIT(wait); - ssize_t ret = 0; - -- if (!iov_iter_count(to)) -+ if (!iov_iter_count(to)) { -+ if (skb) -+ kfree_skb(skb); - return 0; -+ } - - if (skb) - goto put; -@@ -1154,11 +1157,14 @@ static int tap_recvmsg(struct socket *sock, struct msghdr *m, - size_t total_len, int flags) - { - struct tap_queue *q = container_of(sock, struct tap_queue, sock); -+ struct sk_buff *skb = m->msg_control; - int ret; -- if (flags & ~(MSG_DONTWAIT|MSG_TRUNC)) -+ if (flags & ~(MSG_DONTWAIT|MSG_TRUNC)) { -+ if (skb) -+ kfree_skb(skb); - return -EINVAL; -- ret = tap_do_read(q, &m->msg_iter, flags & MSG_DONTWAIT, -- m->msg_control); -+ } -+ ret = tap_do_read(q, &m->msg_iter, flags & MSG_DONTWAIT, skb); - if (ret > total_len) { - m->msg_flags |= MSG_TRUNC; - ret = flags & MSG_TRUNC ? ret : total_len; --- -2.15.0 - -- cgit 1.2.3-korg