Re: [PATCH RESEND] arm64: dts: qcom: Add support for OnePlus 5/5T
On Mon 22 Mar 11:16 CDT 2021, Jami Kettunen wrote: [..] > diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts > b/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts > new file mode 100644 > index ..13b6b8ad4679 > --- /dev/null > +++ b/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts > @@ -0,0 +1,42 @@ > +// SPDX-License-Identifier: GPL-2.0 The DT community prefer to get these under BSD-3-Clause instead? Would you be willing to change this? > +/* > + * OnePlus 5 (cheeseburger) device tree > + * > + * Copyright (c) 2021, Jami Kettunen > + */ > + [..] > diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi > b/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi [..] > +/* Disable all remoteprocs for now until RPM XO clock is usable */ > +_mss { Can you please disable this in msm8998.dtsi and make devices explicitly enable it instead - in a separate patch. > + status = "disabled"; > +}; > + [..] > +/* Hold off on WLAN enablement until MSS remoteproc and friends are brought > up */ Are you saying leave disabled until MSS is up? If so then move the comment inside the node and make it something like "Leave disabled until MSS is functional" - to make it clearer that this relates to the "status" of the node. Regards, Bjorn > + { > + vdd-0.8-cx-mx-supply = <_l5a_0p8>; > + vdd-1.8-xo-supply = <_l7a_1p8>; > + vdd-1.3-rfa-supply = <_l17a_1p3>; > + vdd-3.3-ch0-supply = <_l25a_3p3>; > +}; > diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-dumpling.dts > b/arch/arm64/boot/dts/qcom/msm8998-oneplus-dumpling.dts > new file mode 100644 > index ..b46214a32478 > --- /dev/null > +++ b/arch/arm64/boot/dts/qcom/msm8998-oneplus-dumpling.dts > @@ -0,0 +1,25 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * OnePlus 5T (dumpling) device tree > + * > + * Copyright (c) 2021, Jami Kettunen > + */ > + > +#include "msm8998-oneplus-common.dtsi" > + > +/ { > + model = "OnePlus 5T"; > + compatible = "oneplus,dumpling", "qcom,msm8998"; > + /* Required for bootloader to select correct board */ > + qcom,board-id = <8 0 17801 43>; > +}; > + > +/* Update the screen height values from 1920 to 2160 on the 5T */ > + { > + height = <2160>; > +}; > + > +/* Adjust digitizer area height to match the 5T's taller panel */ > +_f12 { > + touchscreen-y-mm = <137>; > +}; > -- > 2.30.1 >
Re: [PATCH RESEND] arm64: dts: qcom: Add support for OnePlus 5/5T
On Mon, Mar 22, 2021 at 18:16, Jami Kettunen wrote: Add device trees for OnePlus 5 (cheeseburger) and 5T (dumpling) MSM8998 SoC smartphones with initial support included for: - UFS internal storage - USB peripheral mode - Display - Touch - Bluetooth - Hall effect sensor - Power and volume buttons - Capacitive keypad button backlight (on cheeseburger) Signed-off-by: Jami Kettunen Reviewed-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/Makefile | 2 + .../dts/qcom/msm8998-oneplus-cheeseburger.dts | 42 ++ .../boot/dts/qcom/msm8998-oneplus-common.dtsi | 519 ++ .../dts/qcom/msm8998-oneplus-dumpling.dts | 25 + 4 files changed, 588 insertions(+) create mode 100644 arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts create mode 100644 arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi create mode 100644 arch/arm64/boot/dts/qcom/msm8998-oneplus-dumpling.dts diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile index 549a7a2151d4..1beb73f564f7 100644 --- a/arch/arm64/boot/dts/qcom/Makefile +++ b/arch/arm64/boot/dts/qcom/Makefile @@ -27,6 +27,8 @@ dtb-$(CONFIG_ARCH_QCOM) += msm8998-asus-novago-tp370ql.dtb dtb-$(CONFIG_ARCH_QCOM)+= msm8998-hp-envy-x2.dtb dtb-$(CONFIG_ARCH_QCOM)+= msm8998-lenovo-miix-630.dtb dtb-$(CONFIG_ARCH_QCOM)+= msm8998-mtp.dtb +dtb-$(CONFIG_ARCH_QCOM)+= msm8998-oneplus-cheeseburger.dtb +dtb-$(CONFIG_ARCH_QCOM)+= msm8998-oneplus-dumpling.dtb dtb-$(CONFIG_ARCH_QCOM)+= qcs404-evb-1000.dtb dtb-$(CONFIG_ARCH_QCOM)+= qcs404-evb-4000.dtb dtb-$(CONFIG_ARCH_QCOM)+= qrb5165-rb5.dtb diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts b/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts new file mode 100644 index ..13b6b8ad4679 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts @@ -0,0 +1,42 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * OnePlus 5 (cheeseburger) device tree + * + * Copyright (c) 2021, Jami Kettunen + */ + +#include +#include "msm8998-oneplus-common.dtsi" + +/ { + model = "OnePlus 5"; + compatible = "oneplus,cheeseburger", "qcom,msm8998"; + /* Required for bootloader to select correct board */ + qcom,board-id = <8 0 16859 23>; + + /* Capacitive keypad button backlight */ + leds { + compatible = "gpio-leds"; + + pinctrl-names = "default"; + pinctrl-0 = <_backlight_default>; + + button-backlight { + gpios = <_gpio 5 GPIO_ACTIVE_HIGH>; + color = ; + function = LED_FUNCTION_KBD_BACKLIGHT; + default-state = "off"; + }; + }; +}; + +_gpio { + button_backlight_default: button-backlight-default { + pinconf { + pins = "gpio5"; + function = "normal"; + bias-pull-down; + qcom,drive-strength = ; + }; + }; +}; diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi b/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi new file mode 100644 index ..1de4d19ed143 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi @@ -0,0 +1,519 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * OnePlus 5(T) (cheeseburger / dumpling) common device tree source based on msm8998-mtp.dtsi + * + * Copyright (c) 2021, Jami Kettunen + * Copyright (c) 2016, The Linux Foundation. All rights reserved. + */ + +/dts-v1/; + +#include +#include +#include "msm8998.dtsi" +#include "pm8998.dtsi" +#include "pmi8998.dtsi" +#include "pm8005.dtsi" + +/ { + /* Required for bootloader to select correct board */ + qcom,msm-id = <292 0x20001>; /* 8998 v2.1 */ + + chosen { + #address-cells = <2>; + #size-cells = <2>; + ranges; + + /* Use display framebuffer setup by the UEFI XBL bootloader for simplefb */ + framebuffer0: framebuffer@9d40 { + compatible = "simple-framebuffer"; + reg = <0x0 0x9d40 0x0 0x240>; + width = <1080>; + height = <1920>; + stride = <(1080 * 4)>; + format = "a8r8g8b8"; + }; + }; + + reserved-memory { + /* Bootloader display framebuffer region */ + cont_splash_mem: memory@9d40 { + reg = <0x0 0x9d40 0x0 0x240>; + no-map; + }; + + /* For getting crash logs using Android downstream kernels */ + ramoops@ac00 { + compatible = "ramoops"; + reg = <0x0 0xac00 0x0 0x20>; + console-size =
[PATCH RESEND] arm64: dts: qcom: Add support for OnePlus 5/5T
Add device trees for OnePlus 5 (cheeseburger) and 5T (dumpling) MSM8998 SoC smartphones with initial support included for: - UFS internal storage - USB peripheral mode - Display - Touch - Bluetooth - Hall effect sensor - Power and volume buttons - Capacitive keypad button backlight (on cheeseburger) Signed-off-by: Jami Kettunen Reviewed-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/Makefile | 2 + .../dts/qcom/msm8998-oneplus-cheeseburger.dts | 42 ++ .../boot/dts/qcom/msm8998-oneplus-common.dtsi | 519 ++ .../dts/qcom/msm8998-oneplus-dumpling.dts | 25 + 4 files changed, 588 insertions(+) create mode 100644 arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts create mode 100644 arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi create mode 100644 arch/arm64/boot/dts/qcom/msm8998-oneplus-dumpling.dts diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile index 549a7a2151d4..1beb73f564f7 100644 --- a/arch/arm64/boot/dts/qcom/Makefile +++ b/arch/arm64/boot/dts/qcom/Makefile @@ -27,6 +27,8 @@ dtb-$(CONFIG_ARCH_QCOM) += msm8998-asus-novago-tp370ql.dtb dtb-$(CONFIG_ARCH_QCOM)+= msm8998-hp-envy-x2.dtb dtb-$(CONFIG_ARCH_QCOM)+= msm8998-lenovo-miix-630.dtb dtb-$(CONFIG_ARCH_QCOM)+= msm8998-mtp.dtb +dtb-$(CONFIG_ARCH_QCOM)+= msm8998-oneplus-cheeseburger.dtb +dtb-$(CONFIG_ARCH_QCOM)+= msm8998-oneplus-dumpling.dtb dtb-$(CONFIG_ARCH_QCOM)+= qcs404-evb-1000.dtb dtb-$(CONFIG_ARCH_QCOM)+= qcs404-evb-4000.dtb dtb-$(CONFIG_ARCH_QCOM)+= qrb5165-rb5.dtb diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts b/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts new file mode 100644 index ..13b6b8ad4679 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/msm8998-oneplus-cheeseburger.dts @@ -0,0 +1,42 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * OnePlus 5 (cheeseburger) device tree + * + * Copyright (c) 2021, Jami Kettunen + */ + +#include +#include "msm8998-oneplus-common.dtsi" + +/ { + model = "OnePlus 5"; + compatible = "oneplus,cheeseburger", "qcom,msm8998"; + /* Required for bootloader to select correct board */ + qcom,board-id = <8 0 16859 23>; + + /* Capacitive keypad button backlight */ + leds { + compatible = "gpio-leds"; + + pinctrl-names = "default"; + pinctrl-0 = <_backlight_default>; + + button-backlight { + gpios = <_gpio 5 GPIO_ACTIVE_HIGH>; + color = ; + function = LED_FUNCTION_KBD_BACKLIGHT; + default-state = "off"; + }; + }; +}; + +_gpio { + button_backlight_default: button-backlight-default { + pinconf { + pins = "gpio5"; + function = "normal"; + bias-pull-down; + qcom,drive-strength = ; + }; + }; +}; diff --git a/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi b/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi new file mode 100644 index ..1de4d19ed143 --- /dev/null +++ b/arch/arm64/boot/dts/qcom/msm8998-oneplus-common.dtsi @@ -0,0 +1,519 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * OnePlus 5(T) (cheeseburger / dumpling) common device tree source based on msm8998-mtp.dtsi + * + * Copyright (c) 2021, Jami Kettunen + * Copyright (c) 2016, The Linux Foundation. All rights reserved. + */ + +/dts-v1/; + +#include +#include +#include "msm8998.dtsi" +#include "pm8998.dtsi" +#include "pmi8998.dtsi" +#include "pm8005.dtsi" + +/ { + /* Required for bootloader to select correct board */ + qcom,msm-id = <292 0x20001>; /* 8998 v2.1 */ + + chosen { + #address-cells = <2>; + #size-cells = <2>; + ranges; + + /* Use display framebuffer setup by the UEFI XBL bootloader for simplefb */ + framebuffer0: framebuffer@9d40 { + compatible = "simple-framebuffer"; + reg = <0x0 0x9d40 0x0 0x240>; + width = <1080>; + height = <1920>; + stride = <(1080 * 4)>; + format = "a8r8g8b8"; + }; + }; + + reserved-memory { + /* Bootloader display framebuffer region */ + cont_splash_mem: memory@9d40 { + reg = <0x0 0x9d40 0x0 0x240>; + no-map; + }; + + /* For getting crash logs using Android downstream kernels */ + ramoops@ac00 { + compatible = "ramoops"; + reg = <0x0 0xac00 0x0 0x20>; + console-size = <0x8>; + pmsg-size =