From patchwork Mon Oct 17 14:53:25 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 3569 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp1497426wrs; Mon, 17 Oct 2022 08:03:45 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5/YpO0QTe29nYB7Frwhz4kGqZIXkdMVyVBhr1BTKSl39HaC2nXZTNQUmb4rxLxD6s8PF/Q X-Received: by 2002:aa7:d651:0:b0:459:d1c:394e with SMTP id v17-20020aa7d651000000b004590d1c394emr10904309edr.10.1666019025487; Mon, 17 Oct 2022 08:03:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666019025; cv=none; d=google.com; s=arc-20160816; b=RZwGEqJVMWNtLTISAVFGt3pbBnZyQjaYeMS8Q6n7nXuUjg814HlCu02HUIM1/AXSsY 6avd69LewgzL3WWvilqt8yAljqcIAdKQ+orMwh2fwevrCsqybDMdOQLwT0k073FdDDMA OUhh+JU6910T1JDUv7ITCUPK5A4CJD0G8K4pqRQH5polR8r4x8xWT1hx5TeTAMjRT490 8lOWnMp4Y1pUQQXytFHqCYA0HYpC0YdhFxBYvBAXBN9WWuHXPvX3rPx618pz9qJRJ4xh R7RWQwFB65c5zwATNoniO39GIJCjNCMBKS/il8y2F36iipHrZlWoAdJmbn4jCBow6r/z g+Fg== 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=LX8dZctt+qduXfyEuo8piDFDhh8GYyJrZFyEpKbBYYE=; b=bnPWAcE7tQ0xNpGDFXoobjtP7COim6JDzLgoglncjlN+PVOQ+GP7LhZyns89b7pS9v ClKfJ+acLuQvwR8lMx8EtAPoe9sMbHhlqW2mRTv/puJQtfw5vmbk5B3+osDo5NJmsQnU kuWIKNXLWHPgSm+ZR8QQOcjuxduimcDsGT3UqXcGpydbMaM5aWq/ojRXzijLOSEzB/nS Od+2o3cyVEeSblox2R5NhXDD6XEtoEDZ3xifHEOHSUY471eIvmFF1m37giV00OIgXmQG 8lMw4ErU5pHScQfjctjFHyxI0Bfz+7JQ7F7iaaT86m9d5MFfkHcohhl1hYTfykrXfp1m ZBHg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=m1fqAVB4; 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=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d11-20020a170906370b00b007818378f560si7192301ejc.383.2022.10.17.08.02.56; Mon, 17 Oct 2022 08:03:45 -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=@kernel.org header.s=k20201202 header.b=m1fqAVB4; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231561AbiJQPCE (ORCPT + 99 others); Mon, 17 Oct 2022 11:02:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48418 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231334AbiJQPBq (ORCPT ); Mon, 17 Oct 2022 11:01:46 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0A1036292A; Mon, 17 Oct 2022 07:59:54 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 65328611C5; Mon, 17 Oct 2022 14:54:40 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 19F10C4FF15; Mon, 17 Oct 2022 14:54:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1666018479; bh=zIA+ml8wbUJ1pYtOiAw0rtWwlGesij42jZ74b5odlbA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=m1fqAVB4HQfkmNYpScXt6Ppg3atb5I/79VRYDcdqH63Lsl7aL3NTLhvf0LD9nGIdm 8d8zVzRxxo+39f2LqXdFJWN4RhhUoGr9uB0YpV795LwYYMFWQa1wwVZuxAnZs27Dmd tFQLZZ8StlDISMCxZZDGB44IirNOmkPeAL/7BrUc/qIpWEk+praY+Ih9k3uWxqD7iI ndrPPbzwcH4dMxgb73zqUlH4lpmv6dr5BtjE5sE54HWZMsLYEDuYwhvD7EV1taLJ6P nb03Vb9xwIY5kvx0dh9FbncoFyINbD9uDBRn9HJBlGvlT7Z5bdsJ6owk+TJ2+VJefX NdVmJ8MebVaFA== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1okRVd-0005mT-GC; Mon, 17 Oct 2022 16:54:29 +0200 From: Johan Hovold To: Vinod Koul Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Dmitry Baryshkov , linux-arm-msm@vger.kernel.org, linux-phy@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 12/15] phy: qcom-qmp-pcie: fix initialisation reset Date: Mon, 17 Oct 2022 16:53:25 +0200 Message-Id: <20221017145328.22090-13-johan+linaro@kernel.org> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20221017145328.22090-1-johan+linaro@kernel.org> References: <20221017145328.22090-1-johan+linaro@kernel.org> MIME-Version: 1.0 X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1746947566001960994?= X-GMAIL-MSGID: =?utf-8?q?1746947566001960994?= Add the missing delay after asserting reset. This is specifically needed for the reset to have any effect on SC8280XP. The vendor driver uses a 1 ms delay, but that seems a bit excessive. Instead use a 200 us delay which appears to be more than enough and also matches the UFS reset delay added by commit 870b1279c7a0 ("scsi: ufs-qcom: Add reset control support for host controller"). Signed-off-by: Johan Hovold --- drivers/phy/qualcomm/phy-qcom-qmp-pcie.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c index 2f4bdef73395..9c8e009033f1 100644 --- a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c +++ b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c @@ -1866,6 +1866,8 @@ static int qmp_pcie_init(struct phy *phy) goto err_disable_regulators; } + usleep_range(200, 300); + ret = reset_control_bulk_deassert(cfg->num_resets, qmp->resets); if (ret) { dev_err(qmp->dev, "reset deassert failed\n");