kernel: bump 4.14 to 4.14.48
Remove upstreamed patches: generic/pending/101-clocksource-mips-gic-timer-fix-clocksource-counter-w.patch generic/pending/103-MIPS-c-r4k-fix-data-corruption-related-to-cache-coherence.patch generic/pending/182-net-qmi_wwan-add-BroadMobi-BM806U-2020-2033.patch lantiq/0025-MIPS-lantiq-gphy-Remove-reboot-remove-reset-asserts.patch Update patches that no longer apply: generic/pending/811-pci_disable_usb_common_quirks.patch ath79/0009-MIPS-ath79-add-lots-of-missing-registers.patch Fixes CVE-2018-6412. Compile-tested: octeon, x86/64. Runtime-tested: octeon, x86/64. Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be>v19.07.3_mercusys_ac12_duma
parent
7590c3c58f
commit
e52f3e9b13
@ -1,23 +0,0 @@
|
||||
From: Felix Fietkau <nbd@nbd.name>
|
||||
Date: Wed, 21 Feb 2018 13:40:12 +0100
|
||||
Subject: [PATCH] clocksource: mips-gic-timer: fix clocksource counter width
|
||||
|
||||
This code needs to use ffs instead of fls on the mask to determine the
|
||||
shift for reading the GIC_CONFIG_COUNTBITS field.
|
||||
|
||||
Fixes: e07127a077c7 ("clocksource: mips-gic-timer: Use new GIC accessor functions")
|
||||
Cc: Paul Burton <paul.burton@imgtec.com>
|
||||
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||
---
|
||||
|
||||
--- a/drivers/clocksource/mips-gic-timer.c
|
||||
+++ b/drivers/clocksource/mips-gic-timer.c
|
||||
@@ -164,7 +164,7 @@ static int __init __gic_clocksource_init
|
||||
|
||||
/* Set clocksource mask. */
|
||||
count_width = read_gic_config() & GIC_CONFIG_COUNTBITS;
|
||||
- count_width >>= __fls(GIC_CONFIG_COUNTBITS);
|
||||
+ count_width >>= __ffs(GIC_CONFIG_COUNTBITS);
|
||||
count_width *= 4;
|
||||
count_width += 32;
|
||||
gic_clocksource.mask = CLOCKSOURCE_MASK(count_width);
|
@ -1,90 +0,0 @@
|
||||
From patchwork Thu Apr 26 23:28:34 2018
|
||||
Content-Type: text/plain; charset="utf-8"
|
||||
MIME-Version: 1.0
|
||||
Content-Transfer-Encoding: 7bit
|
||||
Subject: [v2] MIPS: c-r4k: fix data corruption related to cache coherence.
|
||||
X-Patchwork-Submitter: NeilBrown <neil@brown.name>
|
||||
X-Patchwork-Id: 19259
|
||||
Message-Id: <87vacdlf8d.fsf@notabene.neil.brown.name>
|
||||
To: James Hogan <jhogan@kernel.org>
|
||||
Cc: Ralf Baechle <ralf@linux-mips.org>,
|
||||
Paul Burton <paul.burton@mips.com>, linux-mips@linux-mips.org,
|
||||
linux-kernel@vger.kernel.org
|
||||
Date: Fri, 27 Apr 2018 09:28:34 +1000
|
||||
From: NeilBrown <neil@brown.name>
|
||||
List-Id: linux-mips <linux-mips.eddie.linux-mips.org>
|
||||
|
||||
When DMA will be performed to a MIPS32 1004K CPS, the
|
||||
L1-cache for the range needs to be flushed and invalidated
|
||||
first.
|
||||
The code currently takes one of two approaches.
|
||||
1/ If the range is less than the size of the dcache, then
|
||||
HIT type requests flush/invalidate cache lines for the
|
||||
particular addresses. HIT-type requests a globalised
|
||||
by the CPS so this is safe on SMP.
|
||||
|
||||
2/ If the range is larger than the size of dcache, then
|
||||
INDEX type requests flush/invalidate the whole cache.
|
||||
INDEX type requests affect the local cache only. CPS
|
||||
does not propagate them in any way. So this invalidation
|
||||
is not safe on SMP CPS systems.
|
||||
|
||||
Data corruption due to '2' can quite easily be demonstrated by
|
||||
repeatedly "echo 3 > /proc/sys/vm/drop_caches" and then sha1sum
|
||||
a file that is several times the size of available memory.
|
||||
Dropping caches means that large contiguous extents (large than
|
||||
dcache) are more likely.
|
||||
|
||||
This was not a problem before Linux-4.8 because option 2 was
|
||||
never used if CONFIG_MIPS_CPS was defined. The commit
|
||||
which removed that apparently didn't appreciate the full
|
||||
consequence of the change.
|
||||
|
||||
We could, in theory, globalize the INDEX based flush by sending an IPI
|
||||
to other cores. These cache invalidation routines can be called with
|
||||
interrupts disabled and synchronous IPI require interrupts to be
|
||||
enabled. Asynchronous IPI may not trigger writeback soon enough.
|
||||
So we cannot use IPI in practice.
|
||||
|
||||
We can already test is IPI would be needed for an INDEX operation
|
||||
with r4k_op_needs_ipi(R4K_INDEX). If this is True then we mustn't try
|
||||
the INDEX approach as we cannot use IPI. If this is False (e.g. when
|
||||
there is only one core and hence one L1 cache) then it is safe to
|
||||
use the INDEX approach without IPI.
|
||||
|
||||
This patch avoids options 2 if r4k_op_needs_ipi(R4K_INDEX), and so
|
||||
eliminates the corruption.
|
||||
|
||||
Fixes: c00ab4896ed5 ("MIPS: Remove cpu_has_safe_index_cacheops")
|
||||
Cc: stable@vger.kernel.org # v4.8+
|
||||
Signed-off-by: NeilBrown <neil@brown.name>
|
||||
---
|
||||
arch/mips/mm/c-r4k.c | 9 ++++++---
|
||||
1 file changed, 6 insertions(+), 3 deletions(-)
|
||||
|
||||
--- a/arch/mips/mm/c-r4k.c
|
||||
+++ b/arch/mips/mm/c-r4k.c
|
||||
@@ -851,9 +851,12 @@ static void r4k_dma_cache_wback_inv(unsi
|
||||
/*
|
||||
* Either no secondary cache or the available caches don't have the
|
||||
* subset property so we have to flush the primary caches
|
||||
- * explicitly
|
||||
+ * explicitly.
|
||||
+ * If we would need IPI to perform an INDEX-type operation, then
|
||||
+ * we have to use the HIT-type alternative as IPI cannot be used
|
||||
+ * here due to interrupts possibly being disabled.
|
||||
*/
|
||||
- if (size >= dcache_size) {
|
||||
+ if (!r4k_op_needs_ipi(R4K_INDEX) && size >= dcache_size) {
|
||||
r4k_blast_dcache();
|
||||
} else {
|
||||
R4600_HIT_CACHEOP_WAR_IMPL;
|
||||
@@ -890,7 +893,7 @@ static void r4k_dma_cache_inv(unsigned l
|
||||
return;
|
||||
}
|
||||
|
||||
- if (size >= dcache_size) {
|
||||
+ if (!r4k_op_needs_ipi(R4K_INDEX) && size >= dcache_size) {
|
||||
r4k_blast_dcache();
|
||||
} else {
|
||||
R4600_HIT_CACHEOP_WAR_IMPL;
|
@ -1,28 +0,0 @@
|
||||
From 743989254ea9f132517806d8893ca9b6cf9dc86b Mon Sep 17 00:00:00 2001
|
||||
From: Pawel Dembicki <paweldembicki@gmail.com>
|
||||
Date: Sat, 24 Mar 2018 22:08:14 +0100
|
||||
Subject: [PATCH] net: qmi_wwan: add BroadMobi BM806U 2020:2033
|
||||
|
||||
BroadMobi BM806U is an Qualcomm MDM9225 based 3G/4G modem.
|
||||
Tested hardware BM806U is mounted on D-Link DWR-921-C3 router.
|
||||
The USB id is added to qmi_wwan.c to allow QMI communication with
|
||||
the BM806U.
|
||||
|
||||
Tested on 4.14 kernel and OpenWRT.
|
||||
|
||||
Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
|
||||
Signed-off-by: David S. Miller <davem@davemloft.net>
|
||||
---
|
||||
drivers/net/usb/qmi_wwan.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
--- a/drivers/net/usb/qmi_wwan.c
|
||||
+++ b/drivers/net/usb/qmi_wwan.c
|
||||
@@ -1184,6 +1184,7 @@ static const struct usb_device_id produc
|
||||
{QMI_FIXED_INTF(0x19d2, 0x2002, 4)}, /* ZTE (Vodafone) K3765-Z */
|
||||
{QMI_FIXED_INTF(0x2001, 0x7e19, 4)}, /* D-Link DWM-221 B1 */
|
||||
{QMI_FIXED_INTF(0x2001, 0x7e35, 4)}, /* D-Link DWM-222 */
|
||||
+ {QMI_FIXED_INTF(0x2020, 0x2033, 4)}, /* BroadMobi BM806U */
|
||||
{QMI_FIXED_INTF(0x0f3d, 0x68a2, 8)}, /* Sierra Wireless MC7700 */
|
||||
{QMI_FIXED_INTF(0x114f, 0x68a2, 8)}, /* Sierra Wireless MC7750 */
|
||||
{QMI_FIXED_INTF(0x1199, 0x68a2, 8)}, /* Sierra Wireless MC7710 in QMI mode */
|
@ -1,86 +0,0 @@
|
||||
From ae14aba7fc748b2da282b59a2f516a311ed1f6eb Mon Sep 17 00:00:00 2001
|
||||
From: Mathias Kresin <dev@kresin.me>
|
||||
Date: Tue, 27 Mar 2018 23:15:07 +0200
|
||||
Subject: [PATCH] MIPS: lantiq: gphy: Remove reboot/remove reset asserts
|
||||
|
||||
While doing a global software reset, these bits are not cleared and let
|
||||
some bootloader fail to initialise the GPHYs. The bootloader don't expect
|
||||
these bits to be set, as they aren't during power on.
|
||||
|
||||
The asserts were a workaround for a wrong syscon-reboot mask. With a mask
|
||||
set which includes the GPHY resets of the first reset register, the
|
||||
resets of the second reset register arn't required any more.
|
||||
|
||||
Signed-off-by: Mathias Kresin <dev@kresin.me>
|
||||
---
|
||||
drivers/soc/lantiq/gphy.c | 34 ----------------------------------
|
||||
1 file changed, 34 deletions(-)
|
||||
|
||||
--- a/drivers/soc/lantiq/gphy.c
|
||||
+++ b/drivers/soc/lantiq/gphy.c
|
||||
@@ -30,7 +30,6 @@ struct xway_gphy_priv {
|
||||
struct clk *gphy_clk_gate;
|
||||
struct reset_control *gphy_reset;
|
||||
struct reset_control *gphy_reset2;
|
||||
- struct notifier_block gphy_reboot_nb;
|
||||
void __iomem *membase;
|
||||
char *fw_name;
|
||||
};
|
||||
@@ -65,24 +64,6 @@ static const struct of_device_id xway_gp
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, xway_gphy_match);
|
||||
|
||||
-static struct xway_gphy_priv *to_xway_gphy_priv(struct notifier_block *nb)
|
||||
-{
|
||||
- return container_of(nb, struct xway_gphy_priv, gphy_reboot_nb);
|
||||
-}
|
||||
-
|
||||
-static int xway_gphy_reboot_notify(struct notifier_block *reboot_nb,
|
||||
- unsigned long code, void *unused)
|
||||
-{
|
||||
- struct xway_gphy_priv *priv = to_xway_gphy_priv(reboot_nb);
|
||||
-
|
||||
- if (priv) {
|
||||
- reset_control_assert(priv->gphy_reset);
|
||||
- reset_control_assert(priv->gphy_reset2);
|
||||
- }
|
||||
-
|
||||
- return NOTIFY_DONE;
|
||||
-}
|
||||
-
|
||||
static int xway_gphy_load(struct device *dev, struct xway_gphy_priv *priv,
|
||||
dma_addr_t *dev_addr)
|
||||
{
|
||||
@@ -216,14 +197,6 @@ static int xway_gphy_probe(struct platfo
|
||||
reset_control_deassert(priv->gphy_reset);
|
||||
reset_control_deassert(priv->gphy_reset2);
|
||||
|
||||
- /* assert the gphy reset because it can hang after a reboot: */
|
||||
- priv->gphy_reboot_nb.notifier_call = xway_gphy_reboot_notify;
|
||||
- priv->gphy_reboot_nb.priority = -1;
|
||||
-
|
||||
- ret = register_reboot_notifier(&priv->gphy_reboot_nb);
|
||||
- if (ret)
|
||||
- dev_warn(dev, "Failed to register reboot notifier\n");
|
||||
-
|
||||
platform_set_drvdata(pdev, priv);
|
||||
|
||||
return ret;
|
||||
@@ -235,17 +208,10 @@ static int xway_gphy_remove(struct platf
|
||||
struct xway_gphy_priv *priv = platform_get_drvdata(pdev);
|
||||
int ret;
|
||||
|
||||
- reset_control_assert(priv->gphy_reset);
|
||||
- reset_control_assert(priv->gphy_reset2);
|
||||
-
|
||||
iowrite32be(0, priv->membase);
|
||||
|
||||
clk_disable_unprepare(priv->gphy_clk_gate);
|
||||
|
||||
- ret = unregister_reboot_notifier(&priv->gphy_reboot_nb);
|
||||
- if (ret)
|
||||
- dev_warn(dev, "Failed to unregister reboot notifier\n");
|
||||
-
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue