From: Sasha Levin Date: Sun, 17 Jan 2021 21:27:10 +0000 (-0500) Subject: Fixes for 4.9 X-Git-Tag: v4.19.169~13 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=95fa13f2251cda27aedf4f48922c15a5e021a4b8;p=thirdparty%2Fkernel%2Fstable-queue.git Fixes for 4.9 Signed-off-by: Sasha Levin --- diff --git a/queue-4.9/acpi-scan-add-stub-acpi_create_platform_device-for-c.patch b/queue-4.9/acpi-scan-add-stub-acpi_create_platform_device-for-c.patch new file mode 100644 index 00000000000..3627a7f3b32 --- /dev/null +++ b/queue-4.9/acpi-scan-add-stub-acpi_create_platform_device-for-c.patch @@ -0,0 +1,41 @@ +From 44bee8c89f682fe7adc98fccabae751b3779c819 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Thu, 31 Dec 2020 19:35:25 +0800 +Subject: ACPI: scan: add stub acpi_create_platform_device() for !CONFIG_ACPI + +From: Shawn Guo + +[ Upstream commit ee61cfd955a64a58ed35cbcfc54068fcbd486945 ] + +It adds a stub acpi_create_platform_device() for !CONFIG_ACPI build, so +that caller doesn't have to deal with !CONFIG_ACPI build issue. + +Reported-by: kernel test robot +Signed-off-by: Shawn Guo +Signed-off-by: Rafael J. Wysocki +Signed-off-by: Sasha Levin +--- + include/linux/acpi.h | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/include/linux/acpi.h b/include/linux/acpi.h +index 5670bb9788bb4..192b045cc56ec 100644 +--- a/include/linux/acpi.h ++++ b/include/linux/acpi.h +@@ -734,6 +734,13 @@ static inline int acpi_device_modalias(struct device *dev, + return -ENODEV; + } + ++static inline struct platform_device * ++acpi_create_platform_device(struct acpi_device *adev, ++ struct property_entry *properties) ++{ ++ return NULL; ++} ++ + static inline bool acpi_dma_supported(struct acpi_device *adev) + { + return false; +-- +2.27.0 + diff --git a/queue-4.9/arc-build-add-boot_targets-to-phony.patch b/queue-4.9/arc-build-add-boot_targets-to-phony.patch new file mode 100644 index 00000000000..1a6ba61b329 --- /dev/null +++ b/queue-4.9/arc-build-add-boot_targets-to-phony.patch @@ -0,0 +1,51 @@ +From 4b3d30f41b0eb33caed074678e17ccd05c617332 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Sun, 22 Nov 2020 04:36:54 +0900 +Subject: ARC: build: add boot_targets to PHONY + +From: Masahiro Yamada + +[ Upstream commit 0cfccb3c04934cdef42ae26042139f16e805b5f7 ] + +The top-level boot_targets (uImage and uImage.*) should be phony +targets. They just let Kbuild descend into arch/arc/boot/ and create +files there. + +If a file exists in the top directory with the same name, the boot +image will not be created. + +You can confirm it by the following steps: + + $ export CROSS_COMPILE= + $ make -s ARCH=arc defconfig all # vmlinux will be built + $ touch uImage.gz + $ make ARCH=arc uImage.gz + CALL scripts/atomic/check-atomics.sh + CALL scripts/checksyscalls.sh + CHK include/generated/compile.h + # arch/arc/boot/uImage.gz is not created + +Specify the targets as PHONY to fix this. + +Signed-off-by: Masahiro Yamada +Signed-off-by: Vineet Gupta +Signed-off-by: Sasha Levin +--- + arch/arc/Makefile | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/arch/arc/Makefile b/arch/arc/Makefile +index fd79faab78926..5dc2d73c64994 100644 +--- a/arch/arc/Makefile ++++ b/arch/arc/Makefile +@@ -108,6 +108,7 @@ bootpImage: vmlinux + + boot_targets += uImage uImage.bin uImage.gz + ++PHONY += $(boot_targets) + $(boot_targets): vmlinux + $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ + +-- +2.27.0 + diff --git a/queue-4.9/arch-arc-add-copy_user_page-to-asm-page.h-to-fix-bui.patch b/queue-4.9/arch-arc-add-copy_user_page-to-asm-page.h-to-fix-bui.patch new file mode 100644 index 00000000000..933fe93a977 --- /dev/null +++ b/queue-4.9/arch-arc-add-copy_user_page-to-asm-page.h-to-fix-bui.patch @@ -0,0 +1,51 @@ +From 89b8462270e34eb26bd18fef5a357ce4f3ef0ad2 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 4 Jan 2021 19:44:53 -0800 +Subject: arch/arc: add copy_user_page() to to fix build error on + ARC + +From: Randy Dunlap + +[ Upstream commit 8a48c0a3360bf2bf4f40c980d0ec216e770e58ee ] + +fs/dax.c uses copy_user_page() but ARC does not provide that interface, +resulting in a build error. + +Provide copy_user_page() in . + +../fs/dax.c: In function 'copy_cow_page_dax': +../fs/dax.c:702:2: error: implicit declaration of function 'copy_user_page'; did you mean 'copy_to_user_page'? [-Werror=implicit-function-declaration] + +Reported-by: kernel test robot +Signed-off-by: Randy Dunlap +Cc: Vineet Gupta +Cc: linux-snps-arc@lists.infradead.org +Cc: Dan Williams +#Acked-by: Vineet Gupta # v1 +Cc: Andrew Morton +Cc: Matthew Wilcox +Cc: Jan Kara +Cc: linux-fsdevel@vger.kernel.org +Cc: linux-nvdimm@lists.01.org +#Reviewed-by: Ira Weiny # v2 +Signed-off-by: Vineet Gupta +Signed-off-by: Sasha Levin +--- + arch/arc/include/asm/page.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/arch/arc/include/asm/page.h b/arch/arc/include/asm/page.h +index ffb5f33475f19..f0f43eb709d2f 100644 +--- a/arch/arc/include/asm/page.h ++++ b/arch/arc/include/asm/page.h +@@ -13,6 +13,7 @@ + #ifndef __ASSEMBLY__ + + #define clear_page(paddr) memset((paddr), 0, PAGE_SIZE) ++#define copy_user_page(to, from, vaddr, pg) copy_page(to, from) + #define copy_page(to, from) memcpy((to), (from), PAGE_SIZE) + + struct vm_area_struct; +-- +2.27.0 + diff --git a/queue-4.9/arm-picoxcell-fix-missing-interrupt-parent-propertie.patch b/queue-4.9/arm-picoxcell-fix-missing-interrupt-parent-propertie.patch new file mode 100644 index 00000000000..03b44359bb4 --- /dev/null +++ b/queue-4.9/arm-picoxcell-fix-missing-interrupt-parent-propertie.patch @@ -0,0 +1,66 @@ +From 9dc9087f5968ad17156aac9be32b222168953c49 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Wed, 30 Dec 2020 16:20:05 +0100 +Subject: ARM: picoxcell: fix missing interrupt-parent properties + +From: Arnd Bergmann + +[ Upstream commit bac717171971176b78c72d15a8b6961764ab197f ] + +dtc points out that the interrupts for some devices are not parsable: + +picoxcell-pc3x2.dtsi:45.19-49.5: Warning (interrupts_property): /paxi/gem@30000: Missing interrupt-parent +picoxcell-pc3x2.dtsi:51.21-55.5: Warning (interrupts_property): /paxi/dmac@40000: Missing interrupt-parent +picoxcell-pc3x2.dtsi:57.21-61.5: Warning (interrupts_property): /paxi/dmac@50000: Missing interrupt-parent +picoxcell-pc3x2.dtsi:233.21-237.5: Warning (interrupts_property): /rwid-axi/axi2pico@c0000000: Missing interrupt-parent + +There are two VIC instances, so it's not clear which one needs to be +used. I found the BSP sources that reference VIC0, so use that: + +https://github.com/r1mikey/meta-picoxcell/blob/master/recipes-kernel/linux/linux-picochip-3.0/0001-picoxcell-support-for-Picochip-picoXcell-SoC.patch + +Acked-by: Jamie Iles +Link: https://lore.kernel.org/r/20201230152010.3914962-1-arnd@kernel.org' +Signed-off-by: Arnd Bergmann +Signed-off-by: Sasha Levin +--- + arch/arm/boot/dts/picoxcell-pc3x2.dtsi | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/arch/arm/boot/dts/picoxcell-pc3x2.dtsi b/arch/arm/boot/dts/picoxcell-pc3x2.dtsi +index 533919e96eaee..f22a6b4363177 100644 +--- a/arch/arm/boot/dts/picoxcell-pc3x2.dtsi ++++ b/arch/arm/boot/dts/picoxcell-pc3x2.dtsi +@@ -54,18 +54,21 @@ + emac: gem@30000 { + compatible = "cadence,gem"; + reg = <0x30000 0x10000>; ++ interrupt-parent = <&vic0>; + interrupts = <31>; + }; + + dmac1: dmac@40000 { + compatible = "snps,dw-dmac"; + reg = <0x40000 0x10000>; ++ interrupt-parent = <&vic0>; + interrupts = <25>; + }; + + dmac2: dmac@50000 { + compatible = "snps,dw-dmac"; + reg = <0x50000 0x10000>; ++ interrupt-parent = <&vic0>; + interrupts = <26>; + }; + +@@ -243,6 +246,7 @@ + axi2pico@c0000000 { + compatible = "picochip,axi2pico-pc3x2"; + reg = <0xc0000000 0x10000>; ++ interrupt-parent = <&vic0>; + interrupts = <13 14 15 16 17 18 19 20 21>; + }; + }; +-- +2.27.0 + diff --git a/queue-4.9/ethernet-ucc_geth-fix-definition-and-size-of-ucc_get.patch b/queue-4.9/ethernet-ucc_geth-fix-definition-and-size-of-ucc_get.patch new file mode 100644 index 00000000000..a517937fa0c --- /dev/null +++ b/queue-4.9/ethernet-ucc_geth-fix-definition-and-size-of-ucc_get.patch @@ -0,0 +1,64 @@ +From 345f5e66bc0a462c028e9ca5cb14140285b0f084 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Fri, 18 Dec 2020 11:55:37 +0100 +Subject: ethernet: ucc_geth: fix definition and size of + ucc_geth_tx_global_pram + +From: Rasmus Villemoes + +[ Upstream commit 887078de2a23689e29d6fa1b75d7cbc544c280be ] + +Table 8-53 in the QUICC Engine Reference manual shows definitions of +fields up to a size of 192 bytes, not just 128. But in table 8-111, +one does find the text + + Base Address of the Global Transmitter Parameter RAM Page. [...] + The user needs to allocate 128 bytes for this page. The address must + be aligned to the page size. + +I've checked both rev. 7 (11/2015) and rev. 9 (05/2018) of the manual; +they both have this inconsistency (and the table numbers are the +same). + +Adding a bit of debug printing, on my board the struct +ucc_geth_tx_global_pram is allocated at offset 0x880, while +the (opaque) ucc_geth_thread_data_tx gets allocated immediately +afterwards, at 0x900. So whatever the engine writes into the thread +data overlaps with the tail of the global tx pram (and devmem says +that something does get written during a simple ping). + +I haven't observed any failure that could be attributed to this, but +it seems to be the kind of thing that would be extremely hard to +debug. So extend the struct definition so that we do allocate 192 +bytes. + +Signed-off-by: Rasmus Villemoes +Signed-off-by: Jakub Kicinski +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/freescale/ucc_geth.h | 9 ++++++++- + 1 file changed, 8 insertions(+), 1 deletion(-) + +diff --git a/drivers/net/ethernet/freescale/ucc_geth.h b/drivers/net/ethernet/freescale/ucc_geth.h +index 5da19b440a6a8..bf25e49d4fe34 100644 +--- a/drivers/net/ethernet/freescale/ucc_geth.h ++++ b/drivers/net/ethernet/freescale/ucc_geth.h +@@ -580,7 +580,14 @@ struct ucc_geth_tx_global_pram { + u32 vtagtable[0x8]; /* 8 4-byte VLAN tags */ + u32 tqptr; /* a base pointer to the Tx Queues Memory + Region */ +- u8 res2[0x80 - 0x74]; ++ u8 res2[0x78 - 0x74]; ++ u64 snums_en; ++ u32 l2l3baseptr; /* top byte consists of a few other bit fields */ ++ ++ u16 mtu[8]; ++ u8 res3[0xa8 - 0x94]; ++ u32 wrrtablebase; /* top byte is reserved */ ++ u8 res4[0xc0 - 0xac]; + } __packed; + + /* structure representing Extended Filtering Global Parameters in PRAM */ +-- +2.27.0 + diff --git a/queue-4.9/misdn-dsp-select-config_bitreverse.patch b/queue-4.9/misdn-dsp-select-config_bitreverse.patch new file mode 100644 index 00000000000..bb73da33745 --- /dev/null +++ b/queue-4.9/misdn-dsp-select-config_bitreverse.patch @@ -0,0 +1,37 @@ +From 9c3de2838adda0698f3a35e6268daf8c7f46dec7 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Sun, 3 Jan 2021 22:36:22 +0100 +Subject: misdn: dsp: select CONFIG_BITREVERSE + +From: Arnd Bergmann + +[ Upstream commit 51049bd903a81307f751babe15a1df8d197884e8 ] + +Without this, we run into a link error + +arm-linux-gnueabi-ld: drivers/isdn/mISDN/dsp_audio.o: in function `dsp_audio_generate_law_tables': +(.text+0x30c): undefined reference to `byte_rev_table' +arm-linux-gnueabi-ld: drivers/isdn/mISDN/dsp_audio.o:(.text+0x5e4): more undefined references to `byte_rev_table' follow + +Signed-off-by: Arnd Bergmann +Signed-off-by: David S. Miller +Signed-off-by: Sasha Levin +--- + drivers/isdn/mISDN/Kconfig | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/drivers/isdn/mISDN/Kconfig b/drivers/isdn/mISDN/Kconfig +index c0730d5c734d6..fb61181a5c4f7 100644 +--- a/drivers/isdn/mISDN/Kconfig ++++ b/drivers/isdn/mISDN/Kconfig +@@ -12,6 +12,7 @@ if MISDN != n + config MISDN_DSP + tristate "Digital Audio Processing of transparent data" + depends on MISDN ++ select BITREVERSE + help + Enable support for digital audio processing capability. + +-- +2.27.0 + diff --git a/queue-4.9/net-ethernet-fs_enet-add-missing-module_license.patch b/queue-4.9/net-ethernet-fs_enet-add-missing-module_license.patch new file mode 100644 index 00000000000..819ae2a6a10 --- /dev/null +++ b/queue-4.9/net-ethernet-fs_enet-add-missing-module_license.patch @@ -0,0 +1,48 @@ +From 1837a1a26e57b44fbcdf70d923236c36b41e8434 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Tue, 5 Jan 2021 20:15:15 +1100 +Subject: net: ethernet: fs_enet: Add missing MODULE_LICENSE + +From: Michael Ellerman + +[ Upstream commit 445c6198fe7be03b7d38e66fe8d4b3187bc251d4 ] + +Since commit 1d6cd3929360 ("modpost: turn missing MODULE_LICENSE() +into error") the ppc32_allmodconfig build fails with: + + ERROR: modpost: missing MODULE_LICENSE() in drivers/net/ethernet/freescale/fs_enet/mii-fec.o + ERROR: modpost: missing MODULE_LICENSE() in drivers/net/ethernet/freescale/fs_enet/mii-bitbang.o + +Add the missing MODULE_LICENSEs to fix the build. Both files include a +copyright header indicating they are GPL v2. + +Signed-off-by: Michael Ellerman +Reviewed-by: Andrew Lunn +Signed-off-by: David S. Miller +Signed-off-by: Sasha Levin +--- + drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c | 1 + + drivers/net/ethernet/freescale/fs_enet/mii-fec.c | 1 + + 2 files changed, 2 insertions(+) + +diff --git a/drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c b/drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c +index 1f015edcca227..3c6fc61597f7e 100644 +--- a/drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c ++++ b/drivers/net/ethernet/freescale/fs_enet/mii-bitbang.c +@@ -223,3 +223,4 @@ static struct platform_driver fs_enet_bb_mdio_driver = { + }; + + module_platform_driver(fs_enet_bb_mdio_driver); ++MODULE_LICENSE("GPL"); +diff --git a/drivers/net/ethernet/freescale/fs_enet/mii-fec.c b/drivers/net/ethernet/freescale/fs_enet/mii-fec.c +index a89267b94352a..fb2b0586469b2 100644 +--- a/drivers/net/ethernet/freescale/fs_enet/mii-fec.c ++++ b/drivers/net/ethernet/freescale/fs_enet/mii-fec.c +@@ -224,3 +224,4 @@ static struct platform_driver fs_enet_fec_mdio_driver = { + }; + + module_platform_driver(fs_enet_fec_mdio_driver); ++MODULE_LICENSE("GPL"); +-- +2.27.0 + diff --git a/queue-4.9/series b/queue-4.9/series index aa7c69a9ba0..48b2321a80f 100644 --- a/queue-4.9/series +++ b/queue-4.9/series @@ -5,3 +5,10 @@ mips-relocatable-fix-possible-boot-hangup-with-kaslr-enabled.patch acpi-scan-harden-acpi_device_add-against-device-id-overflows.patch mm-hugetlb-fix-potential-missing-huge-page-size-info.patch ext4-fix-bug-for-rename-with-rename_whiteout.patch +arc-build-add-boot_targets-to-phony.patch +ethernet-ucc_geth-fix-definition-and-size-of-ucc_get.patch +arch-arc-add-copy_user_page-to-asm-page.h-to-fix-bui.patch +misdn-dsp-select-config_bitreverse.patch +net-ethernet-fs_enet-add-missing-module_license.patch +acpi-scan-add-stub-acpi_create_platform_device-for-c.patch +arm-picoxcell-fix-missing-interrupt-parent-propertie.patch