summaryrefslogtreecommitdiff
path: root/target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch
diff options
context:
space:
mode:
authorÁlvaro Fernández Rojas <noltari@gmail.com>2016-04-07 21:25:10 +0200
committerÁlvaro Fernández Rojas <noltari@gmail.com>2016-04-07 21:25:10 +0200
commita8d4d71c41ff0158c2026cac5981e39702167da9 (patch)
tree0c54ec3eb59f5bab6aa7318d14c92ff875412202 /target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch
parent59e0e88c22007fd77ee9c6c8e02a689889a5f597 (diff)
downloadmtk-20170518-a8d4d71c41ff0158c2026cac5981e39702167da9.zip
mtk-20170518-a8d4d71c41ff0158c2026cac5981e39702167da9.tar.gz
mtk-20170518-a8d4d71c41ff0158c2026cac5981e39702167da9.tar.bz2
brcm2708: update to latest version
As usual these patches were extracted from the raspberry pi repo: https://github.com/raspberrypi/linux/commits/rpi-4.4.y Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
Diffstat (limited to 'target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch')
-rw-r--r--target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch74
1 files changed, 74 insertions, 0 deletions
diff --git a/target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch b/target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch
new file mode 100644
index 0000000..91893c5
--- /dev/null
+++ b/target/linux/brcm2708/patches-4.4/0123-BCM270X_DT-Add-the-sdtweak-overlay-for-tuning-sdhost.patch
@@ -0,0 +1,74 @@
+From 5d03b10c60e70fb5d316706a3777e46dc9dd748e Mon Sep 17 00:00:00 2001
+From: Phil Elwell <phil@raspberrypi.org>
+Date: Mon, 4 Jan 2016 14:42:17 +0000
+Subject: [PATCH 123/232] BCM270X_DT: Add the sdtweak overlay, for tuning
+ sdhost
+
+The sdhost overlay declares the sdhost interface and allows parameters
+to be set. This is overkill for situations where the user just wants to
+tweak the parameters of a pre-declared sdhost interface, so create an
+sdtweak overlay that does just that.
+---
+ arch/arm/boot/dts/overlays/Makefile | 1 +
+ arch/arm/boot/dts/overlays/README | 14 ++++++++++++++
+ arch/arm/boot/dts/overlays/sdtweak-overlay.dts | 21 +++++++++++++++++++++
+ 3 files changed, 36 insertions(+)
+ create mode 100644 arch/arm/boot/dts/overlays/sdtweak-overlay.dts
+
+--- a/arch/arm/boot/dts/overlays/Makefile
++++ b/arch/arm/boot/dts/overlays/Makefile
+@@ -53,6 +53,7 @@ dtb-$(RPI_DT_OVERLAYS) += rpi-proto-over
+ dtb-$(RPI_DT_OVERLAYS) += rpi-sense-overlay.dtb
+ dtb-$(RPI_DT_OVERLAYS) += sdhost-overlay.dtb
+ dtb-$(RPI_DT_OVERLAYS) += sdio-overlay.dtb
++dtb-$(RPI_DT_OVERLAYS) += sdtweak-overlay.dtb
+ dtb-$(RPI_DT_OVERLAYS) += smi-dev-overlay.dtb
+ dtb-$(RPI_DT_OVERLAYS) += smi-nand-overlay.dtb
+ dtb-$(RPI_DT_OVERLAYS) += smi-overlay.dtb
+--- a/arch/arm/boot/dts/overlays/README
++++ b/arch/arm/boot/dts/overlays/README
+@@ -635,6 +635,20 @@ Params: overclock_50 Clock (
+ (default on: polling once at boot-time)
+
+
++Name: sdtweak
++Info: Tunes the bcm2835-sdhost SD/MMC driver
++Load: dtoverlay=sdtweak,<param>=<val>
++Params: overclock_50 Clock (in MHz) to use when the MMC framework
++ requests 50MHz
++
++ force_pio Disable DMA support (default off)
++
++ pio_limit Number of blocks above which to use DMA
++ (default 1)
++
++ debug Enable debug output (default off)
++
++
+ Name: smi
+ Info: Enables the Secondary Memory Interface peripheral. Uses GPIOs 2-25!
+ Load: dtoverlay=smi
+--- /dev/null
++++ b/arch/arm/boot/dts/overlays/sdtweak-overlay.dts
+@@ -0,0 +1,21 @@
++/dts-v1/;
++/plugin/;
++
++/{
++ compatible = "brcm,bcm2708";
++
++ fragment@0 {
++ target = <&sdhost>;
++ frag1: __overlay__ {
++ brcm,overclock-50 = <0>;
++ brcm,pio-limit = <1>;
++ };
++ };
++
++ __overrides__ {
++ overclock_50 = <&frag1>,"brcm,overclock-50:0";
++ force_pio = <&frag1>,"brcm,force-pio?";
++ pio_limit = <&frag1>,"brcm,pio-limit:0";
++ debug = <&frag1>,"brcm,debug?";
++ };
++};