Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp4660076rwl; Wed, 28 Dec 2022 07:11:52 -0800 (PST) X-Google-Smtp-Source: AMrXdXvW0CsCc5yfxG5YcMtusvjr04373y+GpNCjvXarulMnNs161VkuBTluoWMU0Tt8oDoE2cqY X-Received: by 2002:a05:6a20:1e4b:b0:af:8ff3:fc7b with SMTP id cy11-20020a056a201e4b00b000af8ff3fc7bmr27841131pzb.25.1672240312468; Wed, 28 Dec 2022 07:11:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672240312; cv=none; d=google.com; s=arc-20160816; b=fkOTpKCWGByZIgqmrksTamyY1tfCyjI0JULwBxQhHNIt0Rel4MreP2AelVB0mUSldx 3qGuuFJuc7Xwsxa5J5oaF3SzcgpQN8zx6Tb9eNrDQ85QP8wUR7AB5WE+wWIhLGOYeVLt 5QBPA2eHlk881pZFN7whYFXBi3C2rKdoRpco1cajVrqiz+vxzcShBJ3qkc3ti+TIWLRo beaiQkm2ERjAp18aFhm0RBVvZ2rvnAGXBdrWnfuym95KYl48hE7GZtEVP9kquFiyek/V 3uc7IcVP0SlV+wLBsKHxkTpfGO3UXJlUmaqL1uL9pKniNrxVLeSNozK85nQc88/pVfMk kddA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Uc4+euhS4LXEVfDdqc1yEXKVcVuiUdM76BbtiebwHOU=; b=0fjImzruIs1+UuqqBO7qW+IOwW188CmYrD2aoiHCS+agN0D6cMYkMixmpm6fDUz34x axqbZ+bK6ec2uq8j5sVtnVP5s7NCxOMNfPq5Ykza63/rxJLODKOt14l8Ko6B07KUDKxu /WPDHT72CgKroibLvbA2LqJZJTbMSlFe5Jy/75I7Gyn8rZP4JepNGxcxIE4P70mgQweA Aju7Z2BQ9ehmL9I7f2rDUPAnLT49jWTvBf5j252+svKk81yRMJ4TWNTM3B/UYClKcGDu cMbeXxT7rzRfJuZ4XL/BnDRIfC95slqsDjvGZgkQXeddUQBIWR3QuA6tthNNuV5qTE7F 3r5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ASoQ6raw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f130-20020a636a88000000b0047959422029si16287211pgc.395.2022.12.28.07.11.43; Wed, 28 Dec 2022 07:11:52 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=ASoQ6raw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232763AbiL1OYB (ORCPT + 64 others); Wed, 28 Dec 2022 09:24:01 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229627AbiL1OX7 (ORCPT ); Wed, 28 Dec 2022 09:23:59 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B73AEE0E6; Wed, 28 Dec 2022 06:23:58 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 58CE4B816E1; Wed, 28 Dec 2022 14:23:57 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0FB14C433D2; Wed, 28 Dec 2022 14:23:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1672237436; bh=U6K/0V7altRlePQgzg3SYcQ96jXCm6YD0UaJiksHmgs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ASoQ6rawQwU3jGTGh2yhyOm1ShVJoN8CDTbOMj/CcqIAFiM7uIZELwBMrdGJsjt9F gzyHm6qsxawB16HpnJQ/NbUhhOfkVEyzfHSSdVMyaVmc+23Uep3MW+VjE7ELPQXm3j R+wNdLf/0ZIAnIS23rW5bFPxnaQXmNRWKxXt6QWWUAWuwpggwNqKYAVsWrRnO8tN4G m6HOCuzjONvQ8wOgp46CEWHxNHhwQ1+I1MtattVkU9Kt6KB55NPQfciZYYwkI0OYvG t3JxpwwNXMuypfBGj+7RbB+sbO30ZfnW/Z3aTFhl8OLYc0hjtXi3GIsF71XjSBIrGi kXr8AsL8rO4fA== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1pAXLa-0006XI-BU; Wed, 28 Dec 2022 15:23:59 +0100 Date: Wed, 28 Dec 2022 15:23:58 +0100 From: Johan Hovold To: Luca Weiss Cc: linux-arm-msm@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 3/3] arm64: dts: qcom: sm6350: Use specific qmpphy compatible Message-ID: References: <20221130081430.67831-1-luca.weiss@fairphone.com> <20221130081430.67831-3-luca.weiss@fairphone.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221130081430.67831-3-luca.weiss@fairphone.com> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 30, 2022 at 09:14:29AM +0100, Luca Weiss wrote: > The sc7180 phy compatible works fine for some cases, but it turns out > sm6350 does need proper phy configuration in the driver, so use the > newly added sm6350 compatible. > > Because the sm6350 compatible is using the new binding, we need to > change the node quite a bit to match it. > > This fixes qmpphy init when no USB cable is plugged in during bootloader > stage. > > Signed-off-by: Luca Weiss > --- > Changes since v2: > * Rebase on https://lore.kernel.org/all/20221111094729.11842-2-johan+linaro@kernel.org/ > While this commit deletes the changes there it's still good to get it > in for completeness > * Fix clocks, add power-domain > > arch/arm64/boot/dts/qcom/sm6350.dtsi | 50 ++++++++-------------------- > 1 file changed, 14 insertions(+), 36 deletions(-) > > diff --git a/arch/arm64/boot/dts/qcom/sm6350.dtsi b/arch/arm64/boot/dts/qcom/sm6350.dtsi > index 43324bf291c3..cb48f03a6cc9 100644 > --- a/arch/arm64/boot/dts/qcom/sm6350.dtsi > +++ b/arch/arm64/boot/dts/qcom/sm6350.dtsi > @@ -11,6 +11,7 @@ > #include > #include > #include > +#include > #include > #include > > @@ -1119,49 +1120,26 @@ usb_1_hsphy: phy@88e3000 { > resets = <&gcc GCC_QUSB2PHY_PRIM_BCR>; > }; > > - usb_1_qmpphy: phy@88e9000 { > - compatible = "qcom,sc7180-qmp-usb3-dp-phy"; > - reg = <0 0x088e9000 0 0x200>, > - <0 0x088e8000 0 0x40>, > - <0 0x088ea000 0 0x200>; > - status = "disabled"; > - #address-cells = <2>; > - #size-cells = <2>; > - ranges; > + usb_1_qmpphy: phy@88e8000 { > + compatible = "qcom,sm6350-qmp-usb3-dp-phy"; > + reg = <0 0x088e8000 0 0x3000>; > > clocks = <&gcc GCC_USB3_PRIM_PHY_AUX_CLK>, > - <&xo_board>, > - <&rpmhcc RPMH_QLINK_CLK>, > - <&gcc GCC_USB3_PRIM_PHY_COM_AUX_CLK>; > - clock-names = "aux", "cfg_ahb", "ref", "com_aux"; > + <&gcc GCC_USB3_PRIM_CLKREF_CLK>, > + <&gcc GCC_USB3_PRIM_PHY_COM_AUX_CLK>, > + <&gcc GCC_USB3_PRIM_PHY_PIPE_CLK>; > + clock-names = "aux", "ref", "com_aux", "usb3_pipe"; > + > + power-domains = <&gcc USB30_PRIM_GDSC>; > > resets = <&gcc GCC_USB3_DP_PHY_PRIM_BCR>, > <&gcc GCC_USB3_PHY_PRIM_BCR>; These have been switched too. > reset-names = "phy", "common"; > > - usb_1_ssphy: usb3-phy@88e9200 { > - reg = <0 0x088e9200 0 0x200>, > - <0 0x088e9400 0 0x200>, > - <0 0x088e9c00 0 0x400>, > - <0 0x088e9600 0 0x200>, > - <0 0x088e9800 0 0x200>, > - <0 0x088e9a00 0 0x100>; > - #clock-cells = <0>; > - #phy-cells = <0>; > - clocks = <&gcc GCC_USB3_PRIM_PHY_PIPE_CLK>; > - clock-names = "pipe0"; > - clock-output-names = "usb3_phy_pipe_clk_src"; > - }; > + #clock-cells = <1>; > + #phy-cells = <1>; > > - dp_phy: dp-phy@88ea200 { > - reg = <0 0x088ea200 0 0x200>, > - <0 0x088ea400 0 0x200>, > - <0 0x088eaa00 0 0x200>, > - <0 0x088ea600 0 0x200>, > - <0 0x088ea800 0 0x200>; > - #phy-cells = <0>; > - #clock-cells = <1>; > - }; > + status = "disabled"; > }; > > dc_noc: interconnect@9160000 { > @@ -1235,7 +1213,7 @@ usb_1_dwc3: usb@a600000 { > snps,dis_enblslpm_quirk; > snps,has-lpm-erratum; > snps,hird-threshold = /bits/ 8 <0x10>; > - phys = <&usb_1_hsphy>, <&usb_1_ssphy>; > + phys = <&usb_1_hsphy>, <&usb_1_qmpphy QMP_USB43DP_USB3_PHY>; > phy-names = "usb2-phy", "usb3-phy"; > }; > }; Looks good otherwise. With the resets fixed you can add my: Reviewed-by: Johan Hovold Johan