From patchwork Mon Jun 7 01:30:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Jeffery X-Patchwork-Id: 12302397 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4C755C4743E for ; Mon, 7 Jun 2021 01:34:44 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0A49560FDB for ; Mon, 7 Jun 2021 01:34:44 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0A49560FDB Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=aj.id.au Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=kpSpOvbZNEpYvsm3mNxGiCOsKE3/uLxVxWdU/z8DnZg=; b=J2xQSJ5U9Af5T1 cCFzBhJ3FqvGyNjVu6i1con98BBjM8/Rd/p+0LwoD7lRou/j9HGFB2xDm796J+Brp0yXbUEedkGTS DSHlSRrFPqEBrWpIGb5nQiGCF6JksaD0H7ZsaHVvvWY5+ESvmKyJe01vu2dbyf8WGEd9qF1lsYKBh GD0ky8pUlXG/OVgEboIAZ9WUuAM7iRQHsFpC60Qp4RNWvNnTUAw23dOmzMYEQ/p9yCx/mPHUv+INc bgOXZSYU30CsU83rede0VwVMDfK85DoMjy2FtELI2leg4OcChF0G0Dz5Ieh3EHCNuto8nGvbzgpgd 43ayrOq98prc3lsMnwVw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1lq46N-001C2v-1J; Mon, 07 Jun 2021 01:30:51 +0000 Received: from out4-smtp.messagingengine.com ([66.111.4.28]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1lq46I-001C2I-M6 for linux-arm-kernel@lists.infradead.org; Mon, 07 Jun 2021 01:30:48 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 900305C00E6; Sun, 6 Jun 2021 21:30:44 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Sun, 06 Jun 2021 21:30:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aj.id.au; h=from :to:cc:subject:date:message-id:mime-version :content-transfer-encoding; s=fm3; bh=GRzcE4hI5AG2i78thbcMf/cB97 dZ01L3NdzHyw2+Nv0=; b=e57ywDicKtu87q+d8RSK+Uh9L+fpAXqXjvcuSEdrNA 4iHp3kY2ObBLPAtZqbbaQoNrY3Fu0qtd3G5q2F6DRnpOwCTgsK1qNs4Mvo0tiARr Bnyzxq8IzTvKZC5PlVnAWHSNAB2/yVEFYp3Wr+eA5dYW1X+uSqllNBfCrOgL+sZO m99glIg3eGoyH1S8TIDMfe/EFMEKv8gkrY7mgGibogV+eGPZ0SA/ZT3GBWJvonM2 MoW3Odv/3r5OInfFmeQzpPXUC1yR0STMXiHw4RNszb++wEDNNbpZbAIMIe0xrxSp sEtXFbNteFGjeuoJ0xdpsT9LrJFmzzaWDYPJdrts6PIA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :message-id:mime-version:subject:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=GRzcE4hI5AG2i78th bcMf/cB97dZ01L3NdzHyw2+Nv0=; b=jrfBPDSHqWTSn1tTrDWLEYuUwOHA3dRg2 r3x5OHNhDPozYBJj8tiGWPYrcTQtUvroc2ghN9bfxBIAjWsFwrCo92r1AFUYnFCi BIBo5hgOwRTIaF283gcjpHZdoIBIwHr2nwcvN9vxa3NBVIHuLR6K70Fct1CB1XkP tqh9oG79mhDBYV9bG52Wg+H5XAYZ2+R5KExo/m7qV+7oEuXW6Yf6Q60VMtBGjDYY yTY9andCckGWOBT1ZI9lBNuAKyYLqovPDnuOiWtyW+2XFooce05pfBRt+cLqvkIK i4lhY+l3xRT9dbFjeSNZs0QKRbeTNOXlvU1qzOFll6y5rAG4szjyQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrfedtiedggeehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkofgggfestdekredtre dttdenucfhrhhomheptehnughrvgifucflvghffhgvrhihuceorghnughrvgifsegrjhdr ihgurdgruheqnecuggftrfgrthhtvghrnhepkefhieffjeevfeevhedtieeihfefvdejle dvvddthefftedujeethfeuueelfedtnecuvehluhhsthgvrhfuihiivgeptdenucfrrghr rghmpehmrghilhhfrhhomheprghnughrvgifsegrjhdrihgurdgruh X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 6 Jun 2021 21:30:38 -0400 (EDT) From: Andrew Jeffery To: linux-mmc@vger.kernel.org Cc: adrian.hunter@intel.com, ulf.hansson@linaro.org, joel@jms.id.au, linux-aspeed@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, steven_lee@aspeedtech.com Subject: [PATCH] mmc: sdhci-of-aspeed: Turn down a phase correction warning Date: Mon, 7 Jun 2021 11:00:20 +0930 Message-Id: <20210607013020.85885-1-andrew@aj.id.au> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210606_183046_816982_DC5F0C8A X-CRM114-Status: GOOD ( 11.34 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The card timing and the bus frequency are not changed atomically with respect to calls to the set_clock() callback in the driver. The result is the driver sees a transient state where there's a mismatch between the two and thus the inputs to the phase correction calculation formula are garbage. Switch from dev_warn() to dev_dbg() to avoid noise in the normal case, though the change does make bad configurations less likely to be noticed. Reported-by: Joel Stanley Signed-off-by: Andrew Jeffery Reviewed-by: Joel Stanley --- drivers/mmc/host/sdhci-of-aspeed.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/sdhci-of-aspeed.c b/drivers/mmc/host/sdhci-of-aspeed.c index d001c51074a0..e4665a438ec5 100644 --- a/drivers/mmc/host/sdhci-of-aspeed.c +++ b/drivers/mmc/host/sdhci-of-aspeed.c @@ -150,7 +150,7 @@ static int aspeed_sdhci_phase_to_tap(struct device *dev, unsigned long rate_hz, tap = div_u64(phase_period_ps, prop_delay_ps); if (tap > ASPEED_SDHCI_NR_TAPS) { - dev_warn(dev, + dev_dbg(dev, "Requested out of range phase tap %d for %d degrees of phase compensation at %luHz, clamping to tap %d\n", tap, phase_deg, rate_hz, ASPEED_SDHCI_NR_TAPS); tap = ASPEED_SDHCI_NR_TAPS;