Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp5359335pxu; Wed, 21 Oct 2020 23:18:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzhVjytIvmzv5KXjNuMWnS4vzPIIUAZrLJ4PbXNSVXh7XLUrBRcn6j6++ygLh3L61BenUCl X-Received: by 2002:a17:906:3a1a:: with SMTP id z26mr768108eje.519.1603347508042; Wed, 21 Oct 2020 23:18:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603347508; cv=none; d=google.com; s=arc-20160816; b=Ib+dnXMLd+x8fq6qog/2alZ7Pqv1jALQeqRCov3hfeEEDUFuaKOFMdgAADa58Or8pc miWCHlLVCu2YrCcRPwr84dHTfvdAFkTm5hx+3WJ2B7a4R6mP7Yr0XRI0qEw9yYuNL19q t43dYTtTLskBGu4QNZUNt+mABJFuVVUCewWRImoD0S/EVGQX8gcW/F7uc9mNGgIypzM2 qT2JAxmC2l+N05KUjA4wap+agJRht/RX0s9QSWDhy4wW6Vnxz8gICxt8GsqEk1cuZPjU QMQMA//izVM6qzT0rl7rmXHOHw966+LIFztkzQwiM0cs+Hc1KOMn5RrvRGb/CafAm3CS Q0Ow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:user-agent:references:in-reply-to :subject:cc:to:from:date:content-transfer-encoding:mime-version :dkim-signature; bh=temgK5vVQG9U2QWr7A/AJokaFqROaQiMWwV8Ob+suB4=; b=m8jE7KabrdFJd9Vte0nm1APY+WeEBJlwsRi/Z2gk7YGmCmclmojSaa9hFc4jaeN5aQ cE2LIS/pf9lk9Dek+ePMG8EJEzwW2Nzqb9XLLJ5DPoGDg4hcGQgWrU25+Ihz042v27Df 63aKuM6v7v9BCvkU0RIUxRxeNAPblCl/YdK9dmUEPslJdNzhz97A47zwOco5reXeSfpg QS7DNuLVln858bQG+/09G4wMVwESfXxnPugSN0Ypi347uJphwLtk/pfjdUhV9I/TFg5R b6/9cYfAd3RSDjXGKQiKgKDKzOgYlE6R+EhESNtV0uHuB7RCufjD99vEVohgd26612bn 7ycA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b="TN/dz09I"; 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 d4si397722edo.178.2020.10.21.23.18.06; Wed, 21 Oct 2020 23:18:28 -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; dkim=pass header.i=@walle.cc header.s=mail2016061301 header.b="TN/dz09I"; 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 S2503486AbgJUR3z (ORCPT + 99 others); Wed, 21 Oct 2020 13:29:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36720 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2503481AbgJUR3z (ORCPT ); Wed, 21 Oct 2020 13:29:55 -0400 Received: from ssl.serverraum.org (ssl.serverraum.org [IPv6:2a01:4f8:151:8464::1:2]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 091A9C0613CE; Wed, 21 Oct 2020 10:29:55 -0700 (PDT) Received: from ssl.serverraum.org (web.serverraum.org [172.16.0.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ssl.serverraum.org (Postfix) with ESMTPSA id CEDBD22EEB; Wed, 21 Oct 2020 19:29:47 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walle.cc; s=mail2016061301; t=1603301388; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=temgK5vVQG9U2QWr7A/AJokaFqROaQiMWwV8Ob+suB4=; b=TN/dz09IA9vm+/fSjtqWq5A+oC26StzoZYB/RDr2CIQpBbV8Yn3UMx8JN6UWm/13XYAGty 2iGvSFgmp1XQr7jKCScUIHdy97ClxqhvYgW/vplpEigRJFEEyspzuW5F8FHVz+HI2Rdnjp iR+C2/CQx+VK4jmZFI8XFNobidfFYC0= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Wed, 21 Oct 2020 19:29:47 +0200 From: Michael Walle To: Ulf Hansson Cc: linux-mmc@vger.kernel.org, Linux Kernel Mailing List , Yangbo Lu , Adrian Hunter Subject: Re: [PATCH] mmc: sdhci-of-esdhc: set timeout to max before tuning In-Reply-To: References: <20201015231149.9333-1-michael@walle.cc> <7051c929a585bf7b1f62561f0ea91193@walle.cc> User-Agent: Roundcube Webmail/1.4.9 Message-ID: <63b574bbda356f93fe706301416195a7@walle.cc> X-Sender: michael@walle.cc Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Am 2020-10-21 17:04, schrieb Ulf Hansson: > On Fri, 16 Oct 2020 at 14:50, Michael Walle wrote: >> >> Am 2020-10-16 12:53, schrieb Ulf Hansson: >> > On Fri, 16 Oct 2020 at 01:12, Michael Walle wrote: >> >> >> >> On rare occations there is the following error: >> >> >> >> mmc0: Tuning timeout, falling back to fixed sampling clock >> >> >> >> There are SD cards which takes a significant longer time to reply to >> >> the >> >> first CMD19 command. The eSDHC takes the data timeout value into >> >> account >> >> during the tuning period. The SDHCI core doesn't explicitly set this >> >> timeout for the tuning procedure. Thus on the slow cards, there might >> >> be >> >> a spurious "Buffer Read Ready" interrupt, which in turn triggers a >> >> wrong >> >> sequence of events. In the end this will lead to an unsuccessful >> >> tuning >> >> procedure and to the above error. >> >> >> >> To workaround this, set the timeout to the maximum value (which is the >> >> best we can do) and the SDHCI core will take care of the proper >> >> timeout >> >> handling. >> >> >> >> Signed-off-by: Michael Walle >> > >> > Sound like this should be tagged for stable, right? >> >> Yes, but I was unsure about that. I didn't find a lot of Fixes: tags >> in >> the history of this driver (eg. for errata etc.) >> >> I could repost a v2 with a fixes tag if you like. > > If this is regression and you can point to a specific commit it fixes, > then please yes! That would be commit ba49cbd0936e ("mmc: sdhci-of-esdhc: add tuning support"). But as of today it isn't much left of that original code. So I don't know if adding that fixes tag will help a lot. Correct me if I'm wrong. -michael