Merge branch 'openwrt:master' into master
This commit is contained in:
commit
681d9f8331
15 changed files with 116 additions and 23 deletions
|
@ -17,7 +17,7 @@
|
|||
|
||||
#include <mtd.h>
|
||||
#include <linux/mtd/mtd.h>
|
||||
@@ -25,7 +32,19 @@ int board_init(void)
|
||||
@@ -25,7 +32,22 @@ int board_init(void)
|
||||
|
||||
int board_late_init(void)
|
||||
{
|
||||
|
@ -27,7 +27,10 @@
|
|||
+ if (!button_get_by_label(CONFIG_RESET_BUTTON_LABEL, &dev)) {
|
||||
+ puts("reset button found\n");
|
||||
+#ifdef CONFIG_RESET_BUTTON_SETTLE_DELAY
|
||||
+ if (CONFIG_RESET_BUTTON_SETTLE_DELAY > 0) {
|
||||
+ button_get_state(dev);
|
||||
+ mdelay(CONFIG_RESET_BUTTON_SETTLE_DELAY);
|
||||
+ }
|
||||
+#endif
|
||||
+ if (button_get_state(dev) == BUTTON_ON) {
|
||||
+ puts("button pushed, resetting environment\n");
|
||||
|
@ -40,7 +43,7 @@
|
|||
}
|
||||
--- a/arch/arm/mach-mediatek/Kconfig
|
||||
+++ b/arch/arm/mach-mediatek/Kconfig
|
||||
@@ -140,4 +140,8 @@ config MTK_BROM_HEADER_INFO
|
||||
@@ -140,4 +140,11 @@ config MTK_BROM_HEADER_INFO
|
||||
|
||||
source "board/mediatek/mt7629/Kconfig"
|
||||
|
||||
|
@ -48,4 +51,7 @@
|
|||
+ string "Button to trigger factory reset"
|
||||
+ default "reset"
|
||||
+
|
||||
+config RESET_BUTTON_SETTLE_DELAY
|
||||
+ int "Delay to wait for button to settle"
|
||||
+ default 0
|
||||
endif
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
@@ -41,3 +50,22 @@ int mmc_get_env_dev(void)
|
||||
@@ -41,3 +50,25 @@ int mmc_get_env_dev(void)
|
||||
return mmc_get_boot_dev();
|
||||
}
|
||||
#endif
|
||||
|
@ -30,7 +30,10 @@
|
|||
+ if (!button_get_by_label(CONFIG_RESET_BUTTON_LABEL, &dev)) {
|
||||
+ puts("reset button found\n");
|
||||
+#ifdef CONFIG_RESET_BUTTON_SETTLE_DELAY
|
||||
+ if (CONFIG_RESET_BUTTON_SETTLE_DELAY > 0) {
|
||||
+ button_get_state(dev);
|
||||
+ mdelay(CONFIG_RESET_BUTTON_SETTLE_DELAY);
|
||||
+ }
|
||||
+#endif
|
||||
+ if (button_get_state(dev) == BUTTON_ON) {
|
||||
+ puts("button pushed, resetting environment\n");
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
|
||||
#include <mtd.h>
|
||||
#include <linux/mtd/mtd.h>
|
||||
@@ -24,7 +31,19 @@ int board_init(void)
|
||||
@@ -24,7 +31,22 @@ int board_init(void)
|
||||
|
||||
int board_late_init(void)
|
||||
{
|
||||
|
@ -28,7 +28,10 @@
|
|||
+ if (!button_get_by_label(CONFIG_RESET_BUTTON_LABEL, &dev)) {
|
||||
+ puts("reset button found\n");
|
||||
+#ifdef CONFIG_RESET_BUTTON_SETTLE_DELAY
|
||||
+ if (CONFIG_RESET_BUTTON_SETTLE_DELAY > 0) {
|
||||
+ button_get_state(dev);
|
||||
+ mdelay(CONFIG_RESET_BUTTON_SETTLE_DELAY);
|
||||
+ }
|
||||
+#endif
|
||||
+ if (button_get_state(dev) == BUTTON_ON) {
|
||||
+ puts("button pushed, resetting environment\n");
|
||||
|
|
|
@ -213,7 +213,15 @@
|
|||
+_set_bmf=setenv _set_bmf ; setenv bootmenu_${_menu_next} "Reset all settings to factory defaults.=run reset_factory ; reset" ; setenv _menu_next
|
||||
--- a/arch/arm/dts/mt7623n-bananapi-bpi-r2.dts
|
||||
+++ b/arch/arm/dts/mt7623n-bananapi-bpi-r2.dts
|
||||
@@ -66,6 +66,15 @@
|
||||
@@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
#include "mt7623.dtsi"
|
||||
#include "mt7623-u-boot.dtsi"
|
||||
|
||||
@@ -66,6 +67,16 @@
|
||||
default-state = "off";
|
||||
};
|
||||
};
|
||||
|
@ -224,6 +232,7 @@
|
|||
+ factory {
|
||||
+ label = "factory";
|
||||
+ gpios = <&gpio 256 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+ };
|
||||
};
|
||||
|
|
|
@ -191,3 +191,52 @@
|
|||
+_update_bootdev=setenv _update_bootdev ; setenv bootargs "$console root=/dev/mmcblk0p65"
|
||||
+_switch_to_menu=setenv _switch_to_menu ; setenv bootdelay 3 ; setenv bootmenu_delay 3 ; setenv bootmenu_0 $bootmenu_0d ; setenv bootmenu_0d ; run _bootmenu_update_title
|
||||
+_bootmenu_update_title=setenv _bootmenu_update_title ; setenv bootmenu_title "$bootmenu_title [33m$ver[0m"
|
||||
--- a/arch/arm/dts/mt7623a-unielec-u7623-02-emmc.dts
|
||||
+++ b/arch/arm/dts/mt7623a-unielec-u7623-02-emmc.dts
|
||||
@@ -6,6 +6,7 @@
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
#include "mt7623.dtsi"
|
||||
#include "mt7623-u-boot.dtsi"
|
||||
|
||||
@@ -50,6 +51,18 @@
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
+ gpio-keys {
|
||||
+ compatible = "gpio-keys";
|
||||
+ pinctrl-names = "default";
|
||||
+ pinctrl-0 = <&key_pins_a>;
|
||||
+
|
||||
+ factory {
|
||||
+ label = "factory";
|
||||
+ gpios = <&gpio 256 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
leds {
|
||||
compatible = "gpio-leds";
|
||||
|
||||
@@ -109,6 +122,19 @@
|
||||
};
|
||||
};
|
||||
|
||||
+ key_pins_a: keys-alt {
|
||||
+ mux {
|
||||
+ function = "gpio";
|
||||
+ groups = "msdc3";
|
||||
+ };
|
||||
+
|
||||
+ conf {
|
||||
+ pins = "MSDC0E_DAT0", "MSDC0E_DAT1";
|
||||
+ input-enable;
|
||||
+ bias-pull-up;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
mmc0_pins_default: mmc0default {
|
||||
mux {
|
||||
function = "msdc";
|
||||
|
|
|
@ -1,6 +1,14 @@
|
|||
--- a/arch/arm/dts/mt7622-bananapi-bpi-r64.dts
|
||||
+++ b/arch/arm/dts/mt7622-bananapi-bpi-r64.dts
|
||||
@@ -20,6 +20,7 @@
|
||||
@@ -5,6 +5,7 @@
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
#include "mt7622.dtsi"
|
||||
#include "mt7622-u-boot.dtsi"
|
||||
|
||||
@@ -20,6 +21,7 @@
|
||||
|
||||
aliases {
|
||||
spi0 = &snfi;
|
||||
|
@ -8,7 +16,7 @@
|
|||
};
|
||||
|
||||
memory@40000000 {
|
||||
@@ -27,6 +28,42 @@
|
||||
@@ -27,6 +29,44 @@
|
||||
reg = <0x40000000 0x40000000>;
|
||||
};
|
||||
|
||||
|
@ -18,11 +26,13 @@
|
|||
+ reset {
|
||||
+ label = "reset";
|
||||
+ gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+
|
||||
+ wps {
|
||||
+ label = "wps";
|
||||
+ gpios = <&gpio 102 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_WPS_BUTTON>;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
|
@ -51,7 +61,7 @@
|
|||
reg_1p8v: regulator-1p8v {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "fixed-1.8V";
|
||||
@@ -182,6 +219,7 @@
|
||||
@@ -182,6 +222,7 @@
|
||||
};
|
||||
|
||||
&uart0 {
|
||||
|
@ -59,7 +69,7 @@
|
|||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -197,7 +235,7 @@
|
||||
@@ -197,7 +238,7 @@
|
||||
status = "okay";
|
||||
bus-width = <8>;
|
||||
max-frequency = <50000000>;
|
||||
|
@ -68,7 +78,7 @@
|
|||
vmmc-supply = <®_3p3v>;
|
||||
vqmmc-supply = <®_3p3v>;
|
||||
non-removable;
|
||||
@@ -208,7 +246,7 @@
|
||||
@@ -208,7 +249,7 @@
|
||||
pinctrl-0 = <&mmc1_pins_default>;
|
||||
status = "okay";
|
||||
bus-width = <4>;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- a/arch/arm/dts/mt7622-bananapi-bpi-r64.dts
|
||||
+++ b/arch/arm/dts/mt7622-bananapi-bpi-r64.dts
|
||||
@@ -19,7 +19,7 @@
|
||||
@@ -20,7 +20,7 @@
|
||||
};
|
||||
|
||||
aliases {
|
||||
|
@ -9,7 +9,7 @@
|
|||
ethernet0 = ð
|
||||
};
|
||||
|
||||
@@ -205,17 +205,11 @@
|
||||
@@ -208,17 +208,11 @@
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- a/arch/arm/dts/mt7623n-bananapi-bpi-r2.dts
|
||||
+++ b/arch/arm/dts/mt7623n-bananapi-bpi-r2.dts
|
||||
@@ -50,19 +50,19 @@
|
||||
@@ -51,19 +51,19 @@
|
||||
|
||||
blue {
|
||||
label = "bpi-r2:pio:blue";
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- a/arch/arm/dts/mt7623n-bananapi-bpi-r2.dts
|
||||
+++ b/arch/arm/dts/mt7623n-bananapi-bpi-r2.dts
|
||||
@@ -243,6 +243,7 @@
|
||||
@@ -245,6 +245,7 @@
|
||||
&uart0 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&uart0_pins_a>;
|
||||
|
|
|
@ -144,7 +144,7 @@
|
|||
+CONFIG_USB_STORAGE=y
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/dts/mt7622-linksys-e8450-ubi.dts
|
||||
@@ -0,0 +1,194 @@
|
||||
@@ -0,0 +1,197 @@
|
||||
+// SPDX-License-Identifier: GPL-2.0
|
||||
+/*
|
||||
+ * Copyright (c) 2019 MediaTek Inc.
|
||||
|
@ -152,6 +152,7 @@
|
|||
+ */
|
||||
+
|
||||
+/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
+#include "mt7622.dtsi"
|
||||
+#include "mt7622-u-boot.dtsi"
|
||||
+
|
||||
|
@ -175,11 +176,13 @@
|
|||
+ factory {
|
||||
+ label = "reset";
|
||||
+ gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+
|
||||
+ wps {
|
||||
+ label = "wps";
|
||||
+ gpios = <&gpio 102 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_WPS_BUTTON>;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
|
|
|
@ -158,6 +158,7 @@
|
|||
+ */
|
||||
+
|
||||
+/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
+#include "mt7622.dtsi"
|
||||
+#include "mt7622-u-boot.dtsi"
|
||||
+
|
||||
|
@ -178,12 +179,11 @@
|
|||
+
|
||||
+ gpio-keys {
|
||||
+ compatible = "gpio-keys";
|
||||
+ u-boot,dm-pre-reloc;
|
||||
+
|
||||
+ reset {
|
||||
+ label = "reset";
|
||||
+ gpios = <&gpio 62 GPIO_ACTIVE_LOW>;
|
||||
+ u-boot,dm-pre-reloc;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
|
|
|
@ -851,7 +851,7 @@
|
|||
+
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/dts/mt7986a-bpi-r3-sd.dts
|
||||
@@ -0,0 +1,270 @@
|
||||
@@ -0,0 +1,272 @@
|
||||
+// SPDX-License-Identifier: GPL-2.0
|
||||
+/*
|
||||
+ * Copyright (c) 2021 MediaTek Inc.
|
||||
|
@ -859,6 +859,7 @@
|
|||
+ */
|
||||
+
|
||||
+/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
+#include "mt7986.dtsi"
|
||||
+#include <dt-bindings/gpio/gpio.h>
|
||||
+
|
||||
|
@ -893,6 +894,7 @@
|
|||
+ wps {
|
||||
+ label = "reset";
|
||||
+ gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+ };
|
||||
+
|
||||
|
|
|
@ -183,7 +183,7 @@
|
|||
+CONFIG_SERVERIP="192.168.1.254"
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/dts/mt7986a-xiaomi_redmi-ax6000.dts
|
||||
@@ -0,0 +1,153 @@
|
||||
@@ -0,0 +1,156 @@
|
||||
+// SPDX-License-Identifier: GPL-2.0
|
||||
+/*
|
||||
+ * Copyright (c) 2021 MediaTek Inc.
|
||||
|
@ -191,6 +191,7 @@
|
|||
+ */
|
||||
+
|
||||
+/dts-v1/;
|
||||
+#include <dt-bindings/input/linux-event-codes.h>
|
||||
+#include "mt7986.dtsi"
|
||||
+#include <dt-bindings/gpio/gpio.h>
|
||||
+
|
||||
|
@ -210,10 +211,12 @@
|
|||
+ factory {
|
||||
+ label = "reset";
|
||||
+ gpios = <&gpio 9 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_RESTART>;
|
||||
+ };
|
||||
+ mesh {
|
||||
+ label = "mesh";
|
||||
+ gpios = <&gpio 10 GPIO_ACTIVE_LOW>;
|
||||
+ linux,code = <KEY_WPS_BUTTON>;
|
||||
+ };
|
||||
+ };
|
||||
+};
|
||||
|
|
|
@ -120,6 +120,7 @@
|
|||
mod-def0-gpios = <&pio 49 GPIO_ACTIVE_LOW>;
|
||||
tx-disable-gpios = <&pio 20 GPIO_ACTIVE_HIGH>;
|
||||
tx-fault-gpios = <&pio 7 GPIO_ACTIVE_HIGH>;
|
||||
maximum-power-milliwatt = <3000>;
|
||||
};
|
||||
|
||||
/* SFP2 cage (LAN) */
|
||||
|
@ -139,6 +140,7 @@
|
|||
mod-def0-gpios = <&pio 47 GPIO_ACTIVE_LOW>;
|
||||
tx-disable-gpios = <&pio 15 GPIO_ACTIVE_HIGH>;
|
||||
tx-fault-gpios = <&pio 48 GPIO_ACTIVE_HIGH>;
|
||||
maximum-power-milliwatt = <3000>;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -47,6 +47,7 @@ CONFIG_BLK_MQ_PCI=y
|
|||
CONFIG_BLK_PM=y
|
||||
CONFIG_BSD_PROCESS_ACCT=y
|
||||
CONFIG_BSD_PROCESS_ACCT_V3=y
|
||||
CONFIG_CC_HAVE_SHADOW_CALL_STACK=y
|
||||
CONFIG_CC_HAVE_STACKPROTECTOR_SYSREG=y
|
||||
CONFIG_CLKSRC_MMIO=y
|
||||
CONFIG_CLONE_BACKWARDS=y
|
||||
|
@ -177,6 +178,7 @@ CONFIG_HARDIRQS_SW_RESEND=y
|
|||
CONFIG_HAS_DMA=y
|
||||
CONFIG_HAS_IOMEM=y
|
||||
CONFIG_HAS_IOPORT_MAP=y
|
||||
CONFIG_HWMON=y
|
||||
CONFIG_HW_RANDOM=y
|
||||
CONFIG_HW_RANDOM_MTK=y
|
||||
CONFIG_I2C=y
|
||||
|
@ -296,6 +298,7 @@ CONFIG_PCI_DOMAINS=y
|
|||
CONFIG_PCI_DOMAINS_GENERIC=y
|
||||
CONFIG_PCI_MSI=y
|
||||
CONFIG_PCI_MSI_IRQ_DOMAIN=y
|
||||
CONFIG_PCS_MTK_LYNXI=y
|
||||
CONFIG_PERF_EVENTS=y
|
||||
CONFIG_PGTABLE_LEVELS=3
|
||||
CONFIG_PHYLIB=y
|
||||
|
@ -397,11 +400,11 @@ CONFIG_SYSCTL_EXCEPTION_TRACE=y
|
|||
CONFIG_THERMAL=y
|
||||
CONFIG_THERMAL_DEFAULT_GOV_STEP_WISE=y
|
||||
CONFIG_THERMAL_EMERGENCY_POWEROFF_DELAY_MS=0
|
||||
CONFIG_THERMAL_EMULATION=y
|
||||
CONFIG_THERMAL_GOV_BANG_BANG=y
|
||||
CONFIG_THERMAL_GOV_FAIR_SHARE=y
|
||||
CONFIG_THERMAL_GOV_STEP_WISE=y
|
||||
CONFIG_THERMAL_GOV_USER_SPACE=y
|
||||
CONFIG_THERMAL_HWMON=y
|
||||
CONFIG_THERMAL_OF=y
|
||||
CONFIG_THERMAL_WRITABLE_TRIPS=y
|
||||
CONFIG_THREAD_INFO_IN_TASK=y
|
||||
|
|
Loading…
Reference in a new issue