diff options
Diffstat (limited to 'target/linux/bcm27xx/patches-5.4/950-0630-ARM-dts-overlays-Unify-overlay-CMA-handling.patch')
-rw-r--r-- | target/linux/bcm27xx/patches-5.4/950-0630-ARM-dts-overlays-Unify-overlay-CMA-handling.patch | 871 |
1 files changed, 0 insertions, 871 deletions
diff --git a/target/linux/bcm27xx/patches-5.4/950-0630-ARM-dts-overlays-Unify-overlay-CMA-handling.patch b/target/linux/bcm27xx/patches-5.4/950-0630-ARM-dts-overlays-Unify-overlay-CMA-handling.patch deleted file mode 100644 index 3c0f1e4388..0000000000 --- a/target/linux/bcm27xx/patches-5.4/950-0630-ARM-dts-overlays-Unify-overlay-CMA-handling.patch +++ /dev/null @@ -1,871 +0,0 @@ -From 3cd31a44e61e2219d730d6b1a4a13c8e15d6e395 Mon Sep 17 00:00:00 2001 -From: Nicolas Saenz Julienne <nsaenzjulienne@suse.de> -Date: Thu, 2 Apr 2020 19:54:33 +0200 -Subject: [PATCH] ARM: dts: overlays: Unify overlay CMA handling - -Now that we don't have to abuse the kernel command line to change CMA's -size we can clean-up and centralize CMA usage in overlays. - -A new file, cma-overlay.dts is created to be used as a standalone -overlay or included on other overlays. All CMA users are converted to -this scheme. Ultimately upstream-overlay.dts is also updated to use the -default CMA size provided by upstream. - -Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de> ---- - arch/arm/boot/dts/overlays/Makefile | 1 + - arch/arm/boot/dts/overlays/README | 19 +++++ - arch/arm/boot/dts/overlays/cma-overlay.dts | 32 ++++++++ - .../boot/dts/overlays/upstream-overlay.dts | 56 ++++--------- - .../dts/overlays/upstream-pi4-overlay.dts | 66 +++++---------- - .../dts/overlays/vc4-fkms-v3d-overlay.dts | 51 ++---------- - .../boot/dts/overlays/vc4-kms-v3d-overlay.dts | 66 ++++----------- - .../dts/overlays/vc4-kms-v3d-pi4-overlay.dts | 80 +++++-------------- - 8 files changed, 129 insertions(+), 242 deletions(-) - create mode 100644 arch/arm/boot/dts/overlays/cma-overlay.dts - ---- a/arch/arm/boot/dts/overlays/Makefile -+++ b/arch/arm/boot/dts/overlays/Makefile -@@ -28,6 +28,7 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \ - audiosense-pi.dtbo \ - audremap.dtbo \ - balena-fin.dtbo \ -+ cma.dtbo \ - dht11.dtbo \ - dionaudio-loco.dtbo \ - dionaudio-loco-v2.dtbo \ ---- a/arch/arm/boot/dts/overlays/README -+++ b/arch/arm/boot/dts/overlays/README -@@ -554,6 +554,19 @@ Info: This overlay is now deprecated - - Load: <Deprecated> - - -+Name: cma -+Info: Set custom CMA sizes, only use if you know what you are doing, might -+ clash with other overlays like vc4-fkms-v3d and vc4-kms-v3d. -+Load: dtoverlay=cma,<param>=<val> -+Params: cma-256 CMA is 256MB (needs 1GB) -+ cma-192 CMA is 192MB (needs 1GB) -+ cma-128 CMA is 128MB -+ cma-96 CMA is 96MB -+ cma-64 CMA is 64MB -+ cma-size CMA size in bytes, 4MB aligned -+ cma-default Use upstream's default value -+ -+ - Name: dht11 - Info: Overlay for the DHT11/DHT21/DHT22 humidity/temperature sensors - Also sometimes found with the part number(s) AM230x. -@@ -2675,6 +2688,8 @@ Params: cma-256 CMA is 2 - cma-128 CMA is 128MB - cma-96 CMA is 96MB - cma-64 CMA is 64MB -+ cma-size CMA size in bytes, 4MB aligned -+ cma-default Use upstream's default value - - - Name: vc4-kms-kippah-7inch -@@ -2692,6 +2707,8 @@ Params: cma-256 CMA is 2 - cma-128 CMA is 128MB - cma-96 CMA is 96MB - cma-64 CMA is 64MB -+ cma-size CMA size in bytes, 4MB aligned -+ cma-default Use upstream's default value - audio Enable or disable audio over HDMI (default "on") - - -@@ -2703,6 +2720,8 @@ Params: cma-256 CMA is 2 - cma-128 CMA is 128MB - cma-96 CMA is 96MB - cma-64 CMA is 64MB -+ cma-size CMA size in bytes, 4MB aligned -+ cma-default Use upstream's default value - audio Enable or disable audio over HDMI0 (default - "on") - audio1 Enable or disable audio over HDMI1 (default ---- /dev/null -+++ b/arch/arm/boot/dts/overlays/cma-overlay.dts -@@ -0,0 +1,32 @@ -+/* -+ * cma.dts -+ */ -+ -+/dts-v1/; -+/plugin/; -+ -+/ { -+ compatible = "brcm,bcm2835"; -+ -+ fragment@0 { -+ target = <&cma>; -+ frag0: __overlay__ { -+ /* -+ * The default size when using this overlay is 256 MB -+ * and should be kept as is for backwards -+ * compatibility. -+ */ -+ size = <0x10000000>; -+ }; -+ }; -+ -+ __overrides__ { -+ cma-256 = <&frag0>,"size:0=",<0x10000000>; -+ cma-192 = <&frag0>,"size:0=",<0xC000000>; -+ cma-128 = <&frag0>,"size:0=",<0x8000000>; -+ cma-96 = <&frag0>,"size:0=",<0x6000000>; -+ cma-64 = <&frag0>,"size:0=",<0x4000000>; -+ cma-size = <&frag0>,"size:0"; /* in bytes, 4MB aligned */ -+ cma-default = <0>,"-0"; -+ }; -+}; ---- a/arch/arm/boot/dts/overlays/upstream-overlay.dts -+++ b/arch/arm/boot/dts/overlays/upstream-overlay.dts -@@ -1,4 +1,4 @@ --// redo: ovmerge -c vc4-kms-v3d-overlay.dts,cma-96 dwc2-overlay.dts,dr_mode=otg -+// redo: ovmerge -c vc4-kms-v3d-overlay.dts,cma-default dwc2-overlay.dts,dr_mode=otg - - /dts-v1/; - /plugin/; -@@ -8,114 +8,90 @@ - / { - compatible = "brcm,bcm2835"; - fragment@0 { -- target-path = "/chosen"; -+ target = <&cma>; - __dormant__ { -- bootargs = "cma=256M"; -+ size = <0x10000000>; - }; - }; - fragment@1 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=192M"; -- }; -- }; -- fragment@2 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=128M"; -- }; -- }; -- fragment@3 { -- target-path = "/chosen"; -- __overlay__ { -- bootargs = "cma=96M"; -- }; -- }; -- fragment@4 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=64M"; -- }; -- }; -- fragment@5 { - target = <&i2c2>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@6 { -+ fragment@2 { - target = <&fb>; - __overlay__ { - status = "disabled"; - }; - }; -- fragment@7 { -+ fragment@3 { - target = <&pixelvalve0>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@8 { -+ fragment@4 { - target = <&pixelvalve1>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@9 { -+ fragment@5 { - target = <&pixelvalve2>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@10 { -+ fragment@6 { - target = <&hvs>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@11 { -+ fragment@7 { - target = <&hdmi>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@12 { -+ fragment@8 { - target = <&v3d>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@13 { -+ fragment@9 { - target = <&vc4>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@14 { -+ fragment@10 { - target = <&clocks>; - __overlay__ { - claim-clocks = <BCM2835_PLLD_DSI0 BCM2835_PLLD_DSI1 BCM2835_PLLH_AUX BCM2835_PLLH_PIX>; - }; - }; -- fragment@15 { -+ fragment@11 { - target = <&vec>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@16 { -+ fragment@12 { - target = <&txp>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@17 { -+ fragment@13 { - target = <&hdmi>; - __dormant__ { - dmas; - }; - }; -- fragment@18 { -+ fragment@14 { - target = <&usb>; - #address-cells = <1>; - #size-cells = <1>; ---- a/arch/arm/boot/dts/overlays/upstream-pi4-overlay.dts -+++ b/arch/arm/boot/dts/overlays/upstream-pi4-overlay.dts -@@ -8,144 +8,120 @@ - / { - compatible = "brcm,bcm2835"; - fragment@0 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=256M"; -- }; -- }; -- fragment@1 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=192M"; -- }; -- }; -- fragment@2 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=128M"; -- }; -- }; -- fragment@3 { -- target-path = "/chosen"; -+ target = <&cma>; - __overlay__ { -- bootargs = "cma=96M"; -+ size = <100663296>; - }; - }; -- fragment@4 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=64M"; -- }; -- }; -- fragment@5 { -+ fragment@1 { - target = <&ddc0>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@6 { -+ fragment@2 { - target = <&ddc1>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@7 { -+ fragment@3 { - target = <&hdmi0>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@8 { -+ fragment@4 { - target = <&hdmi1>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@9 { -+ fragment@5 { - target = <&hvs>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@10 { -+ fragment@6 { - target = <&pixelvalve0>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@11 { -+ fragment@7 { - target = <&pixelvalve1>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@12 { -+ fragment@8 { - target = <&pixelvalve2>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@13 { -+ fragment@9 { - target = <&pixelvalve3>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@14 { -+ fragment@10 { - target = <&pixelvalve4>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@15 { -+ fragment@11 { - target = <&v3d>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@16 { -+ fragment@12 { - target = <&vc4>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@17 { -+ fragment@13 { - target = <&txp>; - __overlay__ { - status = "okay"; - }; - }; -- fragment@18 { -+ fragment@14 { - target = <&fb>; - __overlay__ { - status = "disabled"; - }; - }; -- fragment@19 { -+ fragment@15 { - target = <&firmwarekms>; - __overlay__ { - status = "disabled"; - }; - }; -- fragment@20 { -+ fragment@16 { - target = <&vec>; - __overlay__ { - status = "disabled"; - }; - }; -- fragment@21 { -+ fragment@17 { - target = <&hdmi0>; - __dormant__ { - dmas; - }; - }; -- fragment@22 { -+ fragment@18 { - target = <&hdmi1>; - __dormant__ { - dmas; - }; - }; -- fragment@23 { -+ fragment@19 { - target = <&usb>; - #address-cells = <1>; - #size-cells = <1>; ---- a/arch/arm/boot/dts/overlays/vc4-fkms-v3d-overlay.dts -+++ b/arch/arm/boot/dts/overlays/vc4-fkms-v3d-overlay.dts -@@ -5,77 +5,36 @@ - /dts-v1/; - /plugin/; - -+#include "cma-overlay.dts" -+ - / { - compatible = "brcm,bcm2835"; - -- fragment@0 { -- target-path = "/chosen"; -- __overlay__ { -- bootargs = "cma=256M"; -- }; -- }; -- - fragment@1 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=192M"; -- }; -- }; -- -- fragment@2 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=128M"; -- }; -- }; -- -- fragment@3 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=96M"; -- }; -- }; -- -- fragment@4 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=64M"; -- }; -- }; -- -- fragment@5 { - target = <&fb>; - __overlay__ { - status = "disabled"; - }; - }; - -- fragment@6 { -+ fragment@2 { - target = <&firmwarekms>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@7 { -+ fragment@3 { - target = <&v3d>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@8 { -+ fragment@4 { - target = <&vc4>; - __overlay__ { - status = "okay"; - }; - }; -- -- __overrides__ { -- cma-256 = <0>,"+0-1-2-3-4"; -- cma-192 = <0>,"-0+1-2-3-4"; -- cma-128 = <0>,"-0-1+2-3-4"; -- cma-96 = <0>,"-0-1-2+3-4"; -- cma-64 = <0>,"-0-1-2-3+4"; -- }; - }; ---- a/arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dts -+++ b/arch/arm/boot/dts/overlays/vc4-kms-v3d-overlay.dts -@@ -7,108 +7,75 @@ - - #include <dt-bindings/clock/bcm2835.h> - -+#include "cma-overlay.dts" -+ - / { - compatible = "brcm,bcm2835"; - -- fragment@0 { -- target-path = "/chosen"; -- __overlay__ { -- bootargs = "cma=256M"; -- }; -- }; -- - fragment@1 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=192M"; -- }; -- }; -- -- fragment@2 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=128M"; -- }; -- }; -- -- fragment@3 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=96M"; -- }; -- }; -- -- fragment@4 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=64M"; -- }; -- }; -- -- fragment@5 { - target = <&i2c2>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@6 { -+ fragment@2 { - target = <&fb>; - __overlay__ { - status = "disabled"; - }; - }; - -- fragment@7 { -+ fragment@3 { - target = <&pixelvalve0>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@8 { -+ fragment@4 { - target = <&pixelvalve1>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@9 { -+ fragment@5 { - target = <&pixelvalve2>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@10 { -+ fragment@6 { - target = <&hvs>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@11 { -+ fragment@7 { - target = <&hdmi>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@12 { -+ fragment@8 { - target = <&v3d>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@13 { -+ fragment@9 { - target = <&vc4>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@14 { -+ fragment@10 { - target = <&clocks>; - __overlay__ { - claim-clocks = < -@@ -120,21 +87,21 @@ - }; - }; - -- fragment@15 { -+ fragment@11 { - target = <&vec>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@16 { -+ fragment@12 { - target = <&txp>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@17 { -+ fragment@13 { - target = <&hdmi>; - __dormant__ { - dmas; -@@ -142,11 +109,6 @@ - }; - - __overrides__ { -- cma-256 = <0>,"+0-1-2-3-4"; -- cma-192 = <0>,"-0+1-2-3-4"; -- cma-128 = <0>,"-0-1+2-3-4"; -- cma-96 = <0>,"-0-1-2+3-4"; -- cma-64 = <0>,"-0-1-2-3+4"; - audio = <0>,"!17"; - }; - }; ---- a/arch/arm/boot/dts/overlays/vc4-kms-v3d-pi4-overlay.dts -+++ b/arch/arm/boot/dts/overlays/vc4-kms-v3d-pi4-overlay.dts -@@ -7,164 +7,131 @@ - - #include <dt-bindings/clock/bcm2835.h> - -+#include "cma-overlay.dts" -+ - / { - compatible = "brcm,bcm2835"; - -- fragment@0 { -- target-path = "/chosen"; -- __overlay__ { -- bootargs = "cma=256M"; -- }; -- }; -- - fragment@1 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=192M"; -- }; -- }; -- -- fragment@2 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=128M"; -- }; -- }; -- -- fragment@3 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=96M"; -- }; -- }; -- -- fragment@4 { -- target-path = "/chosen"; -- __dormant__ { -- bootargs = "cma=64M"; -- }; -- }; -- -- fragment@5 { - target = <&ddc0>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@6 { -+ fragment@2 { - target = <&ddc1>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@7 { -+ fragment@3 { - target = <&hdmi0>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@8 { -+ fragment@4 { - target = <&hdmi1>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@9 { -+ fragment@5 { - target = <&hvs>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@10 { -+ fragment@6 { - target = <&pixelvalve0>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@11 { -+ fragment@7 { - target = <&pixelvalve1>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@12 { -+ fragment@8 { - target = <&pixelvalve2>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@13 { -+ fragment@9 { - target = <&pixelvalve3>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@14 { -+ fragment@10 { - target = <&pixelvalve4>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@15 { -+ fragment@11 { - target = <&v3d>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@16 { -+ fragment@12 { - target = <&vc4>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@17 { -+ fragment@13 { - target = <&txp>; - __overlay__ { - status = "okay"; - }; - }; - -- fragment@18 { -+ fragment@14 { - target = <&fb>; - __overlay__ { - status = "disabled"; - }; - }; - -- fragment@19 { -+ fragment@15 { - target = <&firmwarekms>; - __overlay__ { - status = "disabled"; - }; - }; - -- fragment@20 { -+ fragment@16 { - target = <&vec>; - __overlay__ { - status = "disabled"; - }; - }; - -- fragment@21 { -+ fragment@17 { - target = <&hdmi0>; - __dormant__ { - dmas; - }; - }; - -- fragment@22 { -+ fragment@18 { - target = <&hdmi1>; - __dormant__ { - dmas; -@@ -172,12 +139,7 @@ - }; - - __overrides__ { -- cma-256 = <0>,"+0-1-2-3-4"; -- cma-192 = <0>,"-0+1-2-3-4"; -- cma-128 = <0>,"-0-1+2-3-4"; -- cma-96 = <0>,"-0-1-2+3-4"; -- cma-64 = <0>,"-0-1-2-3+4"; -- audio = <0>,"!21"; -- audio1 = <0>,"!22"; -+ audio = <0>,"!17"; -+ audio1 = <0>,"!18"; - }; - }; |