bcm27xx: add kernel 5.10 support
[openwrt/openwrt.git] / target / linux / bcm27xx / patches-5.10 / 950-0375-overlays-Deprecate-and-delete-the-sdtweak-overlay.patch
1 From 068c8b508a0501de9bda9d6d9a8c4ddc06cf7ff8 Mon Sep 17 00:00:00 2001
2 From: Phil Elwell <phil@raspberrypi.com>
3 Date: Wed, 4 Nov 2020 11:25:02 +0000
4 Subject: [PATCH] overlays: Deprecate and delete the sdtweak overlay
5
6 The sdtweak overlay has been superseded by the board-specific
7 sd_* parameters such as sd_poll_once, sd_overclock etc.
8
9 For example, replace:
10
11 dtoverlay=sdtweak,poll_once
12
13 with:
14
15 dtparam=sd_poll_once
16
17 Signed-off-by: Phil Elwell <phil@raspberrypi.com>
18 ---
19 arch/arm/boot/dts/overlays/Makefile | 1 -
20 arch/arm/boot/dts/overlays/README | 27 +++----------------
21 arch/arm/boot/dts/overlays/overlay_map.dts | 4 +++
22 .../arm/boot/dts/overlays/sdtweak-overlay.dts | 25 -----------------
23 4 files changed, 8 insertions(+), 49 deletions(-)
24 delete mode 100644 arch/arm/boot/dts/overlays/sdtweak-overlay.dts
25
26 --- a/arch/arm/boot/dts/overlays/Makefile
27 +++ b/arch/arm/boot/dts/overlays/Makefile
28 @@ -158,7 +158,6 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
29 sc16is752-spi1.dtbo \
30 sdhost.dtbo \
31 sdio.dtbo \
32 - sdtweak.dtbo \
33 sh1106-spi.dtbo \
34 smi.dtbo \
35 smi-dev.dtbo \
36 --- a/arch/arm/boot/dts/overlays/README
37 +++ b/arch/arm/boot/dts/overlays/README
38 @@ -2409,29 +2409,10 @@ Load: <Deprecated>
39
40
41 Name: sdtweak
42 -Info: Tunes the bcm2835-sdhost SD/MMC driver
43 - N.B. This functionality is now available via the sd_* dtparams in the
44 - base DTB.
45 -Load: dtoverlay=sdtweak,<param>=<val>
46 -Params: overclock_50 Clock (in MHz) to use when the MMC framework
47 - requests 50MHz
48 -
49 - force_pio Disable DMA support (default off)
50 -
51 - pio_limit Number of blocks above which to use DMA
52 - (default 1)
53 -
54 - debug Enable debug output (default off)
55 -
56 - poll_once Looks for a card once after booting. Useful
57 - for network booting scenarios to avoid the
58 - overhead of continuous polling. N.B. Using
59 - this option restricts the system to using a
60 - single card per boot (or none at all).
61 - (default off)
62 -
63 - enable Set to off to completely disable the interface
64 - (default on)
65 +Info: This overlay is now deprecated. Use the sd_* dtparams in the
66 + base DTB, e.g. "dtoverlay=sdtweak,poll_once" becomes
67 + "dtparam=sd_poll_once".
68 +Load: <Deprecated>
69
70
71 Name: sh1106-spi
72 --- a/arch/arm/boot/dts/overlays/overlay_map.dts
73 +++ b/arch/arm/boot/dts/overlays/overlay_map.dts
74 @@ -61,6 +61,10 @@
75 deprecated = "use sdio,bus_width=1,gpios_22_25";
76 };
77
78 + sdtweak {
79 + deprecated = "use 'dtparam=sd_poll_once' etc.";
80 + };
81 +
82 spi0-cs {
83 renamed = "spi0-2cs";
84 };
85 --- a/arch/arm/boot/dts/overlays/sdtweak-overlay.dts
86 +++ /dev/null
87 @@ -1,25 +0,0 @@
88 -/dts-v1/;
89 -/plugin/;
90 -
91 -/* Provide backwards compatible aliases for the old sdhost dtparams. */
92 -
93 -/{
94 - compatible = "brcm,bcm2835";
95 -
96 - fragment@0 {
97 - target = <&sdhost>;
98 - frag0: __overlay__ {
99 - brcm,overclock-50 = <0>;
100 - brcm,pio-limit = <1>;
101 - };
102 - };
103 -
104 - __overrides__ {
105 - overclock_50 = <&frag0>,"brcm,overclock-50:0";
106 - force_pio = <&frag0>,"brcm,force-pio?";
107 - pio_limit = <&frag0>,"brcm,pio-limit:0";
108 - debug = <&frag0>,"brcm,debug?";
109 - enable = <&frag0>,"status";
110 - poll_once = <&frag0>,"non-removable?";
111 - };
112 -};