1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/input/input.h>
10 bootargs = "console=ttyS0,115200n8";
14 compatible = "gpio-keys";
18 gpios = <&gpio 18 GPIO_ACTIVE_LOW>;
19 linux,code = <KEY_RESTART>;
28 compatible = "fixed-partitions";
40 reg = <0x80000 0x40000>;
45 reg = <0xc0000 0x40000>;
49 factory: partition@100000 {
51 reg = <0x100000 0x40000>;
55 compatible = "fixed-layout";
59 macaddr_factory_e000: macaddr@e000 {
63 macaddr_factory_e006: macaddr@e006 {
71 reg = <0x140000 0x40000>;
75 label = "crash_syslog";
76 reg = <0x180000 0x40000>;
81 reg = <0x1c0000 0x40000>;
85 /* uboot expects to find kernels at 0x200000 & 0x600000
86 * referred to as system 1 & system 2 respectively.
87 * a kernel is considered suitable for handing control over
88 * if its linux magic number exists & uImage CRC are correct.
89 * If either of those conditions fail, a matching sys'n'_fail flag
90 * is set in uboot env & a restart performed in the hope that the
91 * alternate kernel is okay.
92 * if neither kernel checksums ok and both are marked failed, system 2
95 * Note uboot's tftp flash install writes the transferred
96 * image to both kernel partitions.
99 /* We keep stock xiaomi firmware (kernel0) here */
101 label = "kernel_stock";
102 reg = <0x200000 0x400000>;
107 reg = <0x600000 0x400000>;
110 /* ubi partition is the result of squashing
111 * next consecutive stock partitions:
112 * - rootfs0 (rootfs partition for stock kernel0),
113 * - rootfs1 (rootfs partition for stock failsafe kernel1),
114 * - overlay (used as ubi overlay in stock fw)
115 * resulting 117,5MiB space for packages.
120 reg = <0xa00000 0x7580000>;