Received: by 2002:a05:7412:3b8b:b0:fc:a2b0:25d7 with SMTP id nd11csp47737rdb; Wed, 7 Feb 2024 20:48:41 -0800 (PST) X-Google-Smtp-Source: AGHT+IH6daqIEowTmx7/djrNp/2DPfQswBsK1kigDKMZzEnhPZGYhUj4d9qAwnlqgzezpnIVrrJh X-Received: by 2002:ad4:5d4e:0:b0:68c:c6ff:2fd8 with SMTP id jk14-20020ad45d4e000000b0068cc6ff2fd8mr1368031qvb.49.1707367721319; Wed, 07 Feb 2024 20:48:41 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707367721; cv=pass; d=google.com; s=arc-20160816; b=q8KDjI0VzcPYhMI31TrXWrvmRwmtneQIEUMHsDMYi/kmQZq965wu9XojbHT1oZtK86 cRRL7iXC8rUHWQtMz1tRZvmX8bV2MhtJ1S50vzwblVtsGDPbID4FLm6ag2mBhTw2REdC hLPpC55vvdAuLj2Kz0CbSBRCOYUso2AgrVlFM8gwJl6DKshatO4HcM7sBZk+6dQDSYwG kAsgCF08zQcNwAsCLhcxAbh1xX0596AaTEwKgEbnnFOvQue87soujFLTZZgTXeUd+nH2 h+/dh4vrBD/GhrGMuPO1/pWCCdiCe1ech2kl9mKSMFdJU2zWms8IWpvpKrzSFAZLjjKc w31g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=6mBo36jd0eUhpi32VDcylBEhhD0XmvjZ+0/CEDOcvh8=; fh=+j4IG5wjcqBOyKnlbHFIIFbMNXUGPQplByQ7X2lqDcU=; b=DardrDmC/zJG/a6sXezU1Mp6GD3D7sVtn4KzJXrGc+C6g8RZstvD0psdDgv6nA8kk7 MF+FzNXxD8hsaifslYzTWN39Gro9DWS6QxWmt4qLnSU0QPAm+9RyI6JBpsPkZWDb7330 OExHVH2SxdLjPXqAJHITgbVOLOL5YfGnN3tGPnsfFzWGM+vgc2QWi2bv9Xizx7o4+766 Uqm4B18XUEyff70kpWSrEB1gMITtADLyqoaPwYjFZGSJPhzSwakMHaPx76el+c36FgCy Ss6hhq0BantlwXz0EXFR5GpoTNyxNvzth7OpEWty+e5HNQyJR08sNalS2d+jO/gDALdM kRqA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=KyLsgFOy; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-57466-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-57466-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com X-Forwarded-Encrypted: i=2; AJvYcCUcJqMoMaUNgoyASBATzR7hpvqyjBULy66yVDn5uBthiSX/gJVyYI66fdP16TtVAYVvNyjjHFRED/pOV0jKVsw7vAfKvZGg9V5B1GGlbg== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id e5-20020ad44185000000b0068cb760019fsi2489288qvp.268.2024.02.07.20.48.41 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 07 Feb 2024 20:48:41 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-57466-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=KyLsgFOy; arc=pass (i=1 spf=pass spfdomain=quicinc.com dkim=pass dkdomain=quicinc.com dmarc=pass fromdomain=quicinc.com); spf=pass (google.com: domain of linux-kernel+bounces-57466-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-57466-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 094BE1C2196E for ; Thu, 8 Feb 2024 04:48:41 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 148FF67A17; Thu, 8 Feb 2024 04:48:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="KyLsgFOy" Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7224E679F8; Thu, 8 Feb 2024 04:48:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.180.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707367709; cv=none; b=Lujk/gvUuUqg3VXgYWRD6oxpzn9LbCrJjMco3Lclt6nJizGe9wxY83hKHeW+DHF0HLKQ0rf8Hy8egqhSxt99KGvnR9DeW2SMboADZSDUjM6RsNAavj2Ha7qyWLZN1D7qajqL7OMLLuU+bNPn4JLLS4GytVpWGLPLmp3+XMlutCc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707367709; c=relaxed/simple; bh=kPtJPhKhm6zFTjkp+nsXqycQ5MLkVr6QmfvGNYifTFA=; h=Message-ID:Date:MIME-Version:Subject:To:CC:References:From: In-Reply-To:Content-Type; b=ex+GpaYOJVf/nJc1S2VlLb+Z+Zufi+3VZrr5wFvQFT8yheGJal3jmhxR/YhT+9TNf8Go2rItBtzBqsKeed0w8B8yFsYgujdmguuGmQXixakCicRB8YxF2opJvmV2TXBZ094iEj+mG8usOphOzQJl2tnYFyBOp8mRAXioCuP3pAE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com; spf=pass smtp.mailfrom=quicinc.com; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b=KyLsgFOy; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=quicinc.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=quicinc.com Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 4184ba2X000421; Thu, 8 Feb 2024 04:48:22 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= message-id:date:mime-version:subject:to:cc:references:from :in-reply-to:content-type:content-transfer-encoding; s= qcppdkim1; bh=6mBo36jd0eUhpi32VDcylBEhhD0XmvjZ+0/CEDOcvh8=; b=Ky LsgFOyYqQzYah+2Cx0QTvSl8EM6jwHssb7vywgd19WbYj3HV0s/7wodJHtJu5dkF 0m7M6UXbA/npgsbgpV4yxNt92lvd/3Q8c/XiZTw7XEkb9TB1GOLqd1IbpdSsdCos Jp4XZgTtqFOhKq4L5u+ZIfOb6/Bge6igczbGYY0AW4I4qw/b8cAsP53LUMsHzKE7 ORyKiVG3xP5TptOferMr978K6ysrNeE42InLWlqGaFtMnEKZNPlW5gponmzO9l9e 4J0y2Jwd7xmvJYtC9wDG38+HRb3KFvqQdggdaSJU3yYPiXaGtjP6Nrc1FpTaOTBi /kMpY7BCqReIQ1tyb+nA== Received: from nalasppmta05.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3w4hhk8qff-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 08 Feb 2024 04:48:22 +0000 (GMT) Received: from nalasex01a.na.qualcomm.com (nalasex01a.na.qualcomm.com [10.47.209.196]) by NALASPPMTA05.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 4184mKf0018231 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 8 Feb 2024 04:48:21 GMT Received: from [10.216.53.86] (10.80.80.8) by nalasex01a.na.qualcomm.com (10.47.209.196) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Wed, 7 Feb 2024 20:48:17 -0800 Message-ID: <7500f1f8-1d97-4fa9-a7cd-7dea0ad52e00@quicinc.com> Date: Thu, 8 Feb 2024 10:18:12 +0530 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/3] arm64: dts: qcom: sa8295p: Enable tertiary controller and its 4 USB ports To: Dmitry Baryshkov CC: Krzysztof Kozlowski , Konrad Dybcio , Rob Herring , Bjorn Andersson , Conor Dooley , , , , , References: <20240206114745.1388491-1-quic_kriskura@quicinc.com> <20240206114745.1388491-3-quic_kriskura@quicinc.com> <0470a930-d629-4467-b619-58d3e76f59a7@quicinc.com> Content-Language: en-US From: Krishna Kurapati PSSNV In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: nasanex01b.na.qualcomm.com (10.46.141.250) To nalasex01a.na.qualcomm.com (10.47.209.196) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: awHsPcJpjndywQK65G6arvL2q3aTze8X X-Proofpoint-GUID: awHsPcJpjndywQK65G6arvL2q3aTze8X X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-02-08_01,2024-02-07_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 mlxlogscore=727 spamscore=0 adultscore=0 phishscore=0 mlxscore=0 malwarescore=0 lowpriorityscore=0 clxscore=1015 impostorscore=0 bulkscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2401310000 definitions=main-2402080023 On 2/8/2024 10:11 AM, Dmitry Baryshkov wrote: > On Thu, 8 Feb 2024 at 04:40, Krishna Kurapati PSSNV > wrote: >> On 2/6/2024 6:54 PM, Dmitry Baryshkov wrote: >>> On Tue, 6 Feb 2024 at 14:28, Krishna Kurapati PSSNV >>> wrote: >>>> >>>> >>>> >>>> On 2/6/2024 5:43 PM, Dmitry Baryshkov wrote: >>>>> On Tue, 6 Feb 2024 at 14:03, Krishna Kurapati wrote: >>>>>> >>>>>> Enable tertiary controller for SA8295P (based on SC8280XP). >>>>>> Add pinctrl support for usb ports to provide VBUS to connected peripherals. >>>>> >>>>> These are not just pinctrl entries. They hide VBUS regulators. Please >>>>> implement them properly as corresponding vbus regulators. >>>>> >>>> >>>> Hi Dmitry. Apologies, can you elaborate on your comment. I thought this >>>> implementation was fine as Konrad reviewed it in v13 [1]. I removed his >>>> RB tag as I made one change of dropping "_state" in labels. >>> >>> My comment is pretty simple: if I'm not mistaken, your DT doesn't >>> reflect your hardware design. >>> You have actual VBUS regulators driven by these GPIO pins. Is this correct? >>> If so, you should describe them properly in the device tree rather >>> than describing them just as USB host's pinctrl state. >>> >> >> Hi Dmitry, >> >> I have very little idea about the gpio controller regulators. I will >> go through it and see how I can implement it. I just found this : >> https://www.kernel.org/doc/Documentation/devicetree/bindings/regulator/gpio-regulator.txt > > Much simpler, it can be found at > Documentation/devicetree/bindings/regulator/fixed-regulator.yaml Thanks for the reference. > >> One query. If we model it as a regulator, do we need to add it as a >> supply and call regulator_enable in dwc3_qcom probe again ? > > Not in probe(), but yes. It needs to be enabled when the VBUS has to > be powered up, when the device is initialised or switched to the host > mode, and disabled when the VBUS has to be powered down, if the device > is being switched to the device mode. > Actually since we never go to device mode, can't we just stick to this pinctrl approach and skip turning on regulator in driver ? Regards, Krishna,