From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6B4D4C4332F for ; Mon, 21 Nov 2022 11:29:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230381AbiKUL27 (ORCPT ); Mon, 21 Nov 2022 06:28:59 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56974 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230309AbiKUL21 (ORCPT ); Mon, 21 Nov 2022 06:28:27 -0500 Received: from mail-lf1-x129.google.com (mail-lf1-x129.google.com [IPv6:2a00:1450:4864:20::129]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 692E218B0D for ; Mon, 21 Nov 2022 03:22:54 -0800 (PST) Received: by mail-lf1-x129.google.com with SMTP id b3so18363014lfv.2 for ; Mon, 21 Nov 2022 03:22:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=K36rHttUXqipmCdXq23O2OGPfeZt634/W4wWM3JG2Lk=; b=mXt0M2zct1dnVh3lcPxi7UmGqsWD3dg/a8w+svjsbPEs9i88Wf1d3HwAKk/lCzqp2l cvwW2YfXDGwyxeFNVfWqldpGFSRLuvdTzcicHU601RiMnWBxllSu9V3pnQbZ89YmVxJS oQOh6FH8c7UpgnCtCHSnk+9tNWYeGkkLuq60FmxEGqJkPBY+V4McNvE69gWhqUvEAJuV baoLsm37VkP+iHvukHQhH6vpVC5iGqV7jW4xkoHrMtLff/wCrn1cSdfL2nkEfAXxNx/F skci3RtTZyvjuZIGKitBkybyxuf17kstjrR/ov/sLdbJbZpuz5fmevbp0iIr0oVp8Lmf N18Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=K36rHttUXqipmCdXq23O2OGPfeZt634/W4wWM3JG2Lk=; b=fs93GQbCaMFe/DW5uRJD0BbE9e+6N8YjjHDf6c7tgXziIBjYMwY0AF/RHrBbotwMPg 6/8PSUG2IFP2ibOfq0FBZJ2jaAp0NzUrXovbbbKmPnASExiWRyrdEixbs4LhMeElUf07 13G5IHhkdz/UX8Yk+qeN62+J4ZQFdGFT4/hs9UCghIk0diQ+PriEmoPuSnh2hL+bqw4z soyvMliB2hWZFNFsps08LL0UEjA80gBDuYancZq31Q3kqLFNqJi1EVPP0mXMrq2WwPnR OMlo2/BYZOuEJoAuQwQxy7642DPcW+LhUGs+dMiS5h4gIYgqhpX7sQAjKOw74rgR98XW CO+Q== X-Gm-Message-State: ANoB5pk4NzD21LzOrDU0IHUQilcumhxaWh5INB/oYQ3xS8GkMAK//9/k 5wdtzCDmMn4eg7A0qfUL5xS8LA== X-Google-Smtp-Source: AA0mqf61tQmfKjVq8RvAAStA86Nq8poqfJTtaBWzYwXodyJF0I7qJtagWsotr2qvZR3relWeiewZ8w== X-Received: by 2002:a05:6512:3d8c:b0:497:a160:ed29 with SMTP id k12-20020a0565123d8c00b00497a160ed29mr5431720lfv.423.1669029772854; Mon, 21 Nov 2022 03:22:52 -0800 (PST) Received: from [192.168.1.101] (95.49.32.48.neoplus.adsl.tpnet.pl. [95.49.32.48]) by smtp.gmail.com with ESMTPSA id u24-20020a2e9b18000000b002637c04b472sm1439005lji.83.2022.11.21.03.22.51 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 21 Nov 2022 03:22:52 -0800 (PST) Message-ID: Date: Mon, 21 Nov 2022 12:22:50 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.5.0 Subject: Re: [PATCH 3/5] arm64: dts: qcom: msm8916-gplus-fl8005a: Add initial device tree Content-Language: en-US To: "Lin, Meng-Bo" , linux-kernel@vger.kernel.org Cc: Andy Gross , Bjorn Andersson , Rob Herring , Krzysztof Kozlowski , Linus Walleij , Stanislav Jakubek , Shawn Guo , Stephan Gerhold , Nikita Travkin , devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht References: <20221119202316.93142-1-linmengbo0689@protonmail.com> <20221119202639.93559-1-linmengbo0689@protonmail.com> From: Konrad Dybcio In-Reply-To: <20221119202639.93559-1-linmengbo0689@protonmail.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 19.11.2022 21:27, Lin, Meng-Bo wrote: > GPLUS FL8005A is a tablet using the MSM8916 SoC released in 2015. > > Add a device tree for with initial support for: > > - GPIO keys > - GPIO LEDs > - pm8916-vibrator > - SDHCI (internal and external storage) > - USB Device Mode > - UART > - WCNSS (WiFi/BT) > - Regulators > > Signed-off-by: Lin, Meng-Bo > --- > arch/arm64/boot/dts/qcom/Makefile | 1 + > .../boot/dts/qcom/msm8916-gplus-fl8005a.dts | 239 ++++++++++++++++++ > 2 files changed, 240 insertions(+) > create mode 100644 arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts > > diff --git a/arch/arm64/boot/dts/qcom/Makefile b/arch/arm64/boot/dts/qcom/Makefile > index afe496a93f94..5a2dcf726159 100644 > --- a/arch/arm64/boot/dts/qcom/Makefile > +++ b/arch/arm64/boot/dts/qcom/Makefile > @@ -9,6 +9,7 @@ dtb-$(CONFIG_ARCH_QCOM) += ipq8074-hk10-c1.dtb > dtb-$(CONFIG_ARCH_QCOM) += ipq8074-hk10-c2.dtb > dtb-$(CONFIG_ARCH_QCOM) += msm8916-alcatel-idol347.dtb > dtb-$(CONFIG_ARCH_QCOM) += msm8916-asus-z00l.dtb > +dtb-$(CONFIG_ARCH_QCOM) += msm8916-gplus-fl8005a.dtb > dtb-$(CONFIG_ARCH_QCOM) += msm8916-huawei-g7.dtb > dtb-$(CONFIG_ARCH_QCOM) += msm8916-longcheer-l8150.dtb > dtb-$(CONFIG_ARCH_QCOM) += msm8916-longcheer-l8910.dtb > diff --git a/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts b/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts > new file mode 100644 > index 000000000000..bed1fe984287 > --- /dev/null > +++ b/arch/arm64/boot/dts/qcom/msm8916-gplus-fl8005a.dts > @@ -0,0 +1,239 @@ > +// SPDX-License-Identifier: GPL-2.0-only > + > +/dts-v1/; > + > +#include "msm8916-pm8916.dtsi" > + > +#include > +#include > +#include > + > +/ { > + model = "GPLUS FL8005A"; > + compatible = "gplus,fl8005a", "qcom,msm8916"; > + chassis-type = "tablet"; > + > + aliases { > + serial0 = &blsp1_uart2; > + }; > + > + chosen { > + stdout-path = "serial0"; > + }; > + > + gpio-keys { > + compatible = "gpio-keys"; > + > + pinctrl-names = "default"; > + pinctrl-0 = <&gpio_keys_default>; > + > + label = "GPIO Buttons"; > + > + button-volume-up { > + label = "Volume Up"; > + gpios = <&msmgpio 107 GPIO_ACTIVE_LOW>; > + linux,code = ; > + }; > + }; > + > + gpio-leds { > + compatible = "gpio-leds"; > + > + pinctrl-names = "default"; > + pinctrl-0 = <&gpio_leds_default>; > + > + led-red { > + function = LED_FUNCTION_CHARGING; > + color = ; > + gpios = <&msmgpio 117 GPIO_ACTIVE_HIGH>; > + retain-state-suspended; > + }; > + > + led-green { > + function = LED_FUNCTION_CHARGING; > + color = ; > + gpios = <&msmgpio 118 GPIO_ACTIVE_HIGH>; > + retain-state-suspended; > + }; > + }; > + > + usb_id: usb-id { > + compatible = "linux,extcon-usb-gpio"; > + id-gpio = <&msmgpio 110 GPIO_ACTIVE_HIGH>; > + pinctrl-names = "default"; > + pinctrl-0 = <&usb_id_default>; > + }; > +}; > + > +&blsp1_uart2 { > + status = "okay"; > +}; > + > +&pm8916_resin { > + status = "okay"; > + linux,code = ; Status should go last, everywhere. > +}; > + > +&pm8916_vib { > + status = "okay"; > +}; > + > +&pronto { > + status = "okay"; > +}; > + > +&sdhc_1 { > + status = "okay"; > + > + pinctrl-names = "default", "sleep"; > + pinctrl-0 = <&sdc1_clk_on &sdc1_cmd_on &sdc1_data_on>; > + pinctrl-1 = <&sdc1_clk_off &sdc1_cmd_off &sdc1_data_off>; > +}; > + > +&sdhc_2 { > + status = "okay"; > + > + pinctrl-names = "default", "sleep"; > + pinctrl-0 = <&sdc2_clk_on &sdc2_cmd_on &sdc2_data_on>; > + pinctrl-1 = <&sdc2_clk_off &sdc2_cmd_off &sdc2_data_off>; > + > + cd-gpios = <&msmgpio 38 GPIO_ACTIVE_LOW>; > +}; > + > +&usb { > + status = "okay"; > + extcon = <&usb_id>, <&usb_id>; > +}; > + > +&usb_hs_phy { > + extcon = <&usb_id>; > +}; These two usb properties are not sorted properly. > + > +&smd_rpm_regulators { > + vdd_l1_l2_l3-supply = <&pm8916_s3>; > + vdd_l4_l5_l6-supply = <&pm8916_s4>; > + vdd_l7-supply = <&pm8916_s4>; > + > + s3 { > + regulator-min-microvolt = <1200000>; > + regulator-max-microvolt = <1300000>; > + }; > + > + s4 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <2100000>; > + }; > + > + l1 { > + regulator-min-microvolt = <1225000>; > + regulator-max-microvolt = <1225000>; > + }; > + > + l2 { > + regulator-min-microvolt = <1200000>; > + regulator-max-microvolt = <1200000>; > + }; > + > + l4 { > + regulator-min-microvolt = <2050000>; > + regulator-max-microvolt = <2050000>; > + }; > + > + l5 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + }; > + > + l6 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + }; > + > + l7 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + }; > + > + l8 { > + regulator-min-microvolt = <2850000>; > + regulator-max-microvolt = <2900000>; > + }; > + > + l9 { > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + }; > + > + l10 { > + regulator-min-microvolt = <2700000>; > + regulator-max-microvolt = <2800000>; > + }; > + > + l11 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <2950000>; > + regulator-allow-set-load; > + regulator-system-load = <200000>; Please swap the two properties. Other than that, LGTM Konrad > + }; > + > + l12 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <2950000>; > + }; > + > + l13 { > + regulator-min-microvolt = <3075000>; > + regulator-max-microvolt = <3075000>; > + }; > + > + l14 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <3300000>; > + }; > + > + l15 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <3300000>; > + }; > + > + l16 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <3300000>; > + }; > + > + l17 { > + regulator-min-microvolt = <2850000>; > + regulator-max-microvolt = <2850000>; > + }; > + > + l18 { > + regulator-min-microvolt = <2700000>; > + regulator-max-microvolt = <2700000>; > + }; > +}; > + > +&msmgpio { > + gpio_keys_default: gpio-keys-default-state { > + pins = "gpio107"; > + function = "gpio"; > + > + drive-strength = <2>; > + bias-pull-up; > + }; > + > + gpio_leds_default: gpio-led-default-state { > + pins = "gpio117", "gpio118"; > + function = "gpio"; > + > + drive-strength = <2>; > + bias-disable; > + }; > + > + usb_id_default: usb-id-default-state { > + pins = "gpio110"; > + function = "gpio"; > + > + drive-strength = <8>; > + bias-pull-up; > + }; > +};