Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp1677193rwb; Wed, 16 Nov 2022 23:40:32 -0800 (PST) X-Google-Smtp-Source: AA0mqf7k6fDwd13jtUorGDurLEltX+ZHp3SwcfI0m3o80XFM7SNZ0NM5YUPR/tzSe0GA3Q+sjA4Y X-Received: by 2002:a05:6402:4507:b0:467:205b:723d with SMTP id ez7-20020a056402450700b00467205b723dmr1160574edb.69.1668670832021; Wed, 16 Nov 2022 23:40:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668670832; cv=none; d=google.com; s=arc-20160816; b=HPQ9EQn9js6g4+vDu9tV+jSn3iK8cWxFV7Qg+cC5bQL3ykkW9u9yMg03aLcZzyHiSV DL3NN7Gg3tNqhGDt8eAHk/z6t5IcA+NGWqUZytdCEnEtolE1DIFcq6KfODEdUsthRO+A rSryUVoFwmEgMkXxw78qgzQ55Tgzmm8gcH00ETdm/IHTLJmAlq/MccJit4zds1e+bTN/ eKS66p6VbwZuU6LeRNYM1BJgAdk9VQGlxi7GKDzSwg5/jR4EbHwsqM8tlLoIPnBXMgSP cwplr0TK53AWcSSD/TDmXovTuUuPkzZFhUACqMlmnuH4BU3fGbJv4TTRak0GkevKdPBn 5fYw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :organization:from:references:cc:to:content-language:subject :user-agent:mime-version:date:message-id:dkim-signature; bh=XrpFvu4uyy9r9/SFuxt9QByo6kVqCBGx+O0kEYob6xo=; b=TzebfFsW4qIo5GViC+HS6buRVhIj8zo/NC06K44HVFWMOE5BuwyYEhOLYjXfW0Kdjy e1cMO/OhqKdB7k9ghy2fuNyI88ipHakTEwPDAzgkE+UhKjOi+WlYl6KMLts6hskANZ1b sQZJ2HuBYx1teA5bfPh3kp04ROGLwjFbLBAdj1S26cgY8f/q3TwCGAQdZ7BJEdWHZ5B3 WKLfZxkizMccWh4SwZHwaGv1zWbvJM2XX6z/GwNIQ9k3ijGuQ0/yulSLAmMdH7Qlpxtz yjIKnbkufkD7950WDwFmejkzjMLLhgcmIZxFW+ktqa4jez6EPaVbLjbABpCU1m2qqtS5 F9wQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=eHl9Ds18; 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=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id dp17-20020a170906c15100b007ae8b1704d0si39442ejc.68.2022.11.16.23.40.10; Wed, 16 Nov 2022 23:40:32 -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=@intel.com header.s=Intel header.b=eHl9Ds18; 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=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234550AbiKQHQK (ORCPT + 92 others); Thu, 17 Nov 2022 02:16:10 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53308 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233963AbiKQHQI (ORCPT ); Thu, 17 Nov 2022 02:16:08 -0500 Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1B2816F35A; Wed, 16 Nov 2022 23:16:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1668669366; x=1700205366; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=OZR+MyWLgP8HkrZB6F3ZwjvvPglgkpwXgGMdnYgokHc=; b=eHl9Ds18wekUjKrR2j+IFgYswVUB3iXAAhx6iTSBnNsave5wPW2vmh3G D/BoeGbRv2WGHmP7fXo4c63BCY8h3s13IEFYx6MwQkk3cJS6Dl77jAc7T as6SBo36j6dYXLRC9S4rA4ISf1FeBVefP41i20YdEb+SFA357LJGlKV6h 47YYOmLjO2KHebmMilHuTCwX7cCvxbT7wIZKU2Uw9YMfPZGSG96alk2MQ zfubzgoJtcby2zohNeSoY8pJPbogjP1J2oOFVLUC1UNitaMo5ER7VgYip 4H8zPktztPXmefUTHOblgxOFc+OvOLmjzn30JP8EXicqE2guopgvOlAk4 Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10533"; a="311483256" X-IronPort-AV: E=Sophos;i="5.96,171,1665471600"; d="scan'208";a="311483256" Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Nov 2022 23:16:05 -0800 X-IronPort-AV: E=McAfee;i="6500,9779,10533"; a="590511493" X-IronPort-AV: E=Sophos;i="5.96,171,1665471600"; d="scan'208";a="590511493" Received: from ahunter6-mobl1.ger.corp.intel.com (HELO [10.0.2.15]) ([10.252.35.99]) by orsmga003-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 16 Nov 2022 23:16:02 -0800 Message-ID: Date: Thu, 17 Nov 2022 09:15:58 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0 Thunderbird/102.5.0 Subject: Re: [PATCH V3 1/1] mmc: sdhci: Fix the SD tuning issue that the SDHCI_TRANSFER_MODE is cleared incorrectly Content-Language: en-US To: Charl Liu , ulf.hansson@linaro.org, linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org Cc: shaper.liu@bayhubtech.com, chevron.li@bayhubtech.com, thomas.hu@bayhubtech.com, xiaoguang.yu@bayhubtech.com, shirley.her@bayhubtech.com References: <20221111122314.307-1-charl.liu@bayhubtech.com> From: Adrian Hunter Organization: Intel Finland Oy, Registered Address: PL 281, 00181 Helsinki, Business Identity Code: 0357606 - 4, Domiciled in Helsinki In-Reply-To: <20221111122314.307-1-charl.liu@bayhubtech.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE 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 On 11/11/22 14:23, Charl Liu wrote: > When cmd->opcode == MMC_SEND_TUNING_BLOCK, the SDHCI_TRANSFER_MODE > should also be kept > > Signed-off-by: Charl Liu Acked-by: Adrian Hunter > --- > change in V1: > Keeping the SDHCI_TRANSFER_MODE when cmd->opcode == MMC_END_TUNING_BLOCK > > change in V2: > add the mmc_op_tuning interface to judge if the opcode is tuning CMD > > change in V3: > cancel the redundant code > --- > drivers/mmc/host/sdhci.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c > index fef03de85b99..98ee688de50d 100644 > --- a/drivers/mmc/host/sdhci.c > +++ b/drivers/mmc/host/sdhci.c > @@ -1465,7 +1465,7 @@ static void sdhci_set_transfer_mode(struct sdhci_host *host, > if (host->quirks2 & > SDHCI_QUIRK2_CLEAR_TRANSFERMODE_REG_BEFORE_CMD) { > /* must not clear SDHCI_TRANSFER_MODE when tuning */ > - if (cmd->opcode != MMC_SEND_TUNING_BLOCK_HS200) > + if (!mmc_op_tuning(cmd->opcode)) > sdhci_writew(host, 0x0, SDHCI_TRANSFER_MODE); > } else { > /* clear Auto CMD settings for no data CMDs */