]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 7 Jul 2016 00:44:54 +0000 (17:44 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 7 Jul 2016 00:44:54 +0000 (17:44 -0700)
added patches:
ipmr-ip6mr-initialize-the-last-assert-time-of-mfc-entries.patch
net-alx-work-around-the-dma-rx-overflow-issue.patch
sit-correct-ip-protocol-used-in-ipip6_err.patch
usb-musb-ensure-rx-reinit-occurs-for-shared_fifo-endpoints.patch
usb-musb-stop-bulk-endpoint-while-queue-is-rotated.patch
usb-quirks-add-no-lpm-quirk-for-acer-c120-led-projector.patch

queue-3.14/ipmr-ip6mr-initialize-the-last-assert-time-of-mfc-entries.patch [new file with mode: 0644]
queue-3.14/net-alx-work-around-the-dma-rx-overflow-issue.patch [new file with mode: 0644]
queue-3.14/series
queue-3.14/sit-correct-ip-protocol-used-in-ipip6_err.patch [new file with mode: 0644]
queue-3.14/usb-musb-ensure-rx-reinit-occurs-for-shared_fifo-endpoints.patch [new file with mode: 0644]
queue-3.14/usb-musb-stop-bulk-endpoint-while-queue-is-rotated.patch [new file with mode: 0644]
queue-3.14/usb-quirks-add-no-lpm-quirk-for-acer-c120-led-projector.patch [new file with mode: 0644]

diff --git a/queue-3.14/ipmr-ip6mr-initialize-the-last-assert-time-of-mfc-entries.patch b/queue-3.14/ipmr-ip6mr-initialize-the-last-assert-time-of-mfc-entries.patch
new file mode 100644 (file)
index 0000000..0df4d15
--- /dev/null
@@ -0,0 +1,47 @@
+From foo@baz Wed Jul  6 17:30:58 PDT 2016
+From: Tom Goff <thomas.goff@ll.mit.edu>
+Date: Thu, 23 Jun 2016 16:11:57 -0400
+Subject: ipmr/ip6mr: Initialize the last assert time of mfc entries.
+Status: RO
+Content-Length: 1204
+Lines: 43
+
+From: Tom Goff <thomas.goff@ll.mit.edu>
+
+[ Upstream commit 70a0dec45174c976c64b4c8c1d0898581f759948 ]
+
+This fixes wrong-interface signaling on 32-bit platforms for entries
+created when jiffies > 2^31 + MFC_ASSERT_THRESH.
+
+Signed-off-by: Tom Goff <thomas.goff@ll.mit.edu>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ net/ipv4/ipmr.c  |    4 +++-
+ net/ipv6/ip6mr.c |    1 +
+ 2 files changed, 4 insertions(+), 1 deletion(-)
+
+--- a/net/ipv4/ipmr.c
++++ b/net/ipv4/ipmr.c
+@@ -883,8 +883,10 @@ static struct mfc_cache *ipmr_cache_allo
+ {
+       struct mfc_cache *c = kmem_cache_zalloc(mrt_cachep, GFP_KERNEL);
+-      if (c)
++      if (c) {
++              c->mfc_un.res.last_assert = jiffies - MFC_ASSERT_THRESH - 1;
+               c->mfc_un.res.minvif = MAXVIFS;
++      }
+       return c;
+ }
+--- a/net/ipv6/ip6mr.c
++++ b/net/ipv6/ip6mr.c
+@@ -1076,6 +1076,7 @@ static struct mfc6_cache *ip6mr_cache_al
+       struct mfc6_cache *c = kmem_cache_zalloc(mrt_cachep, GFP_KERNEL);
+       if (c == NULL)
+               return NULL;
++      c->mfc_un.res.last_assert = jiffies - MFC_ASSERT_THRESH - 1;
+       c->mfc_un.res.minvif = MAXMIFS;
+       return c;
+ }
diff --git a/queue-3.14/net-alx-work-around-the-dma-rx-overflow-issue.patch b/queue-3.14/net-alx-work-around-the-dma-rx-overflow-issue.patch
new file mode 100644 (file)
index 0000000..2c30e27
--- /dev/null
@@ -0,0 +1,53 @@
+From foo@baz Wed Jul  6 17:30:58 PDT 2016
+From: Feng Tang <feng.tang@intel.com>
+Date: Fri, 24 Jun 2016 15:26:05 +0800
+Subject: net: alx: Work around the DMA RX overflow issue
+Status: RO
+Content-Length: 1764
+Lines: 47
+
+From: Feng Tang <feng.tang@intel.com>
+
+[ Upstream commit 881d0327db37ad917a367c77aff1afa1ee41e0a9 ]
+
+Note: This is a verified backported patch for stable 4.4 kernel, and it
+could also be applied to 4.3/4.2/4.1/3.18/3.16
+
+There is a problem with alx devices, that the network link will be
+lost in 1-5 minutes after the device is up.
+
+>From debugging without datasheet, we found the error always
+happen when the DMA RX address is set to 0x....fc0, which is very
+likely to be a HW/silicon problem.
+
+This patch will apply rx skb with 64 bytes longer space, and if the
+allocated skb has a 0x...fc0 address, it will use skb_resever(skb, 64)
+to advance the address, so that the RX overflow can be avoided.
+
+Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=70761
+Signed-off-by: Feng Tang <feng.tang@intel.com>
+Suggested-by: Eric Dumazet <edumazet@google.com>
+Tested-by: Ole Lukoie <olelukoie@mail.ru>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ drivers/net/ethernet/atheros/alx/main.c |    7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+--- a/drivers/net/ethernet/atheros/alx/main.c
++++ b/drivers/net/ethernet/atheros/alx/main.c
+@@ -86,9 +86,14 @@ static int alx_refill_rx_ring(struct alx
+       while (!cur_buf->skb && next != rxq->read_idx) {
+               struct alx_rfd *rfd = &rxq->rfd[cur];
+-              skb = __netdev_alloc_skb(alx->dev, alx->rxbuf_size, gfp);
++              skb = __netdev_alloc_skb(alx->dev, alx->rxbuf_size + 64, gfp);
+               if (!skb)
+                       break;
++
++              /* Workround for the HW RX DMA overflow issue */
++              if (((unsigned long)skb->data & 0xfff) == 0xfc0)
++                      skb_reserve(skb, 64);
++
+               dma = dma_map_single(&alx->hw.pdev->dev,
+                                    skb->data, alx->rxbuf_size,
+                                    DMA_FROM_DEVICE);
index f0ef84e6673c7633ac4a01a7b3e38c4a1dbc5f8b..0b511a1d8430c2153c714e6b4130688cda488102 100644 (file)
@@ -1 +1,7 @@
 crypto-ux500-memmove-the-right-size.patch
+sit-correct-ip-protocol-used-in-ipip6_err.patch
+ipmr-ip6mr-initialize-the-last-assert-time-of-mfc-entries.patch
+net-alx-work-around-the-dma-rx-overflow-issue.patch
+usb-quirks-add-no-lpm-quirk-for-acer-c120-led-projector.patch
+usb-musb-stop-bulk-endpoint-while-queue-is-rotated.patch
+usb-musb-ensure-rx-reinit-occurs-for-shared_fifo-endpoints.patch
diff --git a/queue-3.14/sit-correct-ip-protocol-used-in-ipip6_err.patch b/queue-3.14/sit-correct-ip-protocol-used-in-ipip6_err.patch
new file mode 100644 (file)
index 0000000..16653ec
--- /dev/null
@@ -0,0 +1,61 @@
+From foo@baz Wed Jul  6 17:30:58 PDT 2016
+From: Simon Horman <simon.horman@netronome.com>
+Date: Thu, 16 Jun 2016 17:06:19 +0900
+Subject: sit: correct IP protocol used in ipip6_err
+Status: RO
+Content-Length: 1995
+Lines: 55
+
+From: Simon Horman <simon.horman@netronome.com>
+
+[ Upstream commit d5d8760b78d0cfafe292f965f599988138b06a70 ]
+
+Since 32b8a8e59c9c ("sit: add IPv4 over IPv4 support")
+ipip6_err() may be called for packets whose IP protocol is
+IPPROTO_IPIP as well as those whose IP protocol is IPPROTO_IPV6.
+
+In the case of IPPROTO_IPIP packets the correct protocol value is not
+passed to ipv4_update_pmtu() or ipv4_redirect().
+
+This patch resolves this problem by using the IP protocol of the packet
+rather than a hard-coded value. This appears to be consistent
+with the usage of the protocol of a packet by icmp_socket_deliver()
+the caller of ipip6_err().
+
+I was able to exercise the redirect case by using a setup where an ICMP
+redirect was received for the destination of the encapsulated packet.
+However, it appears that although incorrect the protocol field is not used
+in this case and thus no problem manifests.  On inspection it does not
+appear that a problem will manifest in the fragmentation needed/update pmtu
+case either.
+
+In short I believe this is a cosmetic fix. None the less, the use of
+IPPROTO_IPV6 seems wrong and confusing.
+
+Reviewed-by: Dinan Gunawardena <dinan.gunawardena@netronome.com>
+Signed-off-by: Simon Horman <simon.horman@netronome.com>
+Acked-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+---
+ net/ipv6/sit.c |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/net/ipv6/sit.c
++++ b/net/ipv6/sit.c
+@@ -559,13 +559,13 @@ static int ipip6_err(struct sk_buff *skb
+       if (type == ICMP_DEST_UNREACH && code == ICMP_FRAG_NEEDED) {
+               ipv4_update_pmtu(skb, dev_net(skb->dev), info,
+-                               t->parms.link, 0, IPPROTO_IPV6, 0);
++                               t->parms.link, 0, iph->protocol, 0);
+               err = 0;
+               goto out;
+       }
+       if (type == ICMP_REDIRECT) {
+               ipv4_redirect(skb, dev_net(skb->dev), t->parms.link, 0,
+-                            IPPROTO_IPV6, 0);
++                            iph->protocol, 0);
+               err = 0;
+               goto out;
+       }
diff --git a/queue-3.14/usb-musb-ensure-rx-reinit-occurs-for-shared_fifo-endpoints.patch b/queue-3.14/usb-musb-ensure-rx-reinit-occurs-for-shared_fifo-endpoints.patch
new file mode 100644 (file)
index 0000000..f1a4f11
--- /dev/null
@@ -0,0 +1,46 @@
+From f3eec0cf784e0d6c47822ca6b66df3d5812af7e6 Mon Sep 17 00:00:00 2001
+From: Andrew Goodbody <andrew.goodbody@cambrionix.com>
+Date: Tue, 31 May 2016 10:05:26 -0500
+Subject: usb: musb: Ensure rx reinit occurs for shared_fifo endpoints
+
+From: Andrew Goodbody <andrew.goodbody@cambrionix.com>
+
+commit f3eec0cf784e0d6c47822ca6b66df3d5812af7e6 upstream.
+
+shared_fifo endpoints would only get a previous tx state cleared
+out, the rx state was only cleared for non shared_fifo endpoints
+Change this so that the rx state is cleared for all endpoints.
+This addresses an issue that resulted in rx packets being dropped
+silently.
+
+Signed-off-by: Andrew Goodbody <andrew.goodbody@cambrionix.com>
+Signed-off-by: Bin Liu <b-liu@ti.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/usb/musb/musb_host.c |   13 ++++++-------
+ 1 file changed, 6 insertions(+), 7 deletions(-)
+
+--- a/drivers/usb/musb/musb_host.c
++++ b/drivers/usb/musb/musb_host.c
+@@ -583,14 +583,13 @@ musb_rx_reinit(struct musb *musb, struct
+               musb_writew(ep->regs, MUSB_TXCSR, 0);
+       /* scrub all previous state, clearing toggle */
+-      } else {
+-              csr = musb_readw(ep->regs, MUSB_RXCSR);
+-              if (csr & MUSB_RXCSR_RXPKTRDY)
+-                      WARNING("rx%d, packet/%d ready?\n", ep->epnum,
+-                              musb_readw(ep->regs, MUSB_RXCOUNT));
+-
+-              musb_h_flush_rxfifo(ep, MUSB_RXCSR_CLRDATATOG);
+       }
++      csr = musb_readw(ep->regs, MUSB_RXCSR);
++      if (csr & MUSB_RXCSR_RXPKTRDY)
++              WARNING("rx%d, packet/%d ready?\n", ep->epnum,
++                      musb_readw(ep->regs, MUSB_RXCOUNT));
++
++      musb_h_flush_rxfifo(ep, MUSB_RXCSR_CLRDATATOG);
+       /* target addr and (for multipoint) hub addr/port */
+       if (musb->is_multipoint) {
diff --git a/queue-3.14/usb-musb-stop-bulk-endpoint-while-queue-is-rotated.patch b/queue-3.14/usb-musb-stop-bulk-endpoint-while-queue-is-rotated.patch
new file mode 100644 (file)
index 0000000..fe23e00
--- /dev/null
@@ -0,0 +1,45 @@
+From 7b2c17f829545df27a910e8d82e133c21c9a8c9c Mon Sep 17 00:00:00 2001
+From: Andrew Goodbody <andrew.goodbody@cambrionix.com>
+Date: Tue, 31 May 2016 10:05:27 -0500
+Subject: usb: musb: Stop bulk endpoint while queue is rotated
+
+From: Andrew Goodbody <andrew.goodbody@cambrionix.com>
+
+commit 7b2c17f829545df27a910e8d82e133c21c9a8c9c upstream.
+
+Ensure that the endpoint is stopped by clearing REQPKT before
+clearing DATAERR_NAKTIMEOUT before rotating the queue on the
+dedicated bulk endpoint.
+This addresses an issue where a race could result in the endpoint
+receiving data before it was reprogrammed resulting in a warning
+about such data from musb_rx_reinit before it was thrown away.
+The data thrown away was a valid packet that had been correctly
+ACKed which meant the host and device got out of sync.
+
+Signed-off-by: Andrew Goodbody <andrew.goodbody@cambrionix.com>
+Signed-off-by: Bin Liu <b-liu@ti.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/usb/musb/musb_host.c |    8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+--- a/drivers/usb/musb/musb_host.c
++++ b/drivers/usb/musb/musb_host.c
+@@ -950,9 +950,15 @@ static void musb_bulk_nak_timeout(struct
+       if (is_in) {
+               dma = is_dma_capable() ? ep->rx_channel : NULL;
+-              /* clear nak timeout bit */
++              /*
++               * Need to stop the transaction by clearing REQPKT first
++               * then the NAK Timeout bit ref MUSBMHDRC USB 2.0 HIGH-SPEED
++               * DUAL-ROLE CONTROLLER Programmer's Guide, section 9.2.2
++               */
+               rx_csr = musb_readw(epio, MUSB_RXCSR);
+               rx_csr |= MUSB_RXCSR_H_WZC_BITS;
++              rx_csr &= ~MUSB_RXCSR_H_REQPKT;
++              musb_writew(epio, MUSB_RXCSR, rx_csr);
+               rx_csr &= ~MUSB_RXCSR_DATAERROR;
+               musb_writew(epio, MUSB_RXCSR, rx_csr);
diff --git a/queue-3.14/usb-quirks-add-no-lpm-quirk-for-acer-c120-led-projector.patch b/queue-3.14/usb-quirks-add-no-lpm-quirk-for-acer-c120-led-projector.patch
new file mode 100644 (file)
index 0000000..e93eb46
--- /dev/null
@@ -0,0 +1,34 @@
+From 32cb0b37098f4beeff5ad9e325f11b42a6ede56c Mon Sep 17 00:00:00 2001
+From: Hans de Goede <hdegoede@redhat.com>
+Date: Thu, 19 May 2016 17:12:20 +0200
+Subject: usb: quirks: Add no-lpm quirk for Acer C120 LED Projector
+
+From: Hans de Goede <hdegoede@redhat.com>
+
+commit 32cb0b37098f4beeff5ad9e325f11b42a6ede56c upstream.
+
+The Acer C120 LED Projector is a USB-3 connected pico projector which
+takes both its power and video data from USB-3.
+
+In combination with some hubs this device does not play well with
+lpm, so disable lpm for it.
+
+Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/usb/core/quirks.c |    3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/drivers/usb/core/quirks.c
++++ b/drivers/usb/core/quirks.c
+@@ -205,6 +205,9 @@ static const struct usb_device_id usb_am
+       /* Logitech Optical Mouse M90/M100 */
+       { USB_DEVICE(0x046d, 0xc05a), .driver_info = USB_QUIRK_RESET_RESUME },
++      /* Acer C120 LED Projector */
++      { USB_DEVICE(0x1de1, 0xc102), .driver_info = USB_QUIRK_NO_LPM },
++
+       /* Blackmagic Design Intensity Shuttle */
+       { USB_DEVICE(0x1edb, 0xbd3b), .driver_info = USB_QUIRK_NO_LPM },