aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch
diff options
context:
space:
mode:
authorÁlvaro Fernández Rojas <noltari@gmail.com>2021-08-21 10:54:34 +0200
committerÁlvaro Fernández Rojas <noltari@gmail.com>2021-08-21 19:07:07 +0200
commit8299d1f057439f94c6a4412e2e5c5082b82a30c9 (patch)
tree1bf678d61f11f7394493be464c7876e496f7faed /target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch
parent33b6885975ce376ff075362b7f0890326043111b (diff)
downloadupstream-8299d1f057439f94c6a4412e2e5c5082b82a30c9.tar.gz
upstream-8299d1f057439f94c6a4412e2e5c5082b82a30c9.tar.bz2
upstream-8299d1f057439f94c6a4412e2e5c5082b82a30c9.zip
bcm27xx: add kernel 5.10 support
Rebased RPi foundation patches on linux 5.10.59, removed applied and reverted patches, wireless patches and defconfig patches. bcm2708: boot tested on RPi B+ v1.2 bcm2709: boot tested on RPi 4B v1.1 4G bcm2711: boot tested on RPi 4B v1.1 4G Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch')
-rw-r--r--target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch234
1 files changed, 234 insertions, 0 deletions
diff --git a/target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch b/target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch
new file mode 100644
index 0000000000..addbb1a2ed
--- /dev/null
+++ b/target/linux/bcm27xx/patches-5.10/950-0732-overlays-Add-midi-uart-2345-overlay.dts.patch
@@ -0,0 +1,234 @@
+From 37f172b47784a4debc62cb71974eac303031e69c Mon Sep 17 00:00:00 2001
+From: pjx3 <pjx3@users.noreply.github.com>
+Date: Sun, 8 Aug 2021 20:09:46 +0100
+Subject: [PATCH] overlays: Add midi-uart{2345}-overlay.dts
+
+Added overlays for enabling MIDI baudrates on additional UARTs
+
+Signed-off-by: Pete Marshall <petemarshall303@gmail.com>
+---
+ arch/arm/boot/dts/overlays/Makefile | 4 ++
+ arch/arm/boot/dts/overlays/README | 28 ++++++++++++++
+ .../boot/dts/overlays/midi-uart2-overlay.dts | 37 ++++++++++++++++++
+ .../boot/dts/overlays/midi-uart3-overlay.dts | 38 +++++++++++++++++++
+ .../boot/dts/overlays/midi-uart4-overlay.dts | 38 +++++++++++++++++++
+ .../boot/dts/overlays/midi-uart5-overlay.dts | 38 +++++++++++++++++++
+ 6 files changed, 183 insertions(+)
+ create mode 100644 arch/arm/boot/dts/overlays/midi-uart2-overlay.dts
+ create mode 100644 arch/arm/boot/dts/overlays/midi-uart3-overlay.dts
+ create mode 100644 arch/arm/boot/dts/overlays/midi-uart4-overlay.dts
+ create mode 100644 arch/arm/boot/dts/overlays/midi-uart5-overlay.dts
+
+--- a/arch/arm/boot/dts/overlays/Makefile
++++ b/arch/arm/boot/dts/overlays/Makefile
+@@ -123,6 +123,10 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
+ merus-amp.dtbo \
+ midi-uart0.dtbo \
+ midi-uart1.dtbo \
++ midi-uart2.dtbo \
++ midi-uart3.dtbo \
++ midi-uart4.dtbo \
++ midi-uart5.dtbo \
+ minipitft13.dtbo \
+ miniuart-bt.dtbo \
+ mmc.dtbo \
+--- a/arch/arm/boot/dts/overlays/README
++++ b/arch/arm/boot/dts/overlays/README
+@@ -2088,6 +2088,34 @@ Load: dtoverlay=midi-uart1
+ Params: <None>
+
+
++Name: midi-uart2
++Info: Configures UART2 (ttyAMA1) so that a requested 38.4kbaud actually gets
++ 31.25kbaud, the frequency required for MIDI
++Load: dtoverlay=midi-uart2
++Params: <None>
++
++
++Name: midi-uart3
++Info: Configures UART3 (ttyAMA2) so that a requested 38.4kbaud actually gets
++ 31.25kbaud, the frequency required for MIDI
++Load: dtoverlay=midi-uart3
++Params: <None>
++
++
++Name: midi-uart4
++Info: Configures UART4 (ttyAMA3) so that a requested 38.4kbaud actually gets
++ 31.25kbaud, the frequency required for MIDI
++Load: dtoverlay=midi-uart4
++Params: <None>
++
++
++Name: midi-uart5
++Info: Configures UART5 (ttyAMA4) so that a requested 38.4kbaud actually gets
++ 31.25kbaud, the frequency required for MIDI
++Load: dtoverlay=midi-uart5
++Params: <None>
++
++
+ Name: minipitft13
+ Info: Overlay for AdaFruit Mini Pi 1.3" TFT via SPI using fbtft driver.
+ Load: dtoverlay=minipitft13,<param>=<val>
+--- /dev/null
++++ b/arch/arm/boot/dts/overlays/midi-uart2-overlay.dts
+@@ -0,0 +1,37 @@
++/dts-v1/;
++/plugin/;
++
++#include <dt-bindings/clock/bcm2835.h>
++
++/*
++ * Fake a higher clock rate to get a larger divisor, and thereby a lower
++ * baudrate. The real clock is 48MHz, which we scale so that requesting
++ * 38.4kHz results in an actual 31.25kHz.
++ *
++ * 48000000*38400/31250 = 58982400
++ */
++
++/{
++ compatible = "brcm,bcm2835";
++
++ fragment@0 {
++ target-path = "/";
++ __overlay__ {
++ midi_clk: midi_clk2 {
++ compatible = "fixed-clock";
++ #clock-cells = <0>;
++ clock-output-names = "uart2_pclk";
++ clock-frequency = <58982400>;
++ };
++ };
++ };
++
++ fragment@1 {
++ target = <&uart2>;
++ __overlay__ {
++ clocks = <&midi_clk>,
++ <&clocks BCM2835_CLOCK_VPU>;
++ };
++ };
++};
++
+--- /dev/null
++++ b/arch/arm/boot/dts/overlays/midi-uart3-overlay.dts
+@@ -0,0 +1,38 @@
++/dts-v1/;
++/plugin/;
++
++#include <dt-bindings/clock/bcm2835.h>
++
++/*
++ * Fake a higher clock rate to get a larger divisor, and thereby a lower
++ * baudrate. The real clock is 48MHz, which we scale so that requesting
++ * 38.4kHz results in an actual 31.25kHz.
++ *
++ * 48000000*38400/31250 = 58982400
++ */
++
++/{
++ compatible = "brcm,bcm2835";
++
++ fragment@0 {
++ target-path = "/";
++ __overlay__ {
++ midi_clk: midi_clk3 {
++ compatible = "fixed-clock";
++ #clock-cells = <0>;
++ clock-output-names = "uart3_pclk";
++ clock-frequency = <58982400>;
++ };
++ };
++ };
++
++ fragment@1 {
++ target = <&uart3>;
++ __overlay__ {
++ clocks = <&midi_clk>,
++ <&clocks BCM2835_CLOCK_VPU>;
++ };
++ };
++};
++
++
+--- /dev/null
++++ b/arch/arm/boot/dts/overlays/midi-uart4-overlay.dts
+@@ -0,0 +1,38 @@
++/dts-v1/;
++/plugin/;
++
++#include <dt-bindings/clock/bcm2835.h>
++
++/*
++ * Fake a higher clock rate to get a larger divisor, and thereby a lower
++ * baudrate. The real clock is 48MHz, which we scale so that requesting
++ * 38.4kHz results in an actual 31.25kHz.
++ *
++ * 48000000*38400/31250 = 58982400
++ */
++
++/{
++ compatible = "brcm,bcm2835";
++
++ fragment@0 {
++ target-path = "/";
++ __overlay__ {
++ midi_clk: midi_clk4 {
++ compatible = "fixed-clock";
++ #clock-cells = <0>;
++ clock-output-names = "uart4_pclk";
++ clock-frequency = <58982400>;
++ };
++ };
++ };
++
++ fragment@1 {
++ target = <&uart4>;
++ __overlay__ {
++ clocks = <&midi_clk>,
++ <&clocks BCM2835_CLOCK_VPU>;
++ };
++ };
++};
++
++
+--- /dev/null
++++ b/arch/arm/boot/dts/overlays/midi-uart5-overlay.dts
+@@ -0,0 +1,38 @@
++/dts-v1/;
++/plugin/;
++
++#include <dt-bindings/clock/bcm2835.h>
++
++/*
++ * Fake a higher clock rate to get a larger divisor, and thereby a lower
++ * baudrate. The real clock is 48MHz, which we scale so that requesting
++ * 38.4kHz results in an actual 31.25kHz.
++ *
++ * 48000000*38400/31250 = 58982400
++ */
++
++/{
++ compatible = "brcm,bcm2835";
++
++ fragment@0 {
++ target-path = "/";
++ __overlay__ {
++ midi_clk: midi_clk5 {
++ compatible = "fixed-clock";
++ #clock-cells = <0>;
++ clock-output-names = "uart5_pclk";
++ clock-frequency = <58982400>;
++ };
++ };
++ };
++
++ fragment@1 {
++ target = <&uart5>;
++ __overlay__ {
++ clocks = <&midi_clk>,
++ <&clocks BCM2835_CLOCK_VPU>;
++ };
++ };
++};
++
++