mpc85xx: add support for kernel 5.4
[openwrt/staging/luka.git] / target / linux / mpc85xx / patches-5.4 / 104-powerpc-mpc85xx-change-P2020RDB-dts-file-for-OpenWRT.patch
1 From 93514afd769c305182beeed1f9c4c46235879ef8 Mon Sep 17 00:00:00 2001
2 From: Pawel Dembicki <paweldembicki@gmail.com>
3 Date: Sun, 30 Dec 2018 23:24:41 +0100
4 Subject: [PATCH] powerpc: mpc85xx: change P2020RDB dts file for OpenWRT
5
6 This patch apply chages for OpenWRT in P2020RDB
7 dts file.
8
9 Signed-off-by: Pawel Dembicki <paweldembicki@gmail.com>
10 ---
11 arch/powerpc/boot/dts/fsl/p2020rdb.dts | 98 +++++++++++++++++---------
12 1 file changed, 63 insertions(+), 35 deletions(-)
13
14 --- a/arch/powerpc/boot/dts/fsl/p2020rdb.dts
15 +++ b/arch/powerpc/boot/dts/fsl/p2020rdb.dts
16 @@ -5,10 +5,15 @@
17 * Copyright 2009-2012 Freescale Semiconductor Inc.
18 */
19
20 +/dts-v1/;
21 +
22 /include/ "p2020si-pre.dtsi"
23
24 +#include <dt-bindings/gpio/gpio.h>
25 +#include <dt-bindings/input/input.h>
26 +
27 / {
28 - model = "fsl,P2020RDB";
29 + model = "Freescale P2020RDB";
30 compatible = "fsl,P2020RDB";
31
32 aliases {
33 @@ -34,48 +39,38 @@
34 0x2 0x0 0x0 0xffb00000 0x00020000>;
35
36 nor@0,0 {
37 - #address-cells = <1>;
38 - #size-cells = <1>;
39 compatible = "cfi-flash";
40 reg = <0x0 0x0 0x1000000>;
41 bank-width = <2>;
42 device-width = <1>;
43
44 - partition@0 {
45 - /* This location must not be altered */
46 - /* 256KB for Vitesse 7385 Switch firmware */
47 - reg = <0x0 0x00040000>;
48 - label = "NOR (RO) Vitesse-7385 Firmware";
49 - read-only;
50 - };
51 -
52 - partition@40000 {
53 - /* 256KB for DTB Image */
54 - reg = <0x00040000 0x00040000>;
55 - label = "NOR (RO) DTB Image";
56 - read-only;
57 - };
58 + partitions {
59 + compatible = "fixed-partitions";
60 + #address-cells = <1>;
61 + #size-cells = <1>;
62
63 - partition@80000 {
64 - /* 3.5 MB for Linux Kernel Image */
65 - reg = <0x00080000 0x00380000>;
66 - label = "NOR (RO) Linux Kernel Image";
67 - read-only;
68 - };
69 + partition@0 {
70 + /* This location must not be altered */
71 + /* 256KB for Vitesse 7385 Switch firmware */
72 + reg = <0x0 0x00040000>;
73 + label = "NOR (RO) Vitesse-7385 Firmware";
74 + read-only;
75 + };
76
77 - partition@400000 {
78 - /* 11MB for JFFS2 based Root file System */
79 - reg = <0x00400000 0x00b00000>;
80 - label = "NOR (RW) JFFS2 Root File System";
81 - };
82 + partition@40000 {
83 + compatible = "denx,fit";
84 + reg = <0x00040000 0x00ec0000>;
85 + label = "firmware";
86 + };
87
88 - partition@f00000 {
89 - /* This location must not be altered */
90 - /* 512KB for u-boot Bootloader Image */
91 - /* 512KB for u-boot Environment Variables */
92 - reg = <0x00f00000 0x00100000>;
93 - label = "NOR (RO) U-Boot Image";
94 - read-only;
95 + partition@f00000 {
96 + /* This location must not be altered */
97 + /* 512KB for u-boot Bootloader Image */
98 + /* 512KB for u-boot Environment Variables */
99 + reg = <0x00f00000 0x00100000>;
100 + label = "u-boot";
101 + read-only;
102 + };
103 };
104 };
105
106 @@ -140,13 +135,43 @@
107 soc: soc@ffe00000 {
108 ranges = <0x0 0x0 0xffe00000 0x100000>;
109
110 + gpio0: gpio-controller@fc00 {
111 + };
112 +
113 i2c@3000 {
114 + temperature-sensor@4c {
115 + compatible = "adi,adt7461";
116 + reg = <0x4c>;
117 + };
118 +
119 + eeprom@50 {
120 + compatible = "atmel,24c256";
121 + reg = <0x50>;
122 + };
123 +
124 rtc@68 {
125 compatible = "dallas,ds1339";
126 reg = <0x68>;
127 };
128 };
129
130 + i2c@3100 {
131 + pmic@11 {
132 + compatible = "zl2006";
133 + reg = <0x11>;
134 + };
135 +
136 + gpio@18 {
137 + compatible = "nxp,pca9557";
138 + reg = <0x18>;
139 + };
140 +
141 + eeprom@52 {
142 + compatible = "atmel,24c01";
143 + reg = <0x52>;
144 + };
145 + };
146 +
147 spi@7000 {
148 flash@0 {
149 #address-cells = <1>;
150 @@ -200,10 +225,12 @@
151 phy0: ethernet-phy@0 {
152 interrupts = <3 1 0 0>;
153 reg = <0x0>;
154 + reset-gpios = <&gpio0 14 GPIO_ACTIVE_LOW>;
155 };
156 phy1: ethernet-phy@1 {
157 interrupts = <3 1 0 0>;
158 reg = <0x1>;
159 + reset-gpios = <&gpio0 6 GPIO_ACTIVE_LOW>;
160 };
161 tbi-phy@2 {
162 device_type = "tbi-phy";