Fixed OrangePi 4 bluetooth and mic in current - based on https://github.com/armbian/build/pull/1888

This commit is contained in:
Piotr Szczepanik 2020-04-16 23:04:35 +02:00
parent 69327492c7
commit af2b7127b1
3 changed files with 43 additions and 12 deletions

View File

@ -1466,6 +1466,7 @@ CONFIG_BT_LEDS=y
# Bluetooth device drivers
#
CONFIG_BT_BCM=m
CONFIG_BT_QCA=m
# CONFIG_BT_HCIBTUSB is not set
# CONFIG_BT_HCIBTSDIO is not set
CONFIG_BT_HCIUART=m
@ -1475,12 +1476,12 @@ CONFIG_BT_HCIUART_NOKIA=m
# CONFIG_BT_HCIUART_BCSP is not set
# CONFIG_BT_HCIUART_ATH3K is not set
# CONFIG_BT_HCIUART_LL is not set
# CONFIG_BT_HCIUART_3WIRE is not set
CONFIG_BT_HCIUART_3WIRE=y
# CONFIG_BT_HCIUART_INTEL is not set
# CONFIG_BT_HCIUART_BCM is not set
# CONFIG_BT_HCIUART_QCA is not set
CONFIG_BT_HCIUART_BCM=y
CONFIG_BT_HCIUART_QCA=y
# CONFIG_BT_HCIUART_AG6XX is not set
# CONFIG_BT_HCIUART_MRVL is not set
CONFIG_BT_HCIUART_MRVL=y
# CONFIG_BT_HCIBCM203X is not set
# CONFIG_BT_HCIBPA10X is not set
# CONFIG_BT_HCIBFUSB is not set
@ -3003,7 +3004,8 @@ CONFIG_SERIAL_FSL_LINFLEXUART=m
# end of Serial drivers
CONFIG_SERIAL_MCTRL_GPIO=y
CONFIG_SERIAL_DEV_BUS=m
CONFIG_SERIAL_DEV_BUS=y
CONFIG_SERIAL_DEV_CTRL_TTYPORT=y
CONFIG_TTY_PRINTK=m
CONFIG_TTY_PRINTK_LEVEL=6
CONFIG_HVC_DRIVER=y

View File

@ -12,10 +12,10 @@ index aed41ff1d..92d796a33 100644
dtb-$(CONFIG_ARCH_ROCKCHIP) += rk3399-rock-pi-4.dtb
diff --git a/arch/arm64/boot/dts/rockchip/rk3399-orangepi-4.dts b/arch/arm64/boot/dts/rockchip/rk3399-orangepi-4.dts
new file mode 100644
index 00000000..17010305
index 000000000..1e1747ceb
--- /dev/null
+++ b/arch/arm64/boot/dts/rockchip/rk3399-orangepi-4.dts
@@ -0,0 +1,1130 @@
@@ -0,0 +1,1159 @@
+/*
+ * SPDX-License-Identifier: (GPL-2.0+ or MIT)
+ * Copyright (c) 2017 Fuzhou Rockchip Electronics Co., Ltd.
@ -198,7 +198,8 @@ index 00000000..17010305
+ "Headphone", "Headphone Jack";
+ simple-audio-card,routing =
+ "Mic Jack", "micbias1",
+ "IN1P", "Mic Jack",
+ "IN2P", "Mic Jack",
+ "IN3P", "Mic Jack",
+ "Headphone Jack", "HPOL",
+ "Headphone Jack", "HPOR";
+
@ -370,7 +371,7 @@ index 00000000..17010305
+ wifi_chip_type = "ap6255";
+ sdio_vref = <1800>;
+ WIFI,host_wake_irq = <&gpio0 3 GPIO_ACTIVE_HIGH>; /* GPIO0_a3 */
+ status = "okay";
+ status = "disabled";
+ };
+
+ rk_bluetooth: wireless-bluetooth {
@ -386,7 +387,7 @@ index 00000000..17010305
+ BT,reset_gpio = <&gpio0 9 GPIO_ACTIVE_HIGH>; /* GPIO0_B1 */
+ BT,wake_gpio = <&gpio2 26 GPIO_ACTIVE_HIGH>; /* GPIO2_D2 */
+ BT,wake_host_irq = <&gpio0 4 GPIO_ACTIVE_HIGH>; /* GPIO0_A4 */
+ status = "okay";
+ status = "disabled";
+ };
+};
+
@ -461,8 +462,21 @@ index 00000000..17010305
+
+&uart0 {
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart0_xfer &uart0_cts>;
+ pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
+ status = "okay";
+
+ bluetooth {
+ compatible = "brcm,bcm4345c5";
+ clocks = <&rk808 1>;
+ clock-names = "lpo";
+ device-wakeup-gpios = <&gpio2 RK_PD2 GPIO_ACTIVE_HIGH>;
+ host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>;
+ shutdown-gpios = <&gpio0 RK_PB1 GPIO_ACTIVE_HIGH>;
+ max-speed = <1500000>;
+ pinctrl-names = "default";
+ pinctrl-0 = <&bt_host_wake &bt_wake &bt_reset>;
+ };
+
+};
+
+&uart2 {
@ -1129,6 +1143,21 @@ index 00000000..17010305
+ <1 10 RK_FUNC_GPIO &pcfg_output_low>;
+ };
+ };
+
+ bt {
+ bt_host_wake: bt-host-wake {
+ rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+
+ bt_reset: bt-reset {
+ rockchip,pins = <0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+
+ bt_wake: bt-wake {
+ rockchip,pins = <2 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
+ };
+ };
+
+};
+
+&hdmi_in_vopb {

View File

@ -464,7 +464,7 @@ index 000000000..1e1747ceb
+ pinctrl-names = "default";
+ pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;
+ status = "okay";
+
+
+ bluetooth {
+ compatible = "brcm,bcm4345c5";
+ clocks = <&rk808 1>;