Received: by 2002:a05:7412:798b:b0:fc:a2b0:25d7 with SMTP id fb11csp15474rdb; Wed, 21 Feb 2024 15:20:13 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWBioS5UDdfUb4GAlRhDibQqZd5ErnvR5bfrRn4vVRXexfmYaB9KfLFNL6tDeJ4o1MVjIiyRFLSPHVT1WCHKATTZvmCPvRYgC1GDa+jAA== X-Google-Smtp-Source: AGHT+IHNnrB6WiXKCvteYEBxTz3jG8f8T7w0gtk6EnkQ3DKBEPm4WKQBfa+d+SBY/5OQL6z8fCm4 X-Received: by 2002:a17:906:1197:b0:a3e:3f42:11a1 with SMTP id n23-20020a170906119700b00a3e3f4211a1mr8305129eja.66.1708557613298; Wed, 21 Feb 2024 15:20:13 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708557613; cv=pass; d=google.com; s=arc-20160816; b=Hl2IocLelgTLz0aQEjSg5XSusCmiAO2W3Xj6xJ1zxK2fmKxACvklP7ZRWYttKMGzxa 1/rEpHL8TkC4sn/yATnA0JtV9ex9S0qZrNkhGFeQAA9AdUqwtL0KpK/O4zpG9H6u/OzR 8NKYY4ImuQRAKUrJaUnes1imeJdThlEePFwRtrWmm2RhqdCfldxc11XBDHduAKL/vtIx hjJMzNCpqlAEY2Mes9jOxbcDmWI8WuGbK0S+cDLF27xylTBzfo+Ma5ASV0PWEApyXoSb lVHRPhFBW3wSpk9H85ivQScw+YCHBW7X0ZycrcmtqGsh2U6xktu9+3RmB9m5uxvSln7V wydA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=AsnLIr8iyvoWi/SAEE30XrVqBQSBhBflVgnCniYLN+w=; fh=Ph3D4iPhMs0qfrBSt7uGZnxnp3Fv4RZ3r2ELq4z6NQk=; b=Xqqh3km3xYdWsryPMq9gfmHo3LsEcFLyuAoiHnq1cd2154UAGElnVO7Q3Mcb+cSd2c 3vSwZ58S8bgXRtR+IZffigXAtMkhew0H2eRFpqv0tpmXnMpIKvxfXpdar1dSLMVPfU2I VIv1cP0Gc0EBvLDXFlCtYTod7ZjSxyh9X4+TDE6uF63G9aqtNkliOBDMGGEGJ7BU959V lTf/wDaeFa9lZM0Vqk/hG+eZ9XOXvv8FhTYQ5nEsztrS22LF6OCu+nGLJmEOjvhDqrep crEqPV8YhYscH/Yh7CYh/Q/3V5JwmUP3dHg8iAM8ZvGIC8IN0/tkofI5dGVFT89YvqTV h4VA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=E4izZVFh; 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-75641-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-75641-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=quicinc.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id ka9-20020a170907990900b00a3f04b342d2si1683606ejc.224.2024.02.21.15.20.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Feb 2024 15:20:13 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-75641-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@quicinc.com header.s=qcppdkim1 header.b=E4izZVFh; 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-75641-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-75641-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 am.mirrors.kernel.org (Postfix) with ESMTPS id DC04A1F23B5C for ; Wed, 21 Feb 2024 23:20:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 765C412D76A; Wed, 21 Feb 2024 23:19:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=quicinc.com header.i=@quicinc.com header.b="E4izZVFh" Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.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 D56B13B2B6; Wed, 21 Feb 2024 23:19:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708557568; cv=none; b=dRFSoQf22ohuHl2VX1D9Szt//NurpJcO71aaGgJ/Too3Lm8PMjziWWXMDIxdQAZetfGhVKZaMrPFFLfQsGSlSmep4b+A+f5gVCPZcJ+KUzplffg5A1WeH5XVyw4WovFARiiRNNf6J1KbFmKU54OtmnQhh/7I97WavPVxt88ev7w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708557568; c=relaxed/simple; bh=jFVnUQDGDiwZHsd8qnGF9m4i8GwDQv+12K/5p4xdozs=; h=From:Date:Subject:MIME-Version:Content-Type:Message-ID:References: In-Reply-To:To:CC; b=lBS3/6K5BXWZ1RSkrK+zAuakpkgka8C2nMgBsmRH7zlZs/HlzhdZ3w90ROcGgu52/9C23frb/p46Am8mFiXjUzVnqteh5PJN31MqJJUko+1fAqLzOSUL8U6CMHxHacXXXJUMYey9gLcm1Sp0aF/5hshq0z63GEKbvgnwmyfDdMU= 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=E4izZVFh; arc=none smtp.client-ip=205.220.168.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 (m0279863.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.17.1.24/8.17.1.24) with ESMTP id 41LJKGob012434; Wed, 21 Feb 2024 23:19:16 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=quicinc.com; h= from:date:subject:mime-version:content-type :content-transfer-encoding:message-id:references:in-reply-to:to :cc; s=qcppdkim1; bh=AsnLIr8iyvoWi/SAEE30XrVqBQSBhBflVgnCniYLN+w =; b=E4izZVFhXYb3ndhnqoQ5eB5ta0dOdzBh56SQ30sTN4vf1Ui0v/Mty2wNZwv 9MQxSV63a3gcqzdcgA5Z3ZmzcQ/Y0U+XP1/kydV7kt8HnB6F/nSGjIP/Drehpf1t IRICKtM2rthPLbwRTe3N+iE1t8O2ymRgBJVpnZfWIeF5kPdFn+smnf32aTdLT8E8 WtUArMxV837k551TRiebukxe0uxN9Avk9PCB+7QJ+Ee2wb2KzuLAzsBILK5sCTU0 vmiTpcvh33lagdeVpzL8g/n2FsOKGdavD/Pj85LsRSJYKtV3E3O+qKAxqrMnQJDi PsuMQdASqa7BBTnac4YsZUPqWwQ== Received: from nalasppmta04.qualcomm.com (Global_NAT1.qualcomm.com [129.46.96.20]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 3wdpjn8hcw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 21 Feb 2024 23:19:16 +0000 (GMT) Received: from nalasex01c.na.qualcomm.com (nalasex01c.na.qualcomm.com [10.47.97.35]) by NALASPPMTA04.qualcomm.com (8.17.1.5/8.17.1.5) with ESMTPS id 41LNJFXw028462 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 21 Feb 2024 23:19:15 GMT Received: from [169.254.0.1] (10.49.16.6) by nalasex01c.na.qualcomm.com (10.47.97.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1118.40; Wed, 21 Feb 2024 15:19:15 -0800 From: Bjorn Andersson Date: Wed, 21 Feb 2024 15:19:14 -0800 Subject: [PATCH 6/9] arm64: dts: qcom: qcs6490-rb3gen2: Enable USB role switching Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-ID: <20240221-rb3gen2-dp-connector-v1-6-dc0964ef7d96@quicinc.com> References: <20240221-rb3gen2-dp-connector-v1-0-dc0964ef7d96@quicinc.com> In-Reply-To: <20240221-rb3gen2-dp-connector-v1-0-dc0964ef7d96@quicinc.com> To: Rob Clark , Abhinav Kumar , Dmitry Baryshkov , Sean Paul , Marijn Suijten , David Airlie , Daniel Vetter , , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Conor Dooley CC: , , , , , Bjorn Andersson X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=ed25519-sha256; t=1708557553; l=1847; i=quic_bjorande@quicinc.com; s=20230915; h=from:subject:message-id; bh=jFVnUQDGDiwZHsd8qnGF9m4i8GwDQv+12K/5p4xdozs=; b=L40shD0be2d1s//zwx8G4lUYqbZXpDEtZjSl4CMbjnLZ3HXaOCTtGNr3lHMKY9Y1W4HNFCHON mJfsYk8SJK1CGD7b3MDkn1408DE6b3XZvpzbDE+4SzxclpODHVuK3Sm X-Developer-Key: i=quic_bjorande@quicinc.com; a=ed25519; pk=VkhObtljigy9k0ZUIE1Mvr0Y+E1dgBEH9WoLQnUtbIM= X-ClientProxiedBy: nalasex01c.na.qualcomm.com (10.47.97.35) To nalasex01c.na.qualcomm.com (10.47.97.35) X-QCInternal: smtphost X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=5800 signatures=585085 X-Proofpoint-ORIG-GUID: xQTB72I01Lw_2Ygww6wg-xQygk22DqFn X-Proofpoint-GUID: xQTB72I01Lw_2Ygww6wg-xQygk22DqFn 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-21_09,2024-02-21_02,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 phishscore=0 suspectscore=0 spamscore=0 priorityscore=1501 impostorscore=0 lowpriorityscore=0 clxscore=1015 bulkscore=0 mlxlogscore=947 malwarescore=0 adultscore=0 mlxscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.19.0-2402120000 definitions=main-2402210184 With the ADSP remoteproc loaded pmic_glink can be introduced and wired up to provide role and orientation switching signals. Signed-off-by: Bjorn Andersson --- arch/arm64/boot/dts/qcom/qcs6490-rb3gen2.dts | 48 +++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/qcs6490-rb3gen2.dts b/arch/arm64/boot/dts/qcom/qcs6490-rb3gen2.dts index ab498494caea..079bf43b14cc 100644 --- a/arch/arm64/boot/dts/qcom/qcs6490-rb3gen2.dts +++ b/arch/arm64/boot/dts/qcom/qcs6490-rb3gen2.dts @@ -121,6 +121,41 @@ debug_vm_mem: debug-vm@d0600000 { }; }; + pmic-glink { + compatible = "qcom,qcm6490-pmic-glink", "qcom,pmic-glink"; + + #address-cells = <1>; + #size-cells = <0>; + + connector@0 { + compatible = "usb-c-connector"; + reg = <0>; + power-role = "dual"; + data-role = "dual"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + + pmic_glink_hs_in: endpoint { + remote-endpoint = <&usb_1_dwc3_hs>; + }; + }; + + port@1 { + reg = <1>; + + pmic_glink_ss_in: endpoint { + remote-endpoint = <&usb_1_dwc3_ss>; + }; + }; + }; + }; + }; + vph_pwr: vph-pwr-regulator { compatible = "regulator-fixed"; regulator-name = "vph_pwr"; @@ -476,7 +511,16 @@ &usb_1 { }; &usb_1_dwc3 { - dr_mode = "peripheral"; + dr_mode = "otg"; + usb-role-switch; +}; + +&usb_1_dwc3_hs { + remote-endpoint = <&pmic_glink_hs_in>; +}; + +&usb_1_dwc3_ss { + remote-endpoint = <&pmic_glink_ss_in>; }; &usb_1_hsphy { @@ -491,6 +535,8 @@ &usb_1_qmpphy { vdda-phy-supply = <&vreg_l6b_1p2>; vdda-pll-supply = <&vreg_l1b_0p912>; + orientation-switch; + status = "okay"; }; -- 2.25.1