mirror of
https://github.com/Fishwaldo/build.git
synced 2025-03-26 00:31:47 +00:00
[ nanopi boards ] adjust default settings like they are in stock FA kernel
This commit is contained in:
parent
43e1f75ea3
commit
390a5a2e90
4 changed files with 194 additions and 24 deletions
|
@ -1,12 +0,0 @@
|
|||
diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
index c6decee..642a43b 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
@@ -51,6 +51,7 @@
|
||||
/ {
|
||||
aliases {
|
||||
serial0 = &uart0;
|
||||
+ ethernet0 = &emac;
|
||||
};
|
||||
|
||||
chosen {
|
97
patch/kernel/sunxi-dev/board-nanopi-adjust-defaults.patch
Normal file
97
patch/kernel/sunxi-dev/board-nanopi-adjust-defaults.patch
Normal file
|
@ -0,0 +1,97 @@
|
|||
diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
index f110ee382..c25c08bae 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
@@ -51,6 +51,10 @@
|
||||
/ {
|
||||
aliases {
|
||||
serial0 = &uart0;
|
||||
+ serial1 = &uart1;
|
||||
+ serial2 = &uart2;
|
||||
+ serial3 = &uart3;
|
||||
+ ethernet0 = &emac;
|
||||
};
|
||||
|
||||
chosen {
|
||||
@@ -89,10 +93,38 @@
|
||||
};
|
||||
};
|
||||
|
||||
+&ehci0 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci0 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ehci1 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci1 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ehci2 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci2 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
&ehci3 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
+&ohci3 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
&mmc0 {
|
||||
bus-width = <4>;
|
||||
cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>;
|
||||
@@ -100,10 +132,6 @@
|
||||
vmmc-supply = <®_vcc3v3>;
|
||||
};
|
||||
|
||||
-&ohci3 {
|
||||
- status = "okay";
|
||||
-};
|
||||
-
|
||||
&pio {
|
||||
leds_npi: led_pins {
|
||||
pins = "PA10";
|
||||
@@ -129,6 +157,31 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
+&uart3 {
|
||||
+ pinctrl-names = "default";
|
||||
+ pinctrl-0 = <&uart3_pins>, <&uart3_rts_cts_pins>;
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&i2c0 {
|
||||
+ status = "okay";
|
||||
+ rtc@68 {
|
||||
+ compatible = "dallas,ds1307";
|
||||
+ reg = <0x68>;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&usb_otg {
|
||||
+ // OTG is not stable.
|
||||
+ // most nanopi-h3's MicroUSB support OTG, except:
|
||||
+ // 1. nanopi-neo-V1.4 support OTG, nanopi-neo-V1.3/1.2... support USB device.
|
||||
+ // 2. nanopi-k1 only use as power.
|
||||
+ dr_mode = "otg";
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
&usbphy {
|
||||
+ usb0_id_det-gpios = <&pio 6 12 GPIO_ACTIVE_HIGH>; /* PG12 */
|
||||
+ usb0_vbus-supply = <®_usb0_vbus>;
|
||||
status = "okay";
|
||||
};
|
|
@ -1,12 +0,0 @@
|
|||
diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
index c6decee..642a43b 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
@@ -51,6 +51,7 @@
|
||||
/ {
|
||||
aliases {
|
||||
serial0 = &uart0;
|
||||
+ ethernet0 = &emac;
|
||||
};
|
||||
|
||||
chosen {
|
97
patch/kernel/sunxi-next/board-nanopi-adjust-defaults.patch
Normal file
97
patch/kernel/sunxi-next/board-nanopi-adjust-defaults.patch
Normal file
|
@ -0,0 +1,97 @@
|
|||
diff --git a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
index f110ee382..c25c08bae 100644
|
||||
--- a/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
+++ b/arch/arm/boot/dts/sun8i-h3-nanopi.dtsi
|
||||
@@ -51,6 +51,10 @@
|
||||
/ {
|
||||
aliases {
|
||||
serial0 = &uart0;
|
||||
+ serial1 = &uart1;
|
||||
+ serial2 = &uart2;
|
||||
+ serial3 = &uart3;
|
||||
+ ethernet0 = &emac;
|
||||
};
|
||||
|
||||
chosen {
|
||||
@@ -89,10 +93,38 @@
|
||||
};
|
||||
};
|
||||
|
||||
+&ehci0 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci0 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ehci1 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci1 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ehci2 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&ohci2 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
&ehci3 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
+&ohci3 {
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
&mmc0 {
|
||||
bus-width = <4>;
|
||||
cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>;
|
||||
@@ -100,10 +132,6 @@
|
||||
vmmc-supply = <®_vcc3v3>;
|
||||
};
|
||||
|
||||
-&ohci3 {
|
||||
- status = "okay";
|
||||
-};
|
||||
-
|
||||
&pio {
|
||||
leds_npi: led_pins {
|
||||
pins = "PA10";
|
||||
@@ -129,6 +157,31 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
+&uart3 {
|
||||
+ pinctrl-names = "default";
|
||||
+ pinctrl-0 = <&uart3_pins>, <&uart3_rts_cts_pins>;
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
+&i2c0 {
|
||||
+ status = "okay";
|
||||
+ rtc@68 {
|
||||
+ compatible = "dallas,ds1307";
|
||||
+ reg = <0x68>;
|
||||
+ };
|
||||
+};
|
||||
+
|
||||
+&usb_otg {
|
||||
+ // OTG is not stable.
|
||||
+ // most nanopi-h3's MicroUSB support OTG, except:
|
||||
+ // 1. nanopi-neo-V1.4 support OTG, nanopi-neo-V1.3/1.2... support USB device.
|
||||
+ // 2. nanopi-k1 only use as power.
|
||||
+ dr_mode = "otg";
|
||||
+ status = "okay";
|
||||
+};
|
||||
+
|
||||
&usbphy {
|
||||
+ usb0_id_det-gpios = <&pio 6 12 GPIO_ACTIVE_HIGH>; /* PG12 */
|
||||
+ usb0_vbus-supply = <®_usb0_vbus>;
|
||||
status = "okay";
|
||||
};
|
Loading…
Add table
Reference in a new issue