From mboxrd@z Thu Jan 1 00:00:00 1970 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 2CA91418357 for ; Mon, 10 Aug 2026 15:42:20 +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=1786376544; cv=none; b=K0KHgyQdmPS+tIstGRXva/GBtNUUA6RbfQhl1EuH6mGtgZqVggAJjabwOCAMeLt7/CiLk7moL+pa4aD4EVDiRA/2773jYXzmJ0y+sZm5MyHdE1b4q8ZSzYQejecROqVkkaY/J48nvdh0bRoqSdyOOWeqgmQNkRr44bgJTcDU6hY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786376544; c=relaxed/simple; bh=0CI3mvu26e7yA8lXB+SGW6FHaZ290+w5/6/G0cJEMAA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=bl3taQ8t5wOMB32qmBtuJa11lrRZlHM38+k2Mvd+k0V2mqm4frUXY0ZKSWOe1rnXsYcH4I85nTRxu90Cnjfhr+8DLq65YV0taOqs3DnWGo6WDtVBrlAAaDK7xPhY4FWambV5kSyZMU3tuN/h7oZ5jMy/q0t5v8aWc8tbLdbe8pE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=ZcV9Mp7S; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=g2139EzV; arc=none smtp.client-ip=205.220.180.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="ZcV9Mp7S"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="g2139EzV" Received: from pps.filterd (m0279871.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 67AFWecZ2345308 for ; Mon, 10 Aug 2026 15:42:20 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= Wb7qvpUp/pGm2ninxxAE+oyyMl7XsWm9X5sYC8bZaf8=; b=ZcV9Mp7SANLg3D5T PWLMytl00vS/dew4AbD067kvdt36FpqHJ6AjCy7ZFwOHr9kt137MO3GgFXgScuoW nM3pAZXnEDUjIaql7nTSuDyMD7/PjTIx2pOpxGUcMl4NEU8sOqWls+XAEr65C7Y8 XaQJpLZpa+y35XROU+5SZCpYp/mEx9h415znrRBtb3YGcnixmxYVnlKoDf7Hvo1v GsXXJ8+sqkS2oE+CYGn8J916dKe0t3XNL3mPJ8WxOhG4CTJFc9H13jIL4qiJhGA0 lv/LSw1yCmWc/n5gEODXbb7NEUvjXCDJhtqXZ71Ur1F3xXNnKBI/CSBOvmjQUuMP eG3k2Q== Received: from mail-qt1-f199.google.com (mail-qt1-f199.google.com [209.85.160.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4fy18xubwd-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Mon, 10 Aug 2026 15:42:19 +0000 (GMT) Received: by mail-qt1-f199.google.com with SMTP id d75a77b69052e-51c0e702df8so28584731cf.2 for ; Mon, 10 Aug 2026 08:42:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1786376539; x=1786981339; darn=vger.kernel.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=Wb7qvpUp/pGm2ninxxAE+oyyMl7XsWm9X5sYC8bZaf8=; b=g2139EzVk4c+Dh9HKQTF78EbgMDgEkt3njcuBnUnLR0kKjxLAMrS9QCNvbrSeybY5n moJKNJ84f63g+g203h8CT4ArS+WhlmRhBtQ2a9qVdVOjapRUzQr3wSPNoXdUgC2VX9bM woIzDLt+/WAHdpS066nUEfmFsmAn8XLetZScA9rf9WskgFDdvMHL68yLahpVh/1M8Mp1 I5tyiPagsqEkCQaA1wMs/ZnNrJh6hIrJzHMdxRh58fxW8i6D5zeLSmv1nV0ExiPUgBfb b6X0q2IVKE9SYWPi6iUJX4N8AcKw5ZbGuU36sg2kigrbQRE2yVvcqv4PU1tmeZNEi8YW zuvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786376539; x=1786981339; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :content-type:mime-version:subject:date:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=Wb7qvpUp/pGm2ninxxAE+oyyMl7XsWm9X5sYC8bZaf8=; b=pf02PSnakNnFVUiqRkMyLD61pSpfWhQnpaTPjgCkGxxq1VnyTjvmMsxSzcBJaF2Mgf ZiyyF6Nj3uh5lHWe9gL/HHTXzMzP6TI0SuIJ6PbWjBGetXXWVsvk0cxmw/FQfZCfpPlT eOH+++kGcq6eFhoJWIiR1EsEpF8b86Q1PywYJCUglmUU5z5ojE0HmzIZYB+Owlj0f++B CMTiPWVqi6w9fWiMqfRbVwi8bZScFojtEI6yRH3a+JWZLGTtqGh2Pw6zfGf0OX79IgJo aKRLO/EjQWmqaPSxXXwoAOqNtQsqsfYDLQA2/4Zw0vH84nvDAHjziAKe6SxziJuzSAL9 KKJw== X-Forwarded-Encrypted: i=1; AHgh+RrqvSOIMOKtXwlgfF4peXqldUCxHrWNybU8sRn3HxtgWIX31SR1eIM0G+O5N7OqV3wCYO/G+gSAUSjbSK4=@vger.kernel.org X-Gm-Message-State: AOJu0YxKjRHIkVDzuQVoE1DrDJcCZgsWm941UHchGpdPBmY46Q+9oUtV BMWY0i0xtT0Ers9aPkxiRue4goDRl5K3yhfA5TLQwX8XuR2jMbncdpcdBDNkqRzOZ3uGAplOX2B A+VJRzdQifh+jd76RQU5nl/mzxt3/m6QHkqHEGJQK09j7hr3cXLhb/qvZMehc18WQNmc= X-Gm-Gg: AR+sD13eb9ssStoFQhrjJYz/CgDIZrW+hNn0YiG5j/8lFEb5TgSlhouuQkX1SPun+E9 cSpzsjjiNImRubHfA6IPZJVL7G4ssDBwY++I+m/D5vCXPjieQrJ7DONffd008LV1UhaLAizWzgz 5A+0HcCJu6MNJ6qZPFuAXRDLQon024CtfQ+3LXqmvRm4XMJU/x7J8IhGpnoUMh4oedNeO10KJt9 HpTfO0HhXdQGytwp9A+D8by74G3QfEzVr8NfNFNEoVM08PXoykApMQhffgPI2Oz+KCBJno9wXWH qAWj4HbUFtuWWs09OVJ/rSB0w8L7DQoWeu26EIUyZZWna6T6h8vrT9ODdUVdINEhXpm6i+yeqQJ CFZ61q2AqAbG5XFFnzJV2q7BEml1OCs8HP6WtVvFy9OMsnv5D2xfpYEGwHpHZO6Qpf4oUIHNvRT N8sH4HO43bGhHJZg== X-Received: by 2002:a05:622a:c8c:b0:51c:19af:6341 with SMTP id d75a77b69052e-52ce61d2d25mr497522941cf.36.1786376538891; Mon, 10 Aug 2026 08:42:18 -0700 (PDT) X-Received: by 2002:a05:622a:c8c:b0:51c:19af:6341 with SMTP id d75a77b69052e-52ce61d2d25mr497521651cf.36.1786376538133; Mon, 10 Aug 2026 08:42:18 -0700 (PDT) Received: from umbar.lan (2001-14ba-a073-af00-264b-feff-fe8b-be8a.rev.dnainternet.fi. [2001:14ba:a073:af00:264b:feff:fe8b:be8a]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-5b3056f1bbdsm2071673e87.82.2026.08.10.08.42.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Aug 2026 08:42:16 -0700 (PDT) From: Dmitry Baryshkov Date: Mon, 10 Aug 2026 18:42:07 +0300 Subject: [PATCH 03/10] phy: qcom-usb-hsic: do not run the sleep calibration clock 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: <20260810-msm8974-usb-hsic-v1-3-e5f93ea76ffa@oss.qualcomm.com> References: <20260810-msm8974-usb-hsic-v1-0-e5f93ea76ffa@oss.qualcomm.com> In-Reply-To: <20260810-msm8974-usb-hsic-v1-0-e5f93ea76ffa@oss.qualcomm.com> To: Bartosz Golaszewski , Bjorn Andersson , Linus Walleij , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Greg Kroah-Hartman , Xu Yang , Peng Fan , Vinod Koul , Neil Armstrong , Peter Chen , Pavankumar Kondeti , Stephen Boyd , Konrad Dybcio Cc: Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-gpio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org, linux-phy@lists.infradead.org, Greg Kroah-Hartman , Peter Chen X-Mailer: b4 0.15.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=3001; i=dmitry.baryshkov@oss.qualcomm.com; h=from:subject:message-id; bh=0CI3mvu26e7yA8lXB+SGW6FHaZ290+w5/6/G0cJEMAA=; b=owEBbQGS/pANAwAKAYs8ij4CKSjVAcsmYgBqefFQE6VzvzxQPylH9ol+I79Tpmlw5MGkv8b25 1iWSPmFw6CJATMEAAEKAB0WIQRMcISVXLJjVvC4lX+LPIo+Aiko1QUCannxUAAKCRCLPIo+Aiko 1XrJB/4k7QGxbIKLgD8fuU+VZfJP2y/wpC+a0n4C6NJVVqJBicGgCy3AQ8RQPMNajILbjcTmnxs 42Um3fhKY+5SXieGB3CFYJEOjlA79/KNfLs3M9M8Tqy/OVFOG3m1xDW7BCK7urRoWIVBu7kSbYn 4QlCcu4hYZ4rVVDHGgBhXtsV3Ke4vXH0fpEWTn3rvqTf7hU5BbwX4Wu7MMhp5R70vbXirrZcjXv nI3gVSk18M6Zo27KaVZOf8A19KNnRvRSq++A9OuCeo6MhNWEK7/46RwMvafaMZdu1utqdf24XCk XI0jmDgzo5lFr620llmYyMLV77/QUORAmmowPAq9SCJ394y0 X-Developer-Key: i=dmitry.baryshkov@oss.qualcomm.com; a=openpgp; fpr=8F88381DD5C873E4AE487DA5199BF1243632046A X-Proofpoint-Spam-Info: AW1haW4tMjYwODEwMDEzNSBTYWx0ZWRfX3jwi+CQ2lz5O UkcK4E0lEeVf2OfK5khf3kmdxkNkJDH8zx48EQnt7YTiTZA0IuIVhj2uCIkp8TW4ZtdGX4Jz5n7 u0gzrq7+oqGtyom3mpjI4yRrwr/2qPM= X-Proofpoint-ORIG-GUID: gEEBeriwHnve_NumDdk0zJWTABrYJT9V X-Proofpoint-GUID: gEEBeriwHnve_NumDdk0zJWTABrYJT9V X-Authority-Analysis: v=2.4 cv=bfZbluPB c=1 sm=1 tr=0 ts=6a79f15b cx=c_pps a=WeENfcodrlLV9YRTxbY/uA==:117 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=Sv0fKeRqtYgA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=3WHJM1ZQz_JShphwDgj5:22 a=EUspDBNiAAAA:8 a=h5QO6Q66eTtlMCYmI04A:9 a=QEXdDO2ut3YA:10 a=kacYvNCVWA4VmyqE58fU:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwODEwMDEzNSBTYWx0ZWRfX/FnJ2U9Xivlw IFiJW7uJ0MHFAvonFNKfBAeB6fj6lgZ0XNMpTu1Zo1wbFJNSJpTuLn71To3LEvTl35h9fz6qJvp MvonFRlmDU1T9x1qEtipkB7Vh3FaBFG2fTsdM0dWmeoo7htu3pqKZSlaTVTMTF5X0ZUe5S385Fe pV/2DNnHJE56IKgjWaJZEcod0TcdvU8kSBcMYaa7oO+AMEFMaMSmyJYFeR4DKNoDUwBeYKA7gxb MxcbZEHbbuYuE50Spgr16M0lFCYKhUYMPBAQX3LC/WwJOk/8KywwTEDJkH2YuqT89Sa28X5ODfa vPpIFtWoz10tiYB/Nl5AKBhI5k73yUH3xNo62737JTtUcFFvCXN8yBm5EAhd9pfMfA969EO104B /cDh5LepW8XpPhytCdkYF3ovP40nccp8P0t9d5jtkLMo/TxRSQTByj3KudKIAP3HAx4uzAxHVPt 6z8BMAk8NdId2Vj8I0g== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1176,Hydra:6.1.134,FMLib:17.12.100.49 definitions=2026-08-10_03,2026-08-10_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 impostorscore=0 spamscore=0 lowpriorityscore=0 malwarescore=0 clxscore=1015 priorityscore=1501 phishscore=0 bulkscore=0 suspectscore=0 adultscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2608100135 With the cal_sleep (32 kHz IO calibration sleep) clock running, the HSIC PHY engages its sleep calibration: the strobe/data pad calibration converges to different values than with the active calibration alone, HSIC_CFG reports the sleep calibration state, and the port no longer detects a device connect - an onboard HSIC hub signalling its attach after reset is never seen (observed on the APQ8074 Dragonboard against its USB4604 hub, by comparing the ULPI register state against the vendor kernel, which never enables this clock: with cal_sleep enabled ULPI HSIC_CFG reads 0xab and the pad registers 0x0f/0x0d, without it 0xa9 and 0x10/0x10, matching the working vendor configuration). Stop requesting and enabling the cal_sleep clock. Assisted-by: Claude:claude-fable-5 Signed-off-by: Dmitry Baryshkov --- drivers/phy/qualcomm/phy-qcom-usb-hsic.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) diff --git a/drivers/phy/qualcomm/phy-qcom-usb-hsic.c b/drivers/phy/qualcomm/phy-qcom-usb-hsic.c index 20f6dd37c7c1..b670ec364a2d 100644 --- a/drivers/phy/qualcomm/phy-qcom-usb-hsic.c +++ b/drivers/phy/qualcomm/phy-qcom-usb-hsic.c @@ -20,7 +20,6 @@ struct qcom_usb_hsic_phy { struct pinctrl *pctl; struct clk *phy_clk; struct clk *cal_clk; - struct clk *cal_sleep_clk; }; static int qcom_usb_hsic_phy_power_on(struct phy *phy) @@ -38,9 +37,13 @@ static int qcom_usb_hsic_phy_power_on(struct phy *phy) if (ret) goto err_cal; - ret = clk_prepare_enable(uphy->cal_sleep_clk); - if (ret) - goto err_sleep; + /* + * The sleep calibration clock must not run: with it enabled the PHY + * engages sleep calibration (the strobe/data pad calibration + * converges to different values and HSIC_CFG reports the sleep + * calibration state), and the port does not detect a device connect. + * The vendor driver never enables this clock. + */ /* Set periodic calibration interval to ~2.048sec in HSIC_IO_CAL_REG */ ret = ulpi_write(ulpi, ULPI_HSIC_IO_CAL, 0xff); @@ -76,8 +79,6 @@ static int qcom_usb_hsic_phy_power_on(struct phy *phy) return ret; err_ulpi: - clk_disable_unprepare(uphy->cal_sleep_clk); -err_sleep: clk_disable_unprepare(uphy->cal_clk); err_cal: clk_disable_unprepare(uphy->phy_clk); @@ -88,7 +89,6 @@ static int qcom_usb_hsic_phy_power_off(struct phy *phy) { struct qcom_usb_hsic_phy *uphy = phy_get_drvdata(phy); - clk_disable_unprepare(uphy->cal_sleep_clk); clk_disable_unprepare(uphy->cal_clk); clk_disable_unprepare(uphy->phy_clk); @@ -125,10 +125,6 @@ static int qcom_usb_hsic_phy_probe(struct ulpi *ulpi) if (IS_ERR(clk)) return PTR_ERR(clk); - uphy->cal_sleep_clk = clk = devm_clk_get(&ulpi->dev, "cal_sleep"); - if (IS_ERR(clk)) - return PTR_ERR(clk); - uphy->phy = devm_phy_create(&ulpi->dev, ulpi->dev.of_node, &qcom_usb_hsic_phy_ops); if (IS_ERR(uphy->phy)) -- 2.47.3