Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp2292311pxm; Thu, 24 Feb 2022 22:00:35 -0800 (PST) X-Google-Smtp-Source: ABdhPJw9MvL1i78T5umpIeSSvbSC2c6vCkO6wvRBDLEpfm8PdOANui0PP+x2/8dHt5A4IZy8XGpw X-Received: by 2002:a17:902:a981:b0:14f:d384:73c6 with SMTP id bh1-20020a170902a98100b0014fd38473c6mr6314243plb.148.1645768835259; Thu, 24 Feb 2022 22:00:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645768835; cv=none; d=google.com; s=arc-20160816; b=jRSFmcjY8qWTlYRGuZL+4KyQyVP0FA14bwp0NZByfLbjklqkMvuqglKXjWYfJc0zLr +4RHI4/3tpPxhHjurrSTmZCOIKl97CFYpNy9S9LBrCql7bkYPLZGD+UhzC0YLbOS8V0Y A7lFE0GJeoA97LqRQe/VjkENIO9lAlF08gYQoXG7gCUZnVqAltw0YJl7dchi1tQkzJki RrZdr/RLPvEW8Ury3jc5GoujgE6COQ0DwWV2p1h2DRuPYfnCS2Wf3BLRYImeagluuWph s3uugbSp5ngByxaqdVNfdUm7DTVBqxzv2KF8bHExRe6t1Up45jtTYI8OsHVIZhZdn/cf iyCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=oJp8hP+U6of0fVJudV+JnYfYQm2OqbcYZL17Ud0j5hM=; b=kkrJa7GI4mPhirn7435MtFKmzbyaA2vCecemQUGX6BDmGOG0YtdZvTpQ1DRo0DytGS cggawqAY4OXFinfs0UE/7CUlqWbpXQC6AXZh5lxRHEOCamuDqRgsaOkwjxZdz8uWsu9z +g+hyJsCppzp/HaboJMUS89Gz0jv20TBQ/u84HCRZryCEYqsVhY2cWg08L5fO7CbVvEZ NBp+H9k+M3bN7fP42AE8VK5b81cthmu+S0CkzOg+5bypZQjNSwGT0NIaEpzRKf4+kt5V iUccZFREg9+2LFShZMQmUKp1tEP9IbhdDhpYyOVNFLdoxm2/0NSj9eQFSyyo3TNvY8Pg UwXg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=K14qvOAD; 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=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i3-20020a655b83000000b00373a91a274asi1059281pgr.782.2022.02.24.22.00.18; Thu, 24 Feb 2022 22:00:35 -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=@linaro.org header.s=google header.b=K14qvOAD; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237073AbiBYDj0 (ORCPT + 99 others); Thu, 24 Feb 2022 22:39:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57300 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237045AbiBYDjY (ORCPT ); Thu, 24 Feb 2022 22:39:24 -0500 Received: from mail-oi1-x231.google.com (mail-oi1-x231.google.com [IPv6:2607:f8b0:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8FAF617B0D0 for ; Thu, 24 Feb 2022 19:38:53 -0800 (PST) Received: by mail-oi1-x231.google.com with SMTP id y7so6078509oih.5 for ; Thu, 24 Feb 2022 19:38:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=oJp8hP+U6of0fVJudV+JnYfYQm2OqbcYZL17Ud0j5hM=; b=K14qvOADAvKamyct36KBBctciQ880Q/jd9swL7Wwln6RN3gLFMm+v2gtAuf9BGVPB4 WhCU6t9gKeInxiNFTAEkp5Lk37mjZEQ20ZNl+e6/BRMk5NN2119tSvlkrfL47iSHOQp2 g7KtWVz6LGOzmxM6Y9CYQtR6ef1D/l/Ni/YpDWLFZtPMMCd+TjIGy9Z51f+JWDURBXh3 lI8mokaP3KDuA+Dbv/2forWLn/1If7RLE7tl8EAuVP8qk+aNUgdwIC+MhN54BL0FisAg a91LVNQC0DyaFqtIwZth1CHP0dHqX7DMnfzmIIDP7ZNXeQGKsDXtJOrl084h2gqaZ+U4 6cgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=oJp8hP+U6of0fVJudV+JnYfYQm2OqbcYZL17Ud0j5hM=; b=pB/3wxHmFHmSQ7SamARKNzFbl7DJZktpgp0MKHnSer3Yf9N1ke9DEqAC9lp+F+eD+X NKLe10FA9qQpB6c3nvdo2N6T9SHsANpjLx+gF5Syr5+7ZmgLu/7ZXpIQ6feRk+Jls45Q BAY89+6J2CniYouHdnvUqAsV3gOw7H3MonJ2Cnp3THiDTgGCF/hEBiOrBBNI2dDao+Cy DvRNP8h0Ginw/lwcZF4K6Qmw9WRyMRMDdpG4Joc/B0FA6c8RtUWlu5Vq86/PcKbxixFQ dUpeUEAHaLJaK11TPlMGBdxSmrxYIcPagAuMn8Sy+SnAnlCcWmkb4tdrwxnwDoXgTBc4 mj6A== X-Gm-Message-State: AOAM532IggiSxe5cwnxHiTIA+POrOooTk5bAOYDcQBVh67+cpHXvsfi9 Pc8r1k4jQVtx7FbTf+JPTOtgq6HvpopRsQ== X-Received: by 2002:aca:3e56:0:b0:2d4:c902:b851 with SMTP id l83-20020aca3e56000000b002d4c902b851mr627205oia.114.1645760332736; Thu, 24 Feb 2022 19:38:52 -0800 (PST) Received: from ripper.. ([2600:1700:a0:3dc8:205:1bff:fec0:b9b3]) by smtp.gmail.com with ESMTPSA id fq14-20020a0568710b0e00b000d4492531a2sm809359oab.17.2022.02.24.19.38.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Feb 2022 19:38:52 -0800 (PST) From: Bjorn Andersson To: Kishon Vijay Abraham I , Vinod Koul , Wesley Cheng Cc: Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/2] phy: qcom-snps: Add sc8280xp support Date: Thu, 24 Feb 2022 19:40:49 -0800 Message-Id: <20220225034049.2294207-2-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.33.1 In-Reply-To: <20220225034049.2294207-1-bjorn.andersson@linaro.org> References: <20220225034049.2294207-1-bjorn.andersson@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 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,T_SCC_BODY_TEXT_LINE autolearn=unavailable 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 The Qualcomm sc8280xp platform comes with a 5nm femto USB PHY which, in contrast to previously seen platforms, has the SIDDQ bit in the COMMON0 register default to high. So make the driver match on the 5nm compatible and make sure to clear the SIDDQ bit on phy_init. Signed-off-by: Bjorn Andersson --- drivers/phy/qualcomm/phy-qcom-snps-femto-v2.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/phy/qualcomm/phy-qcom-snps-femto-v2.c b/drivers/phy/qualcomm/phy-qcom-snps-femto-v2.c index 7e61202aa234..5d203784f75d 100644 --- a/drivers/phy/qualcomm/phy-qcom-snps-femto-v2.c +++ b/drivers/phy/qualcomm/phy-qcom-snps-femto-v2.c @@ -32,6 +32,7 @@ #define POR BIT(1) #define USB2_PHY_USB_PHY_HS_PHY_CTRL_COMMON0 (0x54) +#define SIDDQ BIT(2) #define RETENABLEN BIT(3) #define FSEL_MASK GENMASK(6, 4) #define FSEL_DEFAULT (0x3 << 4) @@ -233,6 +234,9 @@ static int qcom_snps_hsphy_init(struct phy *phy) qcom_snps_hsphy_write_mask(hsphy->base, USB2_PHY_USB_PHY_UTMI_CTRL0, SLEEPM, SLEEPM); + qcom_snps_hsphy_write_mask(hsphy->base, USB2_PHY_USB_PHY_HS_PHY_CTRL_COMMON0, + SIDDQ, 0); + qcom_snps_hsphy_write_mask(hsphy->base, USB2_PHY_USB_PHY_UTMI_CTRL5, POR, 0); @@ -275,6 +279,7 @@ static const struct phy_ops qcom_snps_hsphy_gen_ops = { static const struct of_device_id qcom_snps_hsphy_of_match_table[] = { { .compatible = "qcom,sm8150-usb-hs-phy", }, + { .compatible = "qcom,usb-snps-hs-5nm-phy", }, { .compatible = "qcom,usb-snps-hs-7nm-phy", }, { .compatible = "qcom,usb-snps-femto-v2-phy", }, { } -- 2.33.1