Received: by 2002:a05:6358:d186:b0:cc:af7:9280 with SMTP id ka6csp15917rwb; Thu, 13 Oct 2022 20:07:58 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5hRO6lkQc+44vQmTCtntoK07jzfiPFMCx9rbGi4FiRY9rJ+d9uATdvCU9SwHa2AsXmWJQm X-Received: by 2002:a17:902:b589:b0:17f:5756:b3f9 with SMTP id a9-20020a170902b58900b0017f5756b3f9mr3171984pls.14.1665716878392; Thu, 13 Oct 2022 20:07:58 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1665716878; cv=pass; d=google.com; s=arc-20160816; b=EKnC9cTMV28EM9Dx3xaX4A/WKGboHn4vglDOiA7u4ALIeyn/0DDPlGEXp0MUgjur5L 3Q5ftiJZOIJCvpO1Z289+IVmwADOYE+qnKj2oYb5xxL+FYcDZuhkDtcqhtIiRHXalohd guFPuTZ1t/2BF37iA/4VZLK8+8yweFymlvb6tJaUvWF8ecScrkRDO2jegNtodZlo43x5 KvB57s+6A5yBdS32a2QySUw72xJdrj8AFb3jOxY6QnRhwB5v9sXWLWjEsQjiVlrYoNqJ j9M1UXKQIDjen65WUup+/SDgIfJ50lH7+d7+BezREBmSxxHi2z0wyI2O0ku7IfNMeHEY 2Xeg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent :content-transfer-encoding:organization:references:in-reply-to:date :cc:to:from:subject:message-id:dkim-signature; bh=Xch6Ahc6mpKh0o//bMOoqcUw4dYUZ7qun8hT0y/mZyM=; b=jyKNn9cxAAMbFTQfYI/Pz+DJwgYHYYLagMMBhmAQyT/dz10IshF3BEp6cjqFfjJaA4 PgYt9Q4biDzP7RZOc2l8f4kYut8ABK3dR25A2fadrPfJhseMTbLmYmZkHIcqmPzH+ZJq b7GgcyVlyBto3T9WwkcmyDhp6suwTTlyzyI3OZR48C3dW2vmwfX++5TNNi7WCN7oj6af 0/Pvq6jSnJesHCMGxckWig8xNcJAqGV56+w2AYbEm/JKcfXFhnbgIy6WLcXPk+u7A0HJ tqo0x6steOHFC/a0zyNHldl44CCUJ1PXHB517DrJonAIrRmVQQFcZk6JFCUx2D9/iLcf fHxA== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@icenowy.me header.s=zmail header.b=BtjTPZBX; arc=pass (i=1 spf=pass spfdomain=icenowy.me dkim=pass dkdomain=icenowy.me dmarc=pass fromdomain=icenowy.me>); 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u24-20020a631418000000b0045c59e9a8a9si1382381pgl.322.2022.10.13.20.07.46; Thu, 13 Oct 2022 20:07:58 -0700 (PDT) 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=@icenowy.me header.s=zmail header.b=BtjTPZBX; arc=pass (i=1 spf=pass spfdomain=icenowy.me dkim=pass dkdomain=icenowy.me dmarc=pass fromdomain=icenowy.me>); 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229748AbiJNC4j (ORCPT + 99 others); Thu, 13 Oct 2022 22:56:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43466 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229572AbiJNC4i (ORCPT ); Thu, 13 Oct 2022 22:56:38 -0400 Received: from sender4-op-o18.zoho.com (sender4-op-o18.zoho.com [136.143.188.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BCE1415CB25; Thu, 13 Oct 2022 19:56:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665716176; cv=none; d=zohomail.com; s=zohoarc; b=B4NBc5U0vzrb2IVhCmCpkKbCP4qH6kmHNgQSDj+NtSA5jy6VPbXqQlkeejCusg+9/wBJgR5EcHRDsUQIz6pxypvy52qRI/6ulmI1R2lmS/J1ZbTfW2ty8iBUBjDXIRJtBm3J05o6IQYIqLeRxKLF810fC8/Zo61/3MdlzEANXIU= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1665716176; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:To; bh=Xch6Ahc6mpKh0o//bMOoqcUw4dYUZ7qun8hT0y/mZyM=; b=lhkNZN9QvOxPKHYEAuGj43TIiyLsQArkOSH8XbnoRMmkzMai5z1JlRYDeabWrq0jqw7+Zr8J454IiHdmIx20AG9MjcdsP6eYC6493ZgZV6umO8OWa21GIFf6Ckz111JoJVLYt5fyNA/lsPGmVU3EMpDUHqoeX3R/w/EkUmcK4HU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=icenowy.me; spf=pass smtp.mailfrom=uwu@icenowy.me; dmarc=pass header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1665716176; s=zmail; d=icenowy.me; i=uwu@icenowy.me; h=Message-ID:Subject:Subject:From:From:To:To:Cc:Cc:Date:Date:In-Reply-To:References:Content-Type:Content-Transfer-Encoding:MIME-Version:Message-Id:Reply-To; bh=Xch6Ahc6mpKh0o//bMOoqcUw4dYUZ7qun8hT0y/mZyM=; b=BtjTPZBXxvbVdpOh5ub/SM0ayFIbV8M1wxZx54XiFfx8hRU/8tD6FLJhpUrxjMVN jbv1ebptl52p5/ndZF3nTB0YRCeGVfQ+nM+bwk1H+3YZe5aShg4rznGSNsd3dq/9J1y 0M7HZZQzzgvtjqiwEyW6IkMxed3z6SKH5OPSXxhU= Received: from edelgard.fodlan.icenowy.me (112.94.102.144 [112.94.102.144]) by mx.zohomail.com with SMTPS id 1665716174157848.8917127364606; Thu, 13 Oct 2022 19:56:14 -0700 (PDT) Message-ID: Subject: Re: Re: [PATCH v2 04/10] phy: sun4i-usb: add support for the USB PHY on F1C100s SoC From: Icenowy Zheng To: Jernej =?gb2312?Q?=810=947krabec?= , Rob Herring , Krzysztof Kozlowski , Chen-Yu Tsai , Samuel Holland , Greg Kroah-Hartman , Andre Przywara Cc: soc@kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-phy@lists.infradead.org, linux-usb@vger.kernel.org Date: Fri, 14 Oct 2022 10:56:08 +0800 In-Reply-To: <3442772.V25eIC5XRa@kista> References: <20221012055602.1544944-1-uwu@icenowy.me> <4218006.ejJDZkT8p0@kista> <439b685e3aada19021d94669f6f855f1fc81d08e.camel@icenowy.me> <3442772.V25eIC5XRa@kista> Organization: Anthon Open-Source Community Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.44.4 MIME-Version: 1.0 X-ZohoMailClient: External X-Spam-Status: No, score=-0.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLACK autolearn=no 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 =E5=9C=A8 2022-10-13=E6=98=9F=E6=9C=9F=E5=9B=9B=E7=9A=84 20:25 +0200=EF=BC= =8CJernej =C5=A0krabec=E5=86=99=E9=81=93=EF=BC=9A > Dne =C4=8Detrtek, 13. oktober 2022 ob 10:49:51 CEST je Icenowy Zheng > napisal(a): > > =E5=9C=A8 2022-10-12=E6=98=9F=E6=9C=9F=E4=B8=89=E7=9A=84 23:21 +0200=EF= =BC=8CJernej =C5=A0krabec=E5=86=99=E9=81=93=EF=BC=9A > >=20 > > > Hi Icenowy, > > >=20 > > > Dne sreda, 12. oktober 2022 ob 07:55:56 CEST je Icenowy Zheng > > >=20 > > > napisal(a): > > > > The F1C100s SoC has one USB OTG port connected to a MUSB > > > > controller. > > > >=20 > > > > Add support for its USB PHY. > > > >=20 > > > > Signed-off-by: Icenowy Zheng > > > > --- > > > > No changes since v1. > > > >=20 > > > > =C2=A0drivers/phy/allwinner/phy-sun4i-usb.c | 11 +++++++++++ > > > > =C2=A01 file changed, 11 insertions(+) > > > >=20 > > > > diff --git a/drivers/phy/allwinner/phy-sun4i-usb.c > > > > b/drivers/phy/allwinner/phy-sun4i-usb.c index > > > > 3a3831f6059a..2f94cb77637b > > > > 100644 > > > > --- a/drivers/phy/allwinner/phy-sun4i-usb.c > > > > +++ b/drivers/phy/allwinner/phy-sun4i-usb.c > > > > @@ -109,6 +109,7 @@ enum sun4i_usb_phy_type { > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 sun8i_v3s_phy, > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 sun50i_a64_phy, > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 sun50i_h6_phy, > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 suniv_f1c100s_phy, > > > > =C2=A0}; > > > >=20 > > > > =C2=A0struct sun4i_usb_phy_cfg { > > > > @@ -859,6 +860,14 @@ static int sun4i_usb_phy_probe(struct > > > > platform_device > > > > *pdev) return 0; > > > > =C2=A0} > > > >=20 > > > > +static const struct sun4i_usb_phy_cfg suniv_f1c100s_cfg =3D { > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .num_phys =3D 1, > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .type =3D suniv_f1c100s_phy, > > >=20 > > > I think you should just use sun4i_a10_phy. It has no special > > > handling. I don't > > > see a point adding new phy types if there is no special cases for > > > it. > >=20 > > Sounds reasonable, although I think we should finally drop .type > > and > > use only describing items. >=20 > That would be even better. Will you do it? At least not now. But I will at least drop suniv_f1c100s_phy in the next revision. >=20 > >=20 > > > Best regards, > > > Jernej > > >=20 > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .disc_thresh =3D 3, > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .phyctl_offset =3D REG_PHYCTL= _A10, > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .dedicated_clocks =3D true, > > > > +}; > > > > + > > > > =C2=A0static const struct sun4i_usb_phy_cfg sun4i_a10_cfg =3D { > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .num_phys =3D 3, > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .type =3D sun4i_a10_phy, > > > > @@ -988,6 +997,8 @@ static const struct of_device_id > > > > sun4i_usb_phy_of_match[] =3D { { .compatible =3D > > > > "allwinner,sun50i-a64-usb-phy", > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .data =3D &s= un50i_a64_cfg}, > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { .compatible =3D "allwi= nner,sun50i-h6-usb-phy", .data =3D > > >=20 > > > &sun50i_h6_cfg }, > > >=20 > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { .compatible =3D "allwinner,= suniv-f1c100s-usb-phy", > > > > +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 .data =3D &suniv_= f1c100s_cfg }, > > > > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { }, > > > > =C2=A0}; > > > > =C2=A0MODULE_DEVICE_TABLE(of, sun4i_usb_phy_of_match); > > > > -- > > > > 2.37.1 >=20 >=20