kernel: bump 5.4 to 5.4.203

Merged upstream:
 bcm27xx/patches-5.4/950-1014-Revert-mailbox-avoid-timer-start-from-callback.patch
 generic/backport-5.4/080-wireguard-0021-crypto-blake2s-generic-C-library-implementation-and-.patch

Manually adapted:
 layerscape/patches-5.4/801-audio-0005-Revert-ASoC-fsl_sai-Add-support-for-SAI-new-version.patch
 oxnas/patches-5.4/100-oxnas-clk-plla-pllb.patch

Compile-tested: lantiq/xrx200
Run-tested: lantiq/xrx200

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
This commit is contained in:
Hauke Mehrtens 2022-07-03 16:46:35 +00:00 committed by AmadeusGhost
parent 6fdba51a25
commit 5adf0dcafc
72 changed files with 200 additions and 1292 deletions

View File

@ -1,2 +1,2 @@
LINUX_VERSION-5.4 = .199
LINUX_KERNEL_HASH-5.4.199 = 484c09f387656ddb6a1174c7ae6a1df81c02daba831911ad9240aa9582c16c58
LINUX_VERSION-5.4 = .203
LINUX_KERNEL_HASH-5.4.203 = fc933f5b13066cfa54aacb5e86747a167bad1d8d23972e4a03ab5ee36c29798a

View File

@ -656,8 +656,8 @@
#include <linux/types.h>
+#include <linux/in6.h>
u32 secure_ipv4_port_ephemeral(__be32 saddr, __be32 daddr, __be16 dport);
u32 secure_ipv6_port_ephemeral(const __be32 *saddr, const __be32 *daddr,
u64 secure_ipv4_port_ephemeral(__be32 saddr, __be32 daddr, __be16 dport);
u64 secure_ipv6_port_ephemeral(const __be32 *saddr, const __be32 *daddr,
--- a/include/uapi/linux/in.h
+++ b/include/uapi/linux/in.h
@@ -84,7 +84,7 @@ enum {
@ -706,7 +706,7 @@
EXPORT_SYMBOL(xfrm_parse_spi);
--- a/net/ipv4/tcp_input.c
+++ b/net/ipv4/tcp_input.c
@@ -3976,14 +3976,16 @@ static bool tcp_parse_aligned_timestamp(
@@ -3980,14 +3980,16 @@ static bool tcp_parse_aligned_timestamp(
{
const __be32 *ptr = (const __be32 *)(th + 1);

View File

@ -15,7 +15,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.org>
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -1483,6 +1483,103 @@ command_cleanup:
@@ -1494,6 +1494,103 @@ command_cleanup:
}
/*
@ -119,7 +119,7 @@ Signed-off-by: Jonathan Bell <jonathan@raspberrypi.org>
* non-error returns are a promise to giveback() the urb later
* we drop ownership so next owner (or urb unlink) can get it
*/
@@ -5384,6 +5481,7 @@ static const struct hc_driver xhci_hc_dr
@@ -5395,6 +5492,7 @@ static const struct hc_driver xhci_hc_dr
.endpoint_reset = xhci_endpoint_reset,
.check_bandwidth = xhci_check_bandwidth,
.reset_bandwidth = xhci_reset_bandwidth,

View File

@ -139,7 +139,7 @@ Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
+...
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -15143,6 +15143,14 @@ S: Maintained
@@ -15144,6 +15144,14 @@ S: Maintained
F: drivers/media/i2c/imx214.c
F: Documentation/devicetree/bindings/media/i2c/sony,imx214.txt

View File

@ -25,7 +25,7 @@ Signed-off-by: Naushir Patuck <naush@raspberrypi.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -15196,6 +15196,14 @@ T: git git://linuxtv.org/media_tree.git
@@ -15197,6 +15197,14 @@ T: git git://linuxtv.org/media_tree.git
S: Maintained
F: drivers/media/i2c/imx355.c

View File

@ -23,7 +23,7 @@ Link: https://patchwork.freedesktop.org/patch/msgid/20191126142516.630200-1-maar
--- a/drivers/dma-buf/udmabuf.c
+++ b/drivers/dma-buf/udmabuf.c
@@ -93,26 +93,10 @@ static void release_udmabuf(struct dma_b
@@ -96,26 +96,10 @@ static void release_udmabuf(struct dma_b
kfree(ubuf);
}

View File

@ -17,7 +17,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
--- a/drivers/dma-buf/udmabuf.c
+++ b/drivers/dma-buf/udmabuf.c
@@ -94,10 +94,11 @@ static void release_udmabuf(struct dma_b
@@ -97,10 +97,11 @@ static void release_udmabuf(struct dma_b
}
static const struct dma_buf_ops udmabuf_ops = {

View File

@ -27,7 +27,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
};
static vm_fault_t udmabuf_vm_fault(struct vm_fault *vmf)
@@ -104,8 +105,9 @@ static const struct dma_buf_ops udmabuf_
@@ -107,8 +108,9 @@ static const struct dma_buf_ops udmabuf_
#define SEALS_WANTED (F_SEAL_SHRINK)
#define SEALS_DENIED (F_SEAL_WRITE)
@ -39,7 +39,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
{
DEFINE_DMA_BUF_EXPORT_INFO(exp_info);
struct file *memfd = NULL;
@@ -176,6 +178,7 @@ static long udmabuf_create(const struct
@@ -179,6 +181,7 @@ static long udmabuf_create(const struct
exp_info.priv = ubuf;
exp_info.flags = O_RDWR;
@ -47,7 +47,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
buf = dma_buf_export(&exp_info);
if (IS_ERR(buf)) {
ret = PTR_ERR(buf);
@@ -213,7 +216,7 @@ static long udmabuf_ioctl_create(struct
@@ -216,7 +219,7 @@ static long udmabuf_ioctl_create(struct
list.offset = create.offset;
list.size = create.size;
@ -56,7 +56,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
}
static long udmabuf_ioctl_create_list(struct file *filp, unsigned long arg)
@@ -232,7 +235,7 @@ static long udmabuf_ioctl_create_list(st
@@ -235,7 +238,7 @@ static long udmabuf_ioctl_create_list(st
if (IS_ERR(list))
return PTR_ERR(list);

View File

@ -17,7 +17,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
--- a/drivers/dma-buf/udmabuf.c
+++ b/drivers/dma-buf/udmabuf.c
@@ -47,10 +47,10 @@ static int mmap_udmabuf(struct dma_buf *
@@ -50,10 +50,10 @@ static int mmap_udmabuf(struct dma_buf *
return 0;
}
@ -31,7 +31,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
struct sg_table *sg;
int ret;
@@ -62,7 +62,7 @@ static struct sg_table *map_udmabuf(stru
@@ -65,7 +65,7 @@ static struct sg_table *map_udmabuf(stru
GFP_KERNEL);
if (ret < 0)
goto err;
@ -40,7 +40,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
ret = -EINVAL;
goto err;
}
@@ -74,13 +74,25 @@ err:
@@ -77,13 +77,25 @@ err:
return ERR_PTR(ret);
}

View File

@ -29,7 +29,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
struct miscdevice *device;
};
@@ -98,20 +99,58 @@ static void unmap_udmabuf(struct dma_buf
@@ -101,20 +102,58 @@ static void unmap_udmabuf(struct dma_buf
static void release_udmabuf(struct dma_buf *buf)
{
struct udmabuf *ubuf = buf->priv;

View File

@ -37,7 +37,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
--- a/drivers/dma-buf/udmabuf.c
+++ b/drivers/dma-buf/udmabuf.c
@@ -122,9 +122,8 @@ static int begin_cpu_udmabuf(struct dma_
@@ -125,9 +125,8 @@ static int begin_cpu_udmabuf(struct dma_
if (IS_ERR(ubuf->sg))
return PTR_ERR(ubuf->sg);
} else {
@ -49,7 +49,7 @@ Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
}
return 0;
@@ -139,7 +138,7 @@ static int end_cpu_udmabuf(struct dma_bu
@@ -142,7 +141,7 @@ static int end_cpu_udmabuf(struct dma_bu
if (!ubuf->sg)
return -EINVAL;

View File

@ -81,7 +81,7 @@ Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
+ };
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -15200,6 +15200,14 @@ S: Maintained
@@ -15201,6 +15201,14 @@ S: Maintained
F: drivers/media/i2c/imx274.c
F: Documentation/devicetree/bindings/media/i2c/imx274.txt

View File

@ -88,7 +88,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
+ tristate
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -1,13 +1,13 @@
@@ -1,16 +1,16 @@
# SPDX-License-Identifier: GPL-2.0
-obj-$(CONFIG_CRYPTO_LIB_AES) += libaes.o
@ -110,3 +110,6 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
-libsha256-y := sha256.o
+obj-$(CONFIG_CRYPTO_LIB_SHA256) += libsha256.o
+libsha256-y := sha256.o
obj-y += libblake2s.o
libblake2s-y += blake2s.o blake2s-generic.o

View File

@ -193,7 +193,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
/* 32-bit stream position, then 96-bit nonce (RFC7539 convention) */
#define CHACHA_IV_SIZE 16
@@ -29,26 +28,70 @@
@@ -29,27 +28,71 @@
/* 192-bit nonce, then 64-bit stream position */
#define XCHACHA_IV_SIZE 32
@ -278,7 +278,8 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
+ chacha_crypt(state, dst, src, bytes, 20);
+}
#endif /* _CRYPTO_CHACHA_H */
enum chacha_constants { /* expand 32-byte k */
CHACHA_CONSTANT_EXPA = 0x61707865U,
--- /dev/null
+++ b/include/crypto/internal/chacha.h
@@ -0,0 +1,53 @@

View File

@ -28,7 +28,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/arch/arm/crypto/Kconfig
+++ b/arch/arm/crypto/Kconfig
@@ -127,10 +127,8 @@ config CRYPTO_CRC32_ARM_CE
@@ -129,10 +129,8 @@ config CRYPTO_CRC32_ARM_CE
select CRYPTO_HASH
config CRYPTO_CHACHA20_NEON
@ -42,7 +42,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
tristate "NEON accelerated NHPoly1305 hash function (for Adiantum)"
--- a/arch/arm/crypto/Makefile
+++ b/arch/arm/crypto/Makefile
@@ -53,7 +53,8 @@ aes-arm-ce-y := aes-ce-core.o aes-ce-glu
@@ -33,7 +33,8 @@ aes-arm-ce-y := aes-ce-core.o aes-ce-glu
ghash-arm-ce-y := ghash-ce-core.o ghash-ce-glue.o
crct10dif-arm-ce-y := crct10dif-ce-core.o crct10dif-ce-glue.o
crc32-arm-ce-y:= crc32-ce-core.o crc32-ce-glue.o

View File

@ -25,7 +25,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/arch/arm/crypto/Kconfig
+++ b/arch/arm/crypto/Kconfig
@@ -129,6 +129,7 @@ config CRYPTO_CRC32_ARM_CE
@@ -131,6 +131,7 @@ config CRYPTO_CRC32_ARM_CE
config CRYPTO_CHACHA20_NEON
tristate "NEON and scalar accelerated ChaCha stream cipher algorithms"
select CRYPTO_BLKCIPHER

View File

@ -477,7 +477,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
tristate
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -13,5 +13,8 @@ libarc4-y := arc4.o
@@ -13,6 +13,9 @@ libarc4-y := arc4.o
obj-$(CONFIG_CRYPTO_LIB_DES) += libdes.o
libdes-y := des.o
@ -486,6 +486,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
+
obj-$(CONFIG_CRYPTO_LIB_SHA256) += libsha256.o
libsha256-y := sha256.o
--- /dev/null
+++ b/lib/crypto/poly1305.c
@@ -0,0 +1,158 @@

View File

@ -34,7 +34,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/arch/arm/crypto/Kconfig
+++ b/arch/arm/crypto/Kconfig
@@ -131,6 +131,11 @@ config CRYPTO_CHACHA20_NEON
@@ -133,6 +133,11 @@ config CRYPTO_CHACHA20_NEON
select CRYPTO_BLKCIPHER
select CRYPTO_ARCH_HAVE_LIB_CHACHA
@ -55,8 +55,8 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
+obj-$(CONFIG_CRYPTO_POLY1305_ARM) += poly1305-arm.o
obj-$(CONFIG_CRYPTO_NHPOLY1305_NEON) += nhpoly1305-neon.o
ce-obj-$(CONFIG_CRYPTO_AES_ARM_CE) += aes-arm-ce.o
@@ -55,12 +56,16 @@ crct10dif-arm-ce-y := crct10dif-ce-core.
obj-$(CONFIG_CRYPTO_AES_ARM_CE) += aes-arm-ce.o
@@ -35,12 +36,16 @@ crct10dif-arm-ce-y := crct10dif-ce-core.
crc32-arm-ce-y:= crc32-ce-core.o crc32-ce-glue.o
chacha-neon-y := chacha-scalar-core.o chacha-glue.o
chacha-neon-$(CONFIG_KERNEL_MODE_NEON) += chacha-neon-core.o
@ -73,7 +73,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
$(src)/sha256-core.S_shipped: $(src)/sha256-armv4.pl
$(call cmd,perl)
@@ -68,4 +73,9 @@ $(src)/sha512-core.S_shipped: $(src)/sha
@@ -48,4 +53,9 @@ $(src)/sha512-core.S_shipped: $(src)/sha
$(call cmd,perl)
endif

View File

@ -115,7 +115,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
+#endif /* CURVE25519_H */
--- a/lib/crypto/Kconfig
+++ b/lib/crypto/Kconfig
@@ -59,6 +59,31 @@ config CRYPTO_LIB_CHACHA
@@ -34,6 +34,31 @@ config CRYPTO_LIB_CHACHA
by either the generic implementation or an arch-specific one, if one
is available and enabled.
@ -149,9 +149,9 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -16,6 +16,11 @@ libblake2s-generic-y += blake2s-gener
obj-$(CONFIG_CRYPTO_LIB_BLAKE2S) += libblake2s.o
libblake2s-y += blake2s.o
@@ -10,6 +10,11 @@ libaes-y := aes.o
obj-$(CONFIG_CRYPTO_LIB_ARC4) += libarc4.o
libarc4-y := arc4.o
+obj-$(CONFIG_CRYPTO_LIB_CURVE25519_GENERIC) += libcurve25519.o
+libcurve25519-y := curve25519-fiat32.o

View File

@ -50,7 +50,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/arch/arm/crypto/Kconfig
+++ b/arch/arm/crypto/Kconfig
@@ -141,4 +141,10 @@ config CRYPTO_NHPOLY1305_NEON
@@ -143,4 +143,10 @@ config CRYPTO_NHPOLY1305_NEON
depends on KERNEL_MODE_NEON
select CRYPTO_NHPOLY1305
@ -69,9 +69,9 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
obj-$(CONFIG_CRYPTO_NHPOLY1305_NEON) += nhpoly1305-neon.o
+obj-$(CONFIG_CRYPTO_CURVE25519_NEON) += curve25519-neon.o
ce-obj-$(CONFIG_CRYPTO_AES_ARM_CE) += aes-arm-ce.o
ce-obj-$(CONFIG_CRYPTO_SHA1_ARM_CE) += sha1-arm-ce.o
@@ -58,6 +59,7 @@ chacha-neon-y := chacha-scalar-core.o ch
obj-$(CONFIG_CRYPTO_AES_ARM_CE) += aes-arm-ce.o
obj-$(CONFIG_CRYPTO_SHA1_ARM_CE) += sha1-arm-ce.o
@@ -38,6 +39,7 @@ chacha-neon-y := chacha-scalar-core.o ch
chacha-neon-$(CONFIG_KERNEL_MODE_NEON) += chacha-neon-core.o
poly1305-arm-y := poly1305-core.o poly1305-glue.o
nhpoly1305-neon-y := nh-neon-core.o nhpoly1305-neon-glue.o

View File

@ -71,7 +71,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
+#endif /* __CHACHA20POLY1305_H */
--- a/lib/crypto/Kconfig
+++ b/lib/crypto/Kconfig
@@ -119,5 +119,12 @@ config CRYPTO_LIB_POLY1305
@@ -94,5 +94,12 @@ config CRYPTO_LIB_POLY1305
by either the generic implementation or an arch-specific one, if one
is available and enabled.
@ -86,9 +86,9 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
tristate
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -16,6 +16,9 @@ libblake2s-generic-y += blake2s-gener
obj-$(CONFIG_CRYPTO_LIB_BLAKE2S) += libblake2s.o
libblake2s-y += blake2s.o
@@ -10,6 +10,9 @@ libaes-y := aes.o
obj-$(CONFIG_CRYPTO_LIB_ARC4) += libarc4.o
libarc4-y := arc4.o
+obj-$(CONFIG_CRYPTO_LIB_CHACHA20POLY1305) += libchacha20poly1305.o
+libchacha20poly1305-y += chacha20poly1305.o
@ -96,10 +96,10 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
obj-$(CONFIG_CRYPTO_LIB_CURVE25519_GENERIC) += libcurve25519.o
libcurve25519-y := curve25519-fiat32.o
libcurve25519-$(CONFIG_ARCH_SUPPORTS_INT128) := curve25519-hacl64.o
@@ -32,4 +35,5 @@ libsha256-y := sha256.o
@@ -28,4 +31,5 @@ obj-y += libblake2s.o
libblake2s-y += blake2s.o blake2s-generic.o
ifneq ($(CONFIG_CRYPTO_MANAGER_DISABLE_TESTS),y)
libblake2s-y += blake2s-selftest.o
libblake2s-y += blake2s-selftest.o
+libchacha20poly1305-y += chacha20poly1305-selftest.o
endif
--- /dev/null

View File

@ -22,9 +22,9 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -36,4 +36,5 @@ libsha256-y := sha256.o
@@ -32,4 +32,5 @@ libblake2s-y += blake2s.o blake2s-generi
ifneq ($(CONFIG_CRYPTO_MANAGER_DISABLE_TESTS),y)
libblake2s-y += blake2s-selftest.o
libblake2s-y += blake2s-selftest.o
libchacha20poly1305-y += chacha20poly1305-selftest.o
+libcurve25519-y += curve25519-selftest.o
endif

View File

@ -544,7 +544,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
void poly1305_init_arch(struct poly1305_desc_ctx *desc, const u8 *key);
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -28,7 +28,9 @@ obj-$(CONFIG_CRYPTO_LIB_DES) += libdes
@@ -22,7 +22,9 @@ obj-$(CONFIG_CRYPTO_LIB_DES) += libdes
libdes-y := des.o
obj-$(CONFIG_CRYPTO_LIB_POLY1305_GENERIC) += libpoly1305.o

View File

@ -2916,7 +2916,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
MODULE_ALIAS_CRYPTO("poly1305-simd");
--- a/lib/crypto/Kconfig
+++ b/lib/crypto/Kconfig
@@ -90,7 +90,7 @@ config CRYPTO_LIB_DES
@@ -65,7 +65,7 @@ config CRYPTO_LIB_DES
config CRYPTO_LIB_POLY1305_RSIZE
int
default 2 if MIPS

View File

@ -41,7 +41,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/lib/crypto/Makefile
+++ b/lib/crypto/Makefile
@@ -19,9 +19,12 @@ libblake2s-y += blake2s.o
@@ -13,9 +13,12 @@ libarc4-y := arc4.o
obj-$(CONFIG_CRYPTO_LIB_CHACHA20POLY1305) += libchacha20poly1305.o
libchacha20poly1305-y += chacha20poly1305.o

View File

@ -192,7 +192,7 @@ Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -17584,6 +17584,14 @@ L: linux-gpio@vger.kernel.org
@@ -17585,6 +17585,14 @@ L: linux-gpio@vger.kernel.org
S: Maintained
F: drivers/gpio/gpio-ws16c48.c

View File

@ -10,7 +10,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2235,6 +2235,28 @@ static int mtk_start_dma(struct mtk_eth
@@ -2252,6 +2252,28 @@ static int mtk_start_dma(struct mtk_eth
return 0;
}
@ -39,7 +39,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
static int mtk_open(struct net_device *dev)
{
struct mtk_mac *mac = netdev_priv(dev);
@@ -2430,8 +2452,6 @@ static int mtk_hw_init(struct mtk_eth *e
@@ -2447,8 +2469,6 @@ static int mtk_hw_init(struct mtk_eth *e
mtk_w32(eth, 0, MTK_QDMA_DELAY_INT);
mtk_tx_irq_disable(eth, ~0);
mtk_rx_irq_disable(eth, ~0);
@ -48,7 +48,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
/* FE int grouping */
mtk_w32(eth, MTK_TX_DONE_INT, MTK_PDMA_INT_GRP1);
@@ -2440,18 +2460,7 @@ static int mtk_hw_init(struct mtk_eth *e
@@ -2457,18 +2477,7 @@ static int mtk_hw_init(struct mtk_eth *e
mtk_w32(eth, MTK_RX_DONE_INT, MTK_QDMA_INT_GRP2);
mtk_w32(eth, 0x21021000, MTK_FE_INT_GRP);

View File

@ -15,7 +15,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2239,6 +2239,9 @@ static void mtk_gdm_config(struct mtk_et
@@ -2256,6 +2256,9 @@ static void mtk_gdm_config(struct mtk_et
{
int i;
@ -25,7 +25,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
for (i = 0; i < MTK_MAC_COUNT; i++) {
u32 val = mtk_r32(eth, MTK_GDMA_FWD_CFG(i));
@@ -2277,6 +2280,8 @@ static int mtk_open(struct net_device *d
@@ -2294,6 +2297,8 @@ static int mtk_open(struct net_device *d
if (err)
return err;
@ -34,7 +34,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
napi_enable(&eth->tx_napi);
napi_enable(&eth->rx_napi);
mtk_tx_irq_enable(eth, MTK_TX_DONE_INT);
@@ -2460,8 +2465,6 @@ static int mtk_hw_init(struct mtk_eth *e
@@ -2477,8 +2482,6 @@ static int mtk_hw_init(struct mtk_eth *e
mtk_w32(eth, MTK_RX_DONE_INT, MTK_QDMA_INT_GRP2);
mtk_w32(eth, 0x21021000, MTK_FE_INT_GRP);

View File

@ -12,7 +12,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2334,6 +2334,8 @@ static int mtk_stop(struct net_device *d
@@ -2351,6 +2351,8 @@ static int mtk_stop(struct net_device *d
if (!refcount_dec_and_test(&eth->dma_refcnt))
return 0;

View File

@ -859,7 +859,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2493,14 +2493,11 @@ static int __init mtk_init(struct net_de
@@ -2510,14 +2510,11 @@ static int __init mtk_init(struct net_de
{
struct mtk_mac *mac = netdev_priv(dev);
struct mtk_eth *eth = mac->hw;

View File

@ -11,5 +11,5 @@ from backports.
- tristate
+ tristate "ARC4 cipher library"
config CRYPTO_ARCH_HAVE_LIB_BLAKE2S
config CRYPTO_ARCH_HAVE_LIB_CHACHA
tristate

View File

@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/lib/vsprintf.c
+++ b/lib/vsprintf.c
@@ -940,8 +940,10 @@ char *symbol_string(char *buf, char *end
@@ -942,8 +942,10 @@ char *symbol_string(char *buf, char *end
struct printf_spec spec, const char *fmt)
{
unsigned long value;
@ -23,7 +23,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
#endif
if (fmt[1] == 'R')
@@ -958,8 +960,14 @@ char *symbol_string(char *buf, char *end
@@ -960,8 +962,14 @@ char *symbol_string(char *buf, char *end
return string_nocheck(buf, end, sym, spec);
#else

View File

@ -9,7 +9,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -874,7 +874,8 @@ static int txd_to_idx(struct mtk_tx_ring
@@ -885,7 +885,8 @@ static int txd_to_idx(struct mtk_tx_ring
return ((void *)dma - (void *)ring->dma) / sizeof(*dma);
}
@ -19,7 +19,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
{
if (MTK_HAS_CAPS(eth->soc->caps, MTK_QDMA)) {
if (tx_buf->flags & MTK_TX_FLAGS_SINGLE0) {
@@ -906,8 +907,12 @@ static void mtk_tx_unmap(struct mtk_eth
@@ -917,8 +918,12 @@ static void mtk_tx_unmap(struct mtk_eth
tx_buf->flags = 0;
if (tx_buf->skb &&
@ -34,7 +34,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
tx_buf->skb = NULL;
}
@@ -1085,7 +1090,7 @@ err_dma:
@@ -1096,7 +1101,7 @@ err_dma:
tx_buf = mtk_desc_to_tx_buf(ring, itxd);
/* unmap dma */
@ -43,7 +43,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
itxd->txd3 = TX_DMA_LS0 | TX_DMA_OWNER_CPU;
if (!MTK_HAS_CAPS(eth->soc->caps, MTK_QDMA))
@@ -1403,7 +1408,7 @@ static int mtk_poll_tx_qdma(struct mtk_e
@@ -1417,7 +1422,7 @@ static int mtk_poll_tx_qdma(struct mtk_e
done[mac]++;
budget--;
}
@ -52,7 +52,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
ring->last_free = desc;
atomic_inc(&ring->free_count);
@@ -1440,7 +1445,7 @@ static int mtk_poll_tx_pdma(struct mtk_e
@@ -1454,7 +1459,7 @@ static int mtk_poll_tx_pdma(struct mtk_e
budget--;
}
@ -61,7 +61,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
desc = &ring->dma[cpu];
ring->last_free = desc;
@@ -1642,7 +1647,7 @@ static void mtk_tx_clean(struct mtk_eth
@@ -1656,7 +1661,7 @@ static void mtk_tx_clean(struct mtk_eth
if (ring->buf) {
for (i = 0; i < MTK_DMA_SIZE; i++)

View File

@ -12,7 +12,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -1147,17 +1147,6 @@ static void mtk_wake_queue(struct mtk_et
@@ -1158,17 +1158,6 @@ static void mtk_wake_queue(struct mtk_et
}
}
@ -30,7 +30,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
static int mtk_start_xmit(struct sk_buff *skb, struct net_device *dev)
{
struct mtk_mac *mac = netdev_priv(dev);
@@ -1178,7 +1167,7 @@ static int mtk_start_xmit(struct sk_buff
@@ -1189,7 +1178,7 @@ static int mtk_start_xmit(struct sk_buff
tx_num = mtk_cal_txd_req(skb);
if (unlikely(atomic_read(&ring->free_count) <= tx_num)) {
@ -39,7 +39,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
netif_err(eth, tx_queued, dev,
"Tx Ring full when queue awake!\n");
spin_unlock(&eth->page_lock);
@@ -1204,7 +1193,7 @@ static int mtk_start_xmit(struct sk_buff
@@ -1215,7 +1204,7 @@ static int mtk_start_xmit(struct sk_buff
goto drop;
if (unlikely(atomic_read(&ring->free_count) <= ring->thresh))

View File

@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2211,7 +2211,7 @@ static int mtk_start_dma(struct mtk_eth
@@ -2228,7 +2228,7 @@ static int mtk_start_dma(struct mtk_eth
if (MTK_HAS_CAPS(eth->soc->caps, MTK_QDMA)) {
mtk_w32(eth,
MTK_TX_WB_DDONE | MTK_TX_DMA_EN |

View File

@ -20,7 +20,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
MediaTek SoC family.
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -1249,12 +1249,13 @@ static void mtk_update_rx_cpu_idx(struct
@@ -1260,12 +1260,13 @@ static void mtk_update_rx_cpu_idx(struct
static int mtk_poll_rx(struct napi_struct *napi, int budget,
struct mtk_eth *eth)
{
@ -35,7 +35,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
while (done < budget) {
struct net_device *netdev;
@@ -1328,6 +1329,7 @@ static int mtk_poll_rx(struct napi_struc
@@ -1342,6 +1343,7 @@ static int mtk_poll_rx(struct napi_struc
else
skb_checksum_none_assert(skb);
skb->protocol = eth_type_trans(skb, netdev);
@ -43,7 +43,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (netdev->features & NETIF_F_HW_VLAN_CTAG_RX &&
(trxd.rxd2 & RX_DMA_VTAG))
@@ -1359,6 +1361,12 @@ rx_done:
@@ -1373,6 +1375,12 @@ rx_done:
mtk_update_rx_cpu_idx(eth);
}
@ -56,7 +56,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
return done;
}
@@ -1451,6 +1459,7 @@ static int mtk_poll_tx_pdma(struct mtk_e
@@ -1465,6 +1473,7 @@ static int mtk_poll_tx_pdma(struct mtk_e
static int mtk_poll_tx(struct mtk_eth *eth, int budget)
{
struct mtk_tx_ring *ring = &eth->tx_ring;
@ -64,7 +64,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
unsigned int done[MTK_MAX_DEVS];
unsigned int bytes[MTK_MAX_DEVS];
int total = 0, i;
@@ -1468,8 +1477,14 @@ static int mtk_poll_tx(struct mtk_eth *e
@@ -1482,8 +1491,14 @@ static int mtk_poll_tx(struct mtk_eth *e
continue;
netdev_completed_queue(eth->netdev[i], done[i], bytes[i]);
total += done[i];
@ -79,7 +79,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (mtk_queue_stopped(eth) &&
(atomic_read(&ring->free_count) > ring->thresh))
mtk_wake_queue(eth);
@@ -2147,6 +2162,7 @@ static irqreturn_t mtk_handle_irq_rx(int
@@ -2164,6 +2179,7 @@ static irqreturn_t mtk_handle_irq_rx(int
{
struct mtk_eth *eth = _eth;
@ -87,7 +87,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (likely(napi_schedule_prep(&eth->rx_napi))) {
mtk_rx_irq_disable(eth, MTK_RX_DONE_INT);
__napi_schedule(&eth->rx_napi);
@@ -2159,6 +2175,7 @@ static irqreturn_t mtk_handle_irq_tx(int
@@ -2176,6 +2192,7 @@ static irqreturn_t mtk_handle_irq_tx(int
{
struct mtk_eth *eth = _eth;
@ -95,7 +95,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (likely(napi_schedule_prep(&eth->tx_napi))) {
mtk_tx_irq_disable(eth, MTK_TX_DONE_INT);
__napi_schedule(&eth->tx_napi);
@@ -2335,6 +2352,9 @@ static int mtk_stop(struct net_device *d
@@ -2352,6 +2369,9 @@ static int mtk_stop(struct net_device *d
napi_disable(&eth->tx_napi);
napi_disable(&eth->rx_napi);
@ -105,7 +105,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (MTK_HAS_CAPS(eth->soc->caps, MTK_QDMA))
mtk_stop_dma(eth, MTK_QDMA_GLO_CFG);
mtk_stop_dma(eth, MTK_PDMA_GLO_CFG);
@@ -2384,6 +2404,64 @@ err_disable_clks:
@@ -2401,6 +2421,64 @@ err_disable_clks:
return ret;
}
@ -170,7 +170,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
static int mtk_hw_init(struct mtk_eth *eth)
{
int i, val, ret;
@@ -2405,9 +2483,6 @@ static int mtk_hw_init(struct mtk_eth *e
@@ -2422,9 +2500,6 @@ static int mtk_hw_init(struct mtk_eth *e
goto err_disable_pm;
}
@ -180,7 +180,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
/* disable delay and normal interrupt */
mtk_tx_irq_disable(eth, ~0);
mtk_rx_irq_disable(eth, ~0);
@@ -2446,11 +2521,10 @@ static int mtk_hw_init(struct mtk_eth *e
@@ -2463,11 +2538,10 @@ static int mtk_hw_init(struct mtk_eth *e
/* Enable RX VLan Offloading */
mtk_w32(eth, 1, MTK_CDMP_EG_CTRL);
@ -194,7 +194,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
mtk_tx_irq_disable(eth, ~0);
mtk_rx_irq_disable(eth, ~0);
@@ -2951,6 +3025,13 @@ static int mtk_probe(struct platform_dev
@@ -2971,6 +3045,13 @@ static int mtk_probe(struct platform_dev
spin_lock_init(&eth->page_lock);
spin_lock_init(&eth->tx_irq_lock);
spin_lock_init(&eth->rx_irq_lock);

View File

@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -1379,7 +1379,7 @@ static int mtk_poll_tx_qdma(struct mtk_e
@@ -1393,7 +1393,7 @@ static int mtk_poll_tx_qdma(struct mtk_e
struct mtk_tx_buf *tx_buf;
u32 cpu, dma;
@ -20,7 +20,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
dma = mtk_r32(eth, MTK_QTX_DRX_PTR);
desc = mtk_qdma_phys_to_virt(ring, cpu);
@@ -1413,6 +1413,7 @@ static int mtk_poll_tx_qdma(struct mtk_e
@@ -1427,6 +1427,7 @@ static int mtk_poll_tx_qdma(struct mtk_e
cpu = next_cpu;
}
@ -28,7 +28,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
mtk_w32(eth, cpu, MTK_QTX_CRX_PTR);
return budget;
@@ -1613,6 +1614,7 @@ static int mtk_tx_alloc(struct mtk_eth *
@@ -1627,6 +1628,7 @@ static int mtk_tx_alloc(struct mtk_eth *
atomic_set(&ring->free_count, MTK_DMA_SIZE - 2);
ring->next_free = &ring->dma[0];
ring->last_free = &ring->dma[MTK_DMA_SIZE - 1];
@ -36,7 +36,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
ring->thresh = MAX_SKB_FRAGS;
/* make sure that all changes to the dma ring are flushed before we
@@ -1626,9 +1628,7 @@ static int mtk_tx_alloc(struct mtk_eth *
@@ -1640,9 +1642,7 @@ static int mtk_tx_alloc(struct mtk_eth *
mtk_w32(eth,
ring->phys + ((MTK_DMA_SIZE - 1) * sz),
MTK_QTX_CRX_PTR);

View File

@ -31,8 +31,8 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
+ return true;
}
/* the qdma core needs scratch memory to be setup */
@@ -1271,8 +1276,7 @@ static int mtk_poll_rx(struct napi_struc
static void *mtk_max_lro_buf_alloc(gfp_t gfp_mask)
@@ -1282,8 +1287,7 @@ static int mtk_poll_rx(struct napi_struc
rxd = &ring->dma[idx];
data = ring->data[idx];

View File

@ -11,7 +11,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -1314,17 +1314,18 @@ static int mtk_poll_rx(struct napi_struc
@@ -1328,17 +1328,18 @@ static int mtk_poll_rx(struct napi_struc
goto release_desc;
}
@ -34,7 +34,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
pktlen = RX_DMA_GET_PLEN0(trxd.rxd2);
skb->dev = netdev;
skb_put(skb, pktlen);
@@ -1342,6 +1343,7 @@ static int mtk_poll_rx(struct napi_struc
@@ -1356,6 +1357,7 @@ static int mtk_poll_rx(struct napi_struc
skb_record_rx_queue(skb, 0);
napi_gro_receive(napi, skb);

View File

@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -1536,8 +1536,8 @@ static int mtk_napi_tx(struct napi_struc
@@ -1550,8 +1550,8 @@ static int mtk_napi_tx(struct napi_struc
if (status & MTK_TX_DONE_INT)
return budget;
@ -21,7 +21,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
return tx_done;
}
@@ -1570,8 +1570,9 @@ poll_again:
@@ -1584,8 +1584,9 @@ poll_again:
remain_budget -= rx_done;
goto poll_again;
}

View File

@ -18,7 +18,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
#include "mtk_eth_soc.h"
@@ -1280,13 +1281,12 @@ static int mtk_poll_rx(struct napi_struc
@@ -1291,13 +1292,12 @@ static int mtk_poll_rx(struct napi_struc
break;
/* find out which mac the packet come from. values start at 1 */
@ -37,7 +37,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
if (unlikely(mac < 0 || mac >= MTK_MAC_COUNT ||
!eth->netdev[mac]))
@@ -2271,6 +2271,9 @@ static void mtk_gdm_config(struct mtk_et
@@ -2288,6 +2288,9 @@ static void mtk_gdm_config(struct mtk_et
val |= config;

View File

@ -18,7 +18,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
#include <net/dsa.h>
#include "mtk_eth_soc.h"
@@ -1267,6 +1268,7 @@ static int mtk_poll_rx(struct napi_struc
@@ -1278,6 +1279,7 @@ static int mtk_poll_rx(struct napi_struc
struct net_device *netdev;
unsigned int pktlen;
dma_addr_t dma_addr;
@ -26,7 +26,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
int mac;
ring = mtk_get_rx_ring(eth);
@@ -1336,6 +1338,12 @@ static int mtk_poll_rx(struct napi_struc
@@ -1350,6 +1352,12 @@ static int mtk_poll_rx(struct napi_struc
skb->protocol = eth_type_trans(skb, netdev);
bytes += pktlen;

View File

@ -24,7 +24,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
+mtk_eth-y := mtk_eth_soc.o mtk_sgmii.o mtk_eth_path.o mtk_ppe.o
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2304,12 +2304,17 @@ static int mtk_open(struct net_device *d
@@ -2321,12 +2321,17 @@ static int mtk_open(struct net_device *d
/* we run 2 netdevs on the same dma ring so we only bring it up once */
if (!refcount_read(&eth->dma_refcnt)) {
@ -44,7 +44,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
napi_enable(&eth->tx_napi);
napi_enable(&eth->rx_napi);
@@ -2379,6 +2384,9 @@ static int mtk_stop(struct net_device *d
@@ -2396,6 +2401,9 @@ static int mtk_stop(struct net_device *d
mtk_dma_free(eth);
@ -54,7 +54,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
return 0;
}
@@ -3165,6 +3173,13 @@ static int mtk_probe(struct platform_dev
@@ -3185,6 +3193,13 @@ static int mtk_probe(struct platform_dev
goto err_free_dev;
}
@ -68,7 +68,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
for (i = 0; i < MTK_MAX_DEVS; i++) {
if (!eth->netdev[i])
continue;
@@ -3241,6 +3256,7 @@ static const struct mtk_soc_data mt7621_
@@ -3259,6 +3274,7 @@ static const struct mtk_soc_data mt7621_
.hw_features = MTK_HW_FEATURES,
.required_clks = MT7621_CLKS_BITMAP,
.required_pctl = false,
@ -76,7 +76,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
};
static const struct mtk_soc_data mt7622_data = {
@@ -3249,6 +3265,7 @@ static const struct mtk_soc_data mt7622_
@@ -3267,6 +3283,7 @@ static const struct mtk_soc_data mt7622_
.hw_features = MTK_HW_FEATURES,
.required_clks = MT7622_CLKS_BITMAP,
.required_pctl = false,

View File

@ -29,7 +29,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
#include <net/dsa.h>
#include "mtk_eth_soc.h"
@@ -1348,8 +1350,12 @@ static int mtk_poll_rx(struct napi_struc
@@ -1362,8 +1364,12 @@ static int mtk_poll_rx(struct napi_struc
(trxd.rxd2 & RX_DMA_VTAG))
__vlan_hwaccel_put_tag(skb, htons(ETH_P_8021Q),
RX_DMA_VID(trxd.rxd3));
@ -44,7 +44,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
skip_rx:
ring->data[idx] = new_data;
@@ -2882,6 +2888,25 @@ static int mtk_set_rxnfc(struct net_devi
@@ -2902,6 +2908,25 @@ static int mtk_set_rxnfc(struct net_devi
return ret;
}
@ -70,7 +70,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
static const struct ethtool_ops mtk_ethtool_ops = {
.get_link_ksettings = mtk_get_link_ksettings,
.set_link_ksettings = mtk_set_link_ksettings,
@@ -2913,6 +2938,7 @@ static const struct net_device_ops mtk_n
@@ -2933,6 +2958,7 @@ static const struct net_device_ops mtk_n
#ifdef CONFIG_NET_POLL_CONTROLLER
.ndo_poll_controller = mtk_poll_controller,
#endif
@ -78,7 +78,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
};
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
@@ -3178,6 +3204,10 @@ static int mtk_probe(struct platform_dev
@@ -3198,6 +3224,10 @@ static int mtk_probe(struct platform_dev
eth->base + MTK_ETH_PPE_BASE, 2);
if (err)
goto err_free_dev;

View File

@ -13,7 +13,7 @@ Signed-off-by: Mathias Kresin <dev@kresin.me>
--- a/arch/mips/lantiq/xway/sysctrl.c
+++ b/arch/mips/lantiq/xway/sysctrl.c
@@ -503,7 +503,7 @@ void __init ltq_soc_init(void)
@@ -517,7 +517,7 @@ void __init ltq_soc_init(void)
clkdev_add_pmu("1a800000.pcie", "msi", 1, 1, PMU1_PCIE2_MSI);
clkdev_add_pmu("1f106a00.pcie", "pdi", 1, 1, PMU1_PCIE2_PDI);
clkdev_add_pmu("1a800000.pcie", "ctl", 1, 1, PMU1_PCIE2_CTL);
@ -22,7 +22,7 @@ Signed-off-by: Mathias Kresin <dev@kresin.me>
clkdev_add_pmu("1da00000.usif", "NULL", 1, 0, PMU_USIF);
clkdev_add_pmu("1e103100.deu", NULL, 1, 0, PMU_DEU);
} else if (of_machine_is_compatible("lantiq,ar10")) {
@@ -511,11 +511,11 @@ void __init ltq_soc_init(void)
@@ -525,11 +525,11 @@ void __init ltq_soc_init(void)
ltq_ar10_fpi_hz(), ltq_ar10_pp32_hz());
clkdev_add_pmu("1e101000.usb", "otg", 1, 0, PMU_USB0);
clkdev_add_pmu("1e106000.usb", "otg", 1, 0, PMU_USB1);
@ -37,7 +37,7 @@ Signed-off-by: Mathias Kresin <dev@kresin.me>
clkdev_add_pmu("1e103100.deu", NULL, 1, 0, PMU_DEU);
clkdev_add_pmu("1e116000.mei", "afe", 1, 2, PMU_ANALOG_DSL_AFE);
clkdev_add_pmu("1e116000.mei", "dfe", 1, 0, PMU_DFE);
@@ -534,12 +534,12 @@ void __init ltq_soc_init(void)
@@ -548,12 +548,12 @@ void __init ltq_soc_init(void)
clkdev_add_pmu(NULL, "ahb", 1, 0, PMU_AHBM | PMU_AHBS);
clkdev_add_pmu("1da00000.usif", "NULL", 1, 0, PMU_USIF);

View File

@ -41,7 +41,7 @@ Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
/* the pci enable helper */
static int pci_enable(struct clk *clk)
{
@@ -565,4 +584,5 @@ void __init ltq_soc_init(void)
@@ -579,4 +598,5 @@ void __init ltq_soc_init(void)
clkdev_add_pmu("1e116000.mei", "dfe", 1, 0, PMU_DFE);
clkdev_add_pmu("1e100400.serial", NULL, 1, 0, PMU_ASC0);
}

View File

@ -1,6 +1,6 @@
--- a/arch/mips/lantiq/xway/sysctrl.c
+++ b/arch/mips/lantiq/xway/sysctrl.c
@@ -422,6 +422,20 @@ static void clkdev_add_clkout(void)
@@ -436,6 +436,20 @@ static void clkdev_add_clkout(void)
}
}
@ -21,7 +21,7 @@
/* bring up all register ranges that we need for basic system control */
void __init ltq_soc_init(void)
{
@@ -585,4 +599,6 @@ void __init ltq_soc_init(void)
@@ -599,4 +613,6 @@ void __init ltq_soc_init(void)
clkdev_add_pmu("1e100400.serial", NULL, 1, 0, PMU_ASC0);
}
usb_set_clock();

View File

@ -55,7 +55,7 @@ Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
#define NETIF_F_HW_TLS_RX __NETIF_F(HW_TLS_RX)
+#define NETIF_F_HW_ACCEL_MQ __NETIF_F(HW_ACCEL_MQ)
/* Finds the next feature with the highest number of the range of start till 0.
/* Finds the next feature with the highest number of the range of start-1 till 0.
*/
--- a/net/sched/sch_generic.c
+++ b/net/sched/sch_generic.c

View File

@ -101,9 +101,9 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
/* Allow broadcast MAC frames. */
for (i = ocelot->num_phys_ports + 1; i < PGID_CPU; i++) {
u32 val = ANA_PGID_PGID_PGID(GENMASK(ocelot->num_phys_ports - 1, 0));
@@ -2326,13 +2354,6 @@ int ocelot_init(struct ocelot *ocelot)
ocelot_write_rix(ocelot, 0, ANA_PGID_PGID, PGID_MCIPV4);
ocelot_write_rix(ocelot, 0, ANA_PGID_PGID, PGID_MCIPV6);
@@ -2330,13 +2358,6 @@ int ocelot_init(struct ocelot *ocelot)
ANA_PGID_PGID_PGID(GENMASK(ocelot->num_phys_ports, 0)),
ANA_PGID_PGID, PGID_MCIPV6);
- /* CPU port Injection/Extraction configuration */
- ocelot_write_rix(ocelot, QSYS_SWITCH_PORT_MODE_INGRESS_DROP_MODE |

View File

@ -105,7 +105,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
/* Basic L2 initialization */
@@ -2490,9 +2481,7 @@ EXPORT_SYMBOL(ocelot_init);
@@ -2494,9 +2485,7 @@ EXPORT_SYMBOL(ocelot_init);
void ocelot_deinit(struct ocelot *ocelot)
{
@ -115,7 +115,7 @@ Signed-off-by: David S. Miller <davem@davemloft.net>
int i;
cancel_delayed_work(&ocelot->stats_work);
@@ -2504,14 +2493,7 @@ void ocelot_deinit(struct ocelot *ocelot
@@ -2508,14 +2497,7 @@ void ocelot_deinit(struct ocelot *ocelot
for (i = 0; i < ocelot->num_phys_ports; i++) {
port = ocelot->ports[i];

View File

@ -24,7 +24,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
#define MDIO_PHYXS_VEND_IF_STATUS 0xe812
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_MASK GENMASK(7, 3)
@@ -121,6 +123,29 @@
@@ -123,6 +125,29 @@
#define VEND1_GLOBAL_INT_VEND_MASK_GLOBAL2 BIT(1)
#define VEND1_GLOBAL_INT_VEND_MASK_GLOBAL3 BIT(0)
@ -54,7 +54,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
struct aqr107_hw_stat {
const char *name;
int reg;
@@ -241,6 +266,51 @@ static int aqr_config_aneg(struct phy_de
@@ -254,6 +279,51 @@ static int aqr_config_aneg(struct phy_de
return genphy_c45_check_and_restart_aneg(phydev, changed);
}
@ -106,7 +106,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
static int aqr_config_intr(struct phy_device *phydev)
{
bool en = phydev->interrupts == PHY_INTERRUPT_ENABLED;
@@ -682,6 +752,22 @@ static struct phy_driver aqr_driver[] =
@@ -695,6 +765,22 @@ static struct phy_driver aqr_driver[] =
.ack_interrupt = aqr_ack_interrupt,
.read_status = aqr_read_status,
},
@ -129,7 +129,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
};
module_phy_driver(aqr_driver);
@@ -694,6 +780,8 @@ static struct mdio_device_id __maybe_unu
@@ -707,6 +793,8 @@ static struct mdio_device_id __maybe_unu
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR107) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQCS109) },
{ PHY_ID_MATCH_MODEL(PHY_ID_AQR405) },

View File

@ -14,7 +14,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
--- a/drivers/net/phy/aquantia_main.c
+++ b/drivers/net/phy/aquantia_main.c
@@ -299,10 +299,16 @@ static int aqr_config_aneg_set_prot(stru
@@ -312,10 +312,16 @@ static int aqr_config_aneg_set_prot(stru
phy_write_mmd(phydev, MDIO_MMD_VEND1, AQUANTIA_VND1_GSTART_RATE,
aquantia_syscfg[if_type].start_rate);

View File

@ -24,7 +24,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
#define MDIO_AN_VEND_PROV 0xc400
#define MDIO_AN_VEND_PROV_1000BASET_FULL BIT(15)
#define MDIO_AN_VEND_PROV_1000BASET_HALF BIT(14)
@@ -310,6 +313,10 @@ static int aqr_config_aneg_set_prot(stru
@@ -323,6 +326,10 @@ static int aqr_config_aneg_set_prot(stru
aquantia_syscfg[if_type].syscfg);
}

View File

@ -35,7 +35,7 @@ Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
int ocelot_init(struct ocelot *ocelot)
{
char queue_name[32];
@@ -2474,6 +2488,13 @@ int ocelot_init(struct ocelot *ocelot)
@@ -2478,6 +2492,13 @@ int ocelot_init(struct ocelot *ocelot)
"Timestamp initialization failed\n");
return ret;
}
@ -49,7 +49,7 @@ Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
}
return 0;
@@ -2488,6 +2509,8 @@ void ocelot_deinit(struct ocelot *ocelot
@@ -2492,6 +2513,8 @@ void ocelot_deinit(struct ocelot *ocelot
cancel_delayed_work(&ocelot->stats_work);
destroy_workqueue(ocelot->stats_queue);
mutex_destroy(&ocelot->stats_lock);

View File

@ -26,7 +26,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
#define MDIO_PHYXS_VEND_IF_STATUS 0xe812
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_MASK GENMASK(7, 3)
#define MDIO_PHYXS_VEND_IF_STATUS_TYPE_KR 0
@@ -153,9 +159,12 @@ struct aqr107_hw_stat {
@@ -155,9 +161,12 @@ struct aqr107_hw_stat {
const char *name;
int reg;
int size;
@ -40,7 +40,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
static const struct aqr107_hw_stat aqr107_hw_stats[] = {
SGMII_STAT("sgmii_rx_good_frames", RX_GOOD_FRAMES, 26),
SGMII_STAT("sgmii_rx_bad_frames", RX_BAD_FRAMES, 26),
@@ -167,6 +176,10 @@ static const struct aqr107_hw_stat aqr10
@@ -169,6 +178,10 @@ static const struct aqr107_hw_stat aqr10
SGMII_STAT("sgmii_tx_line_collisions", TX_LINE_COLLISIONS, 8),
SGMII_STAT("sgmii_tx_frame_alignment_err", TX_FRAME_ALIGN_ERR, 16),
SGMII_STAT("sgmii_tx_runt_frames", TX_RUNT_FRAMES, 22),
@ -51,7 +51,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
};
#define AQR107_SGMII_STAT_SZ ARRAY_SIZE(aqr107_hw_stats)
@@ -196,13 +209,13 @@ static u64 aqr107_get_stat(struct phy_de
@@ -198,13 +211,13 @@ static u64 aqr107_get_stat(struct phy_de
u64 ret;
int val;
@ -67,7 +67,7 @@ Signed-off-by: Alex Marginean <alexandru.marginean@nxp.com>
if (val < 0)
return U64_MAX;
@@ -768,18 +781,26 @@ static struct phy_driver aqr_driver[] =
@@ -781,18 +794,26 @@ static struct phy_driver aqr_driver[] =
{
PHY_ID_MATCH_MODEL(PHY_ID_AQR112),
.name = "Aquantia AQR112",

View File

@ -582,8 +582,8 @@ This reverts commit 4f7a0728b5305e2d865f543fbcffd617e03c7674.
-#define FSL_SAI_xCR3(tx, ofs) (tx ? FSL_SAI_TCR3(ofs) : FSL_SAI_RCR3(ofs))
-#define FSL_SAI_xCR4(tx, ofs) (tx ? FSL_SAI_TCR4(ofs) : FSL_SAI_RCR4(ofs))
-#define FSL_SAI_xCR5(tx, ofs) (tx ? FSL_SAI_TCR5(ofs) : FSL_SAI_RCR5(ofs))
-#define FSL_SAI_xDR(tx, ofs) (tx ? FSL_SAI_TDR(ofs) : FSL_SAI_RDR(ofs))
-#define FSL_SAI_xFR(tx, ofs) (tx ? FSL_SAI_TFR(ofs) : FSL_SAI_RFR(ofs))
-#define FSL_SAI_xDR0(tx) (tx ? FSL_SAI_TDR0 : FSL_SAI_RDR0)
-#define FSL_SAI_xFR0(tx) (tx ? FSL_SAI_TFR0 : FSL_SAI_RFR0)
+#define FSL_SAI_xCSR(tx) (tx ? FSL_SAI_TCSR : FSL_SAI_RCSR)
+#define FSL_SAI_xCR1(tx) (tx ? FSL_SAI_TCR1 : FSL_SAI_RCR1)
+#define FSL_SAI_xCR2(tx) (tx ? FSL_SAI_TCR2 : FSL_SAI_RCR2)

View File

@ -27,7 +27,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
#include <linux/serial_core.h>
#include <linux/slab.h>
#include <linux/tty_flip.h>
@@ -2394,6 +2396,54 @@ static struct uart_driver lpuart_reg = {
@@ -2391,6 +2393,54 @@ static struct uart_driver lpuart_reg = {
.cons = LPUART_CONSOLE,
};
@ -82,7 +82,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
static int lpuart_probe(struct platform_device *pdev)
{
const struct of_device_id *of_id = of_match_device(lpuart_dt_ids,
@@ -2431,6 +2481,10 @@ static int lpuart_probe(struct platform_
@@ -2428,6 +2478,10 @@ static int lpuart_probe(struct platform_
sport->port.rs485_config = lpuart_config_rs485;

View File

@ -20,7 +20,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
#include <linux/serial_core.h>
#include <linux/slab.h>
#include <linux/tty_flip.h>
@@ -1555,8 +1556,17 @@ static void lpuart32_configure(struct lp
@@ -1552,8 +1553,17 @@ static void lpuart32_configure(struct lp
static int lpuart32_startup(struct uart_port *port)
{
struct lpuart_port *sport = container_of(port, struct lpuart_port, port);

View File

@ -12,7 +12,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
--- a/drivers/tty/serial/fsl_lpuart.c
+++ b/drivers/tty/serial/fsl_lpuart.c
@@ -931,7 +931,12 @@ static void lpuart32_rxint(struct lpuart
@@ -928,7 +928,12 @@ static void lpuart32_rxint(struct lpuart
*/
sr = lpuart32_read(&sport->port, UARTSTAT);
rx = lpuart32_read(&sport->port, UARTDATA);

View File

@ -60,7 +60,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
/* Rx DMA timeout in ms, which is used to calculate Rx ring buffer size */
#define DMA_RX_TIMEOUT (10)
@@ -254,6 +261,9 @@ struct lpuart_port {
@@ -252,6 +259,9 @@ struct lpuart_port {
unsigned int txfifo_size;
unsigned int rxfifo_size;
@ -70,7 +70,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
bool lpuart_dma_tx_use;
bool lpuart_dma_rx_use;
struct dma_chan *dma_tx_chan;
@@ -279,33 +289,45 @@ struct lpuart_soc_data {
@@ -276,33 +286,45 @@ struct lpuart_soc_data {
enum lpuart_type devtype;
char iotype;
u8 reg_off;
@ -116,7 +116,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
};
static const struct of_device_id lpuart_dt_ids[] = {
@@ -320,6 +342,7 @@ MODULE_DEVICE_TABLE(of, lpuart_dt_ids);
@@ -317,6 +339,7 @@ MODULE_DEVICE_TABLE(of, lpuart_dt_ids);
/* Forward declare this for the dma callbacks*/
static void lpuart_dma_tx_complete(void *arg);
@ -124,7 +124,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
static inline bool is_layerscape_lpuart(struct lpuart_port *sport)
{
@@ -1011,19 +1034,15 @@ static irqreturn_t lpuart32_int(int irq,
@@ -1008,19 +1031,15 @@ static irqreturn_t lpuart32_int(int irq,
if ((sts & UARTSTAT_TDRE) && !sport->lpuart_dma_tx_use)
lpuart32_txint(sport);
@ -148,7 +148,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
if (lpuart_is_32(sport)) {
unsigned long sr = lpuart32_read(&sport->port, UARTSTAT);
@@ -1075,8 +1094,21 @@ static void lpuart_copy_rx_to_tty(struct
@@ -1072,8 +1091,21 @@ static void lpuart_copy_rx_to_tty(struct
writeb(cr2, sport->port.membase + UARTCR2);
}
}
@ -171,7 +171,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
spin_lock_irqsave(&sport->port.lock, flags);
@@ -1139,7 +1171,33 @@ static void lpuart_copy_rx_to_tty(struct
@@ -1136,7 +1168,33 @@ static void lpuart_copy_rx_to_tty(struct
spin_unlock_irqrestore(&sport->port.lock, flags);
tty_flip_buffer_push(port);
@ -206,7 +206,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
}
static void lpuart_dma_rx_complete(void *arg)
@@ -1147,6 +1205,8 @@ static void lpuart_dma_rx_complete(void
@@ -1144,6 +1202,8 @@ static void lpuart_dma_rx_complete(void
struct lpuart_port *sport = arg;
lpuart_copy_rx_to_tty(sport);
@ -215,7 +215,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
}
static void lpuart_timer_func(struct timer_list *t)
@@ -1154,13 +1214,78 @@ static void lpuart_timer_func(struct tim
@@ -1151,13 +1211,78 @@ static void lpuart_timer_func(struct tim
struct lpuart_port *sport = from_timer(sport, t, lpuart_timer);
lpuart_copy_rx_to_tty(sport);
@ -298,7 +298,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
int bits, baud;
struct tty_port *port = &sport->port.state->port;
struct tty_struct *tty = port->tty;
@@ -1180,6 +1305,18 @@ static inline int lpuart_start_rx_dma(st
@@ -1177,6 +1302,18 @@ static inline int lpuart_start_rx_dma(st
sport->rx_dma_rng_buf_len = (1 << (fls(sport->rx_dma_rng_buf_len) - 1));
if (sport->rx_dma_rng_buf_len < 16)
sport->rx_dma_rng_buf_len = 16;
@ -317,7 +317,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
ring->buf = kzalloc(sport->rx_dma_rng_buf_len, GFP_ATOMIC);
if (!ring->buf)
@@ -1205,32 +1342,7 @@ static inline int lpuart_start_rx_dma(st
@@ -1202,32 +1339,7 @@ static inline int lpuart_start_rx_dma(st
return ret;
}
@ -351,7 +351,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
}
static void lpuart_dma_rx_free(struct uart_port *port)
@@ -1416,8 +1528,10 @@ static void lpuart_setup_watermark(struc
@@ -1413,8 +1525,10 @@ static void lpuart_setup_watermark(struc
writeb(UARTSFIFO_RXUF, sport->port.membase + UARTSFIFO);
}
@ -363,7 +363,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
/* Restore cr2 */
writeb(cr2_saved, sport->port.membase + UARTCR2);
@@ -1438,6 +1552,7 @@ static void lpuart32_setup_watermark(str
@@ -1435,6 +1549,7 @@ static void lpuart32_setup_watermark(str
{
unsigned long val, ctrl;
unsigned long ctrl_saved;
@ -371,7 +371,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
ctrl = lpuart32_read(&sport->port, UARTCTRL);
ctrl_saved = ctrl;
@@ -1449,12 +1564,26 @@ static void lpuart32_setup_watermark(str
@@ -1446,12 +1561,26 @@ static void lpuart32_setup_watermark(str
val = lpuart32_read(&sport->port, UARTFIFO);
val |= UARTFIFO_TXFE | UARTFIFO_RXFE;
val |= UARTFIFO_TXFLUSH | UARTFIFO_RXFLUSH;
@ -399,7 +399,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
/* Restore cr2 */
lpuart32_write(&sport->port, ctrl_saved, UARTCTRL);
}
@@ -1466,17 +1595,29 @@ static void lpuart32_setup_watermark_ena
@@ -1463,17 +1592,29 @@ static void lpuart32_setup_watermark_ena
lpuart32_setup_watermark(sport);
temp = lpuart32_read(&sport->port, UARTCTRL);
@ -430,7 +430,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
static void lpuart_tx_dma_startup(struct lpuart_port *sport)
{
u32 uartbaud;
@@ -1540,19 +1681,23 @@ static int lpuart_startup(struct uart_po
@@ -1537,19 +1678,23 @@ static int lpuart_startup(struct uart_po
return 0;
}
@ -461,7 +461,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
if (!sport->lpuart_dma_tx_use)
temp |= UARTCTRL_TIE;
lpuart32_write(&sport->port, temp, UARTCTRL);
@@ -1596,12 +1741,12 @@ static int lpuart32_startup(struct uart_
@@ -1593,12 +1738,12 @@ static int lpuart32_startup(struct uart_
spin_lock_irqsave(&sport->port.lock, flags);
@ -476,7 +476,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
lpuart32_configure(sport);
spin_unlock_irqrestore(&sport->port.lock, flags);
@@ -1611,7 +1756,7 @@ static int lpuart32_startup(struct uart_
@@ -1608,7 +1753,7 @@ static int lpuart32_startup(struct uart_
static void lpuart_dma_shutdown(struct lpuart_port *sport)
{
if (sport->lpuart_dma_rx_use) {
@ -485,7 +485,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
lpuart_dma_rx_free(&sport->port);
}
@@ -1652,11 +1797,22 @@ static void lpuart32_shutdown(struct uar
@@ -1649,11 +1794,22 @@ static void lpuart32_shutdown(struct uar
spin_lock_irqsave(&port->lock, flags);
@ -510,7 +510,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
spin_unlock_irqrestore(&port->lock, flags);
@@ -1753,10 +1909,10 @@ lpuart_set_termios(struct uart_port *por
@@ -1750,10 +1906,10 @@ lpuart_set_termios(struct uart_port *por
* baud rate and restart Rx DMA path.
*
* Since timer function acqures sport->port.lock, need to stop before
@ -523,7 +523,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
lpuart_dma_rx_free(&sport->port);
}
@@ -1968,10 +2124,10 @@ lpuart32_set_termios(struct uart_port *p
@@ -1965,10 +2121,10 @@ lpuart32_set_termios(struct uart_port *p
* baud rate and restart Rx DMA path.
*
* Since timer function acqures sport->port.lock, need to stop before
@ -536,7 +536,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
lpuart_dma_rx_free(&sport->port);
}
@@ -2483,6 +2639,10 @@ static int lpuart_probe(struct platform_
@@ -2480,6 +2636,10 @@ static int lpuart_probe(struct platform_
sport->port.dev = &pdev->dev;
sport->port.type = PORT_LPUART;
sport->devtype = sdata->devtype;
@ -547,7 +547,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
ret = platform_get_irq(pdev, 0);
if (ret < 0)
return ret;
@@ -2645,7 +2805,7 @@ static int lpuart_suspend(struct device
@@ -2630,7 +2790,7 @@ static int lpuart_suspend(struct device
* Rx DMA path before suspend and start Rx DMA path on resume.
*/
if (irq_wake) {

View File

@ -12,7 +12,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
--- a/drivers/tty/serial/fsl_lpuart.c
+++ b/drivers/tty/serial/fsl_lpuart.c
@@ -1477,6 +1477,14 @@ static void lpuart32_set_mctrl(struct ua
@@ -1474,6 +1474,14 @@ static void lpuart32_set_mctrl(struct ua
temp |= UARTMODIR_TXCTSE;
lpuart32_write(port, temp, UARTMODIR);

View File

@ -16,7 +16,7 @@ Signed-off-by: Vipul Kumar <vipul_kumar@mentor.com>
--- a/drivers/tty/serial/fsl_lpuart.c
+++ b/drivers/tty/serial/fsl_lpuart.c
@@ -505,6 +505,10 @@ static void lpuart_dma_tx_complete(void
@@ -502,6 +502,10 @@ static void lpuart_dma_tx_complete(void
unsigned long flags;
spin_lock_irqsave(&sport->port.lock, flags);

View File

@ -59,7 +59,7 @@ Signed-off-by: Shrikant Bobade <Shrikant_Bobade@mentor.com>
#define UARTFIFO_RXIDEN_RDRF 0x3
#define UARTCTRL_IDLECFG 0x7
@@ -350,6 +360,11 @@ static inline bool is_layerscape_lpuart(
@@ -347,6 +357,11 @@ static inline bool is_layerscape_lpuart(
sport->devtype == LS1028A_LPUART);
}
@ -71,7 +71,7 @@ Signed-off-by: Shrikant Bobade <Shrikant_Bobade@mentor.com>
static inline bool is_imx8qxp_lpuart(struct lpuart_port *sport)
{
return sport->devtype == IMX8QXP_LPUART;
@@ -413,6 +428,33 @@ static unsigned int lpuart_get_baud_clk_
@@ -410,6 +425,33 @@ static unsigned int lpuart_get_baud_clk_
#define lpuart_enable_clks(x) __lpuart_enable_clks(x, true)
#define lpuart_disable_clks(x) __lpuart_enable_clks(x, false)
@ -105,7 +105,7 @@ Signed-off-by: Shrikant Bobade <Shrikant_Bobade@mentor.com>
static void lpuart_stop_tx(struct uart_port *port)
{
unsigned char temp;
@@ -2731,6 +2773,10 @@ static int lpuart_probe(struct platform_
@@ -2723,6 +2765,10 @@ static int lpuart_probe(struct platform_
if (ret)
goto failed_attach_port;
@ -116,7 +116,7 @@ Signed-off-by: Shrikant Bobade <Shrikant_Bobade@mentor.com>
uart_get_rs485_mode(&pdev->dev, &sport->port.rs485);
if (sport->port.rs485.flags & SER_RS485_RX_DURING_TX)
@@ -2754,6 +2800,8 @@ static int lpuart_probe(struct platform_
@@ -2746,6 +2792,8 @@ static int lpuart_probe(struct platform_
return 0;

View File

@ -22,7 +22,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
#define DRIVER_NAME "fsl-lpuart"
#define DEV_NAME "ttyLP"
@@ -859,6 +860,20 @@ static void lpuart32_start_tx(struct uar
@@ -856,6 +857,20 @@ static void lpuart32_start_tx(struct uar
}
}
@ -43,7 +43,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
/* return TIOCSER_TEMT when transmitter is not busy */
static unsigned int lpuart_tx_empty(struct uart_port *port)
{
@@ -2283,6 +2298,7 @@ static const struct uart_ops lpuart_pops
@@ -2280,6 +2295,7 @@ static const struct uart_ops lpuart_pops
.break_ctl = lpuart_break_ctl,
.startup = lpuart_startup,
.shutdown = lpuart_shutdown,
@ -51,7 +51,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
.set_termios = lpuart_set_termios,
.type = lpuart_type,
.request_port = lpuart_request_port,
@@ -2307,6 +2323,7 @@ static const struct uart_ops lpuart32_po
@@ -2304,6 +2320,7 @@ static const struct uart_ops lpuart32_po
.break_ctl = lpuart32_break_ctl,
.startup = lpuart32_startup,
.shutdown = lpuart32_shutdown,
@ -59,7 +59,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
.set_termios = lpuart32_set_termios,
.type = lpuart_type,
.request_port = lpuart_request_port,
@@ -2769,6 +2786,11 @@ static int lpuart_probe(struct platform_
@@ -2761,6 +2778,11 @@ static int lpuart_probe(struct platform_
if (ret)
goto failed_irq_request;
@ -71,7 +71,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
ret = uart_add_one_port(&lpuart_reg, &sport->port);
if (ret)
goto failed_attach_port;
@@ -2803,6 +2825,9 @@ static int lpuart_probe(struct platform_
@@ -2795,6 +2817,9 @@ static int lpuart_probe(struct platform_
failed_reset:
uart_remove_one_port(&lpuart_reg, &sport->port);
failed_attach_port:
@ -80,8 +80,8 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
+ pm_runtime_dont_use_autosuspend(&pdev->dev);
failed_irq_request:
lpuart_disable_clks(sport);
failed_clock_enable:
@@ -2829,15 +2854,41 @@ static int lpuart_remove(struct platform
return ret;
@@ -2814,15 +2839,41 @@ static int lpuart_remove(struct platform
if (sport->dma_rx_chan)
dma_release_channel(sport->dma_rx_chan);
@ -123,7 +123,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
if (lpuart_is_32(sport)) {
/* disable Rx/Tx and interrupts */
@@ -2851,10 +2902,14 @@ static int lpuart_suspend(struct device
@@ -2836,10 +2887,14 @@ static int lpuart_suspend(struct device
writeb(temp, sport->port.membase + UARTCR2);
}
@ -138,7 +138,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
if (sport->lpuart_dma_rx_use) {
/*
@@ -2885,9 +2940,6 @@ static int lpuart_suspend(struct device
@@ -2870,9 +2925,6 @@ static int lpuart_suspend(struct device
dmaengine_terminate_all(sport->dma_tx_chan);
}
@ -148,7 +148,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
return 0;
}
@@ -2895,9 +2947,11 @@ static int lpuart_resume(struct device *
@@ -2880,9 +2932,11 @@ static int lpuart_resume(struct device *
{
struct lpuart_port *sport = dev_get_drvdata(dev);
bool irq_wake = irqd_is_wakeup_set(irq_get_irq_data(sport->port.irq));
@ -162,7 +162,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
if (lpuart_is_32(sport))
lpuart32_setup_watermark_enable(sport);
@@ -2918,13 +2972,23 @@ static int lpuart_resume(struct device *
@@ -2903,13 +2957,23 @@ static int lpuart_resume(struct device *
if (lpuart_is_32(sport))
lpuart32_configure(sport);
@ -188,7 +188,7 @@ Reviewed-by: Robin Gong <yibin.gong@nxp.com>
static struct platform_driver lpuart_driver = {
.probe = lpuart_probe,
@@ -2932,7 +2996,7 @@ static struct platform_driver lpuart_dri
@@ -2917,7 +2981,7 @@ static struct platform_driver lpuart_dri
.driver = {
.name = "fsl-lpuart",
.of_match_table = lpuart_dt_ids,

View File

@ -28,7 +28,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
#include <linux/pm_domain.h>
#include <linux/pm_runtime.h>
#include <linux/reset.h>
@@ -1722,10 +1723,23 @@ static void lpuart_rx_dma_startup(struct
@@ -1719,10 +1720,23 @@ static void lpuart_rx_dma_startup(struct
}
}
@ -53,7 +53,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
unsigned char temp;
/* determine FIFO size and enable FIFO mode */
@@ -1738,14 +1752,7 @@ static int lpuart_startup(struct uart_po
@@ -1735,14 +1749,7 @@ static int lpuart_startup(struct uart_po
sport->rxfifo_size = UARTFIFO_DEPTH((temp >> UARTPFIFO_RXSIZE_OFF) &
UARTPFIFO_FIFOSIZE_MASK);
@ -69,7 +69,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
return 0;
}
@@ -1772,11 +1779,27 @@ static void lpuart32_configure(struct lp
@@ -1769,11 +1776,27 @@ static void lpuart32_configure(struct lp
lpuart32_write(&sport->port, temp, UARTCTRL);
}
@ -98,7 +98,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
unsigned long temp;
int ret;
@@ -1808,17 +1831,8 @@ static int lpuart32_startup(struct uart_
@@ -1805,17 +1828,8 @@ static int lpuart32_startup(struct uart_
sport->port.fifosize = sport->txfifo_size;
}
@ -117,7 +117,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
return 0;
}
@@ -2879,108 +2893,205 @@ static int lpuart_runtime_resume(struct
@@ -2864,108 +2878,205 @@ static int lpuart_runtime_resume(struct
return lpuart_enable_clks(sport);
};

View File

@ -14,7 +14,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
--- a/drivers/tty/serial/fsl_lpuart.c
+++ b/drivers/tty/serial/fsl_lpuart.c
@@ -2135,11 +2135,12 @@ lpuart32_set_termios(struct uart_port *p
@@ -2132,11 +2132,12 @@ lpuart32_set_termios(struct uart_port *p
{
struct lpuart_port *sport = container_of(port, struct lpuart_port, port);
unsigned long flags;
@ -28,7 +28,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
modem = lpuart32_read(&sport->port, UARTMODIR);
/*
* only support CS8 and CS7, and for CS7 must enable PE.
@@ -2176,7 +2177,9 @@ lpuart32_set_termios(struct uart_port *p
@@ -2173,7 +2174,9 @@ lpuart32_set_termios(struct uart_port *p
}
if (termios->c_cflag & CSTOPB)
@ -39,7 +39,7 @@ Signed-off-by: Fugang Duan <fugang.duan@nxp.com>
/* parity must be enabled when CS7 to match 8-bits format */
if ((termios->c_cflag & CSIZE) == CS7)
@@ -2246,6 +2249,7 @@ lpuart32_set_termios(struct uart_port *p
@@ -2243,6 +2246,7 @@ lpuart32_set_termios(struct uart_port *p
lpuart32_write(&sport->port, old_ctrl & ~(UARTCTRL_TE | UARTCTRL_RE),
UARTCTRL);

View File

@ -24,7 +24,7 @@ Signed-off-by: Peng Fan <peng.fan@nxp.com>
--- a/drivers/tty/serial/fsl_lpuart.c
+++ b/drivers/tty/serial/fsl_lpuart.c
@@ -2617,7 +2617,9 @@ static int __init lpuart32_early_console
@@ -2614,7 +2614,9 @@ static int __init lpuart32_early_console
if (!device->port.membase)
return -ENODEV;

View File

@ -335,7 +335,7 @@ Signed-off-by: Peter Chen <peter.chen@nxp.com>
int is_setup
--- a/include/linux/usb/hcd.h
+++ b/include/linux/usb/hcd.h
@@ -409,7 +409,10 @@ struct hc_driver {
@@ -411,7 +411,10 @@ struct hc_driver {
int (*find_raw_port_number)(struct usb_hcd *, int);
/* Call for power on/off the port if necessary */
int (*port_power)(struct usb_hcd *hcd, int portnum, bool enable);
@ -347,7 +347,7 @@ Signed-off-by: Peter Chen <peter.chen@nxp.com>
};
static inline int hcd_giveback_urb_in_bh(struct usb_hcd *hcd)
@@ -474,6 +477,14 @@ int usb_hcd_setup_local_mem(struct usb_h
@@ -476,6 +479,14 @@ int usb_hcd_setup_local_mem(struct usb_h
struct platform_device;
extern void usb_hcd_platform_shutdown(struct platform_device *dev);

View File

@ -20,7 +20,7 @@ Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
--- a/drivers/gpio/gpio-mvebu.c
+++ b/drivers/gpio/gpio-mvebu.c
@@ -1248,7 +1248,7 @@ static int mvebu_gpio_probe(struct platf
@@ -1251,7 +1251,7 @@ static int mvebu_gpio_probe(struct platf
* pins.
*/
for (i = 0; i < 4; i++) {

View File

@ -268,6 +268,6 @@
+ clocks = <&armclk>;
+ };
+
gic: gic@1000 {
gic: interrupt-controller@1000 {
compatible = "arm,arm11mp-gic";
interrupt-controller;

View File

@ -14,7 +14,7 @@ Signed-off-by: René van Dorst <opensource@vdorst.com>
--- a/drivers/net/ethernet/mediatek/mtk_eth_soc.c
+++ b/drivers/net/ethernet/mediatek/mtk_eth_soc.c
@@ -2944,6 +2944,7 @@ static const struct net_device_ops mtk_n
@@ -2963,6 +2963,7 @@ static const struct net_device_ops mtk_n
static int mtk_add_mac(struct mtk_eth *eth, struct device_node *np)
{
@ -22,7 +22,7 @@ Signed-off-by: René van Dorst <opensource@vdorst.com>
const __be32 *_id = of_get_property(np, "reg", NULL);
struct phylink *phylink;
int phy_mode, id, err;
@@ -3036,6 +3037,9 @@ static int mtk_add_mac(struct mtk_eth *e
@@ -3055,6 +3056,9 @@ static int mtk_add_mac(struct mtk_eth *e
eth->netdev[id]->max_mtu = MTK_MAX_RX_LENGTH - MTK_RX_ETH_HLEN;