Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4238297pxj; Tue, 25 May 2021 03:32:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy4TQ+RZ9mFyt6NdH0ge+s1XcVO7vMuSt+vm9bCdUdinJmwC8s0ZJrncFlPxLvIyLg7SuV8 X-Received: by 2002:a05:6402:4252:: with SMTP id g18mr30307113edb.195.1621938750980; Tue, 25 May 2021 03:32:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621938750; cv=none; d=google.com; s=arc-20160816; b=S+Jznq/tNtCtk2I3U25ewwcfZO6fM8HoTp2TOchNn2alwxG7YJWfCb8+UbYUKug7aD fMARzUHWkPb5rlzKyjDUP+j6jOHRy2Fgewc8raSQ13SYALBEfAPSYhnx4lSdruZj8zFJ ZUQYEZTjVK8STe97AOVmG8xUHBqtxKp2/Jy5+fGzEmLJvFTC9I5qIYebx335FcOSeCF+ AvC+kAvrs2Vz6QFmHMk7+06V0rgOqansn9bIQWB6njiByAFgV84Ak2EnTpXu5bd5znCI GCXahunK4L1j06qRWizooavcpF4RN3F90Wd8AaSkhq9TvHBGsL64oBM9y5IKavAVWbxB RTpg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=aZz/75r0VSldRnfEC0lDjnxJeLd+pWzYm+12tZWWOuE=; b=PLNnY8LDBCSLwGR8woNGXW1eVaFWGCfObLVCB0JUAvmLas6GSXkgRIA8JIeBp8Nl1U UcgDRWTltCUcbbwJO73xbvCcNSJZBZJJY3/c6dJEQplZIs8eMN8N2j24BdFNGKh84XCJ 5so9oRqrMpRORcFdmXkr1XoYmlbhf+EiYG5VjvRyVRgAG2Itfd4zq30Mloz0uobMcmG0 EwfATVSViMUN7rjJlWzcSa9kyCKxE7Bh2lCKIF9BS/j/VgCDeVwhVRSkn3EIwjA6d4gv 3BtvCxA/5odUl/LEUc24IKfuxlycLB8xcjpQGLIvEZuoJ1jhJxGpc758hN4rFS+GgB5F KowQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p23si4404426edw.135.2021.05.25.03.32.07; Tue, 25 May 2021 03:32:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232678AbhEYJue (ORCPT + 99 others); Tue, 25 May 2021 05:50:34 -0400 Received: from twspam01.aspeedtech.com ([211.20.114.71]:44440 "EHLO twspam01.aspeedtech.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232545AbhEYJue (ORCPT ); Tue, 25 May 2021 05:50:34 -0400 Received: from mail.aspeedtech.com ([192.168.0.24]) by twspam01.aspeedtech.com with ESMTP id 14P9ZLSX049551; Tue, 25 May 2021 17:35:21 +0800 (GMT-8) (envelope-from steven_lee@aspeedtech.com) Received: from aspeedtech.com (192.168.100.253) by TWMBX02.aspeed.com (192.168.0.24) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 25 May 2021 17:48:19 +0800 Date: Tue, 25 May 2021 17:48:16 +0800 From: Steven Lee To: Joel Stanley CC: Andrew Jeffery , Rob Herring , "Adrian Hunter" , Ulf Hansson , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , "moderated list:ARM/ASPEED MACHINE SUPPORT" , "moderated list:ARM/ASPEED MACHINE SUPPORT" , open list , linux-mmc , "moderated list:ASPEED SD/MMC DRIVER" , "Hongwei Zhang" , Ryan Chen , Chin-Ting Kuo Subject: Re: [PATCH v5 0/4] mmc: sdhci-of-aspeed: Support toggling SD bus signal Message-ID: <20210525094815.GA8757@aspeedtech.com> References: <20210524073308.9328-1-steven_lee@aspeedtech.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) X-Originating-IP: [192.168.100.253] X-ClientProxiedBy: TWMBX02.aspeed.com (192.168.0.24) To TWMBX02.aspeed.com (192.168.0.24) X-DNSRBL: X-MAIL: twspam01.aspeedtech.com 14P9ZLSX049551 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The 05/25/2021 15:55, Joel Stanley wrote: > On Mon, 24 May 2021 at 07:33, Steven Lee wrote: > > > > AST2600-A2 EVB has the reference design for enabling SD bus > > power and toggling SD bus signal voltage between 3.3v and 1.8v by > > GPIO regulators. > > This patch series adds sdhci node and gpio regulators in a new dts file > > for AST2600-A2 EVB. > > The description of the reference design of AST2600-A2 EVB is added > > in the new dts file. > > > > This patch also include a helper for updating AST2600 sdhci capability > > registers. > > The device trees look good: > > Reviewed-by: Joel Stanley > > I've applied patches 1-3 to the aspeed tree for v5.14. I made a little > fix to patch 3 as it needed to add the new device tree to the > makefile. > Thanks! > When I was testing on my A2 EVB I saw this: > > [ 1.436219] sdhci-aspeed 1e750100.sdhci: Requested out of range > phase tap 192 for 9 degrees of phase compensation at 1562500Hz, > clamping to tap 15 > [ 1.450913] sdhci-aspeed 1e750100.sdhci: Requested out of range > phase tap 963 for 45 degrees of phase compensation at 1562500Hz, > clamping to tap 15 > > Do you know what is happening there? > Per MMC spec, eMMC bus speed is set as legacy mode(0~26MHz) at startup of eMMC initializtion flow. Clock phase calculation is triggered in set_clock() and it calculates taps based on phase_deg(<9>, <225>) in the dts file and the current speed(1562500Hz), which causes the warning message you mentioned. As the phase_deg in the dts file should be calculated with 100MHz. https://lkml.org/lkml/2021/5/24/95 But after some initialization flow, eMMC bus speed will be set to correct speed(100MHz). Clock phase calculation will be triggered again to get correct taps. > Cheers, > > Joel