Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp7405642ybi; Wed, 5 Jun 2019 17:19:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqyCLCutZE2H/lJlb+YWavI0ibwlPM5uZCXXq33FWAn5UBk5Nb3TGfEpCZv3ml7jqgF3HiGv X-Received: by 2002:a63:2c01:: with SMTP id s1mr531048pgs.261.1559780353600; Wed, 05 Jun 2019 17:19:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559780353; cv=none; d=google.com; s=arc-20160816; b=Kr/l1ej99/KZ6xPnpqvVHbO18qwEOAX7QC3jlN7MecyUTD+YorP35IqrK3Sd7tgs2I CRzEofnP6kQRO140PDKDos3krttP/CgQd8ELdm+HrZsye/7XddXJjeKRz+UU+ZTOp4Nk b9P5MwySeM/9Ct2QhIoZ3kxNNn1KlPzYclm50pbTO/EbfukGKT6HNFQJd5eneEoVjdlJ OohGVqGHeYAgNSgfdlASM4B7BlRt+cex9VRVScx17QPaaTCRtTH1O7KOhpSaXsJgOhZT FWdsqTWViX18CnHOSKwQktgMQbQi1wrCHu38ukzoV9UfuvXHth+ycxIYqzvPHnbLRxV7 lrxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=cK/gGt5PDimlIevfbs8g1ARiYxKpO3It4jGHeUdOAXQ=; b=Vz2PNNGmMXhPyXhkp2M+TLSp73C/udIV1tupbK04r3GqtRa7IPSUmjwEYZdzSNpgRf EZkK4BhWEMqcssVkC/oX9clbNucwQVpL0KxBbpmGJ+asBsYn4i4lzlBD5GXAxZWDpuko NzBSBBMkkfzxJouFd0kIU/L6SDk35z2OnHj+R6NeZQxISRRwYjwi8mxHQvyxXrrerF/n gWuVmr/TAi7iGDss7CIaw69/YUnUsr94skvFyOhwGs0xS8zEKWujuxGtXXar8mIKIHxP T2HMOd8gNAcm8aT0jAn3YsYJl+ofgXKwGl94C0JrH9SD1FFPHtyVmG68KYpqIwWe0wjQ Wezg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Ay6RwqsM; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v22si94847pfe.275.2019.06.05.17.18.57; Wed, 05 Jun 2019 17:19:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Ay6RwqsM; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726738AbfFFAQq (ORCPT + 99 others); Wed, 5 Jun 2019 20:16:46 -0400 Received: from mail-pf1-f196.google.com ([209.85.210.196]:44033 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726532AbfFFAQp (ORCPT ); Wed, 5 Jun 2019 20:16:45 -0400 Received: by mail-pf1-f196.google.com with SMTP id t16so307178pfe.11 for ; Wed, 05 Jun 2019 17:16:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=cK/gGt5PDimlIevfbs8g1ARiYxKpO3It4jGHeUdOAXQ=; b=Ay6RwqsM05DNTHbEStXHw3SHZKFvhBkjCx8hE4XKG0cWnEjcpqh9Jb33U70NaQK5P5 JRB8pq/Yv1iSxEVJIdwTFVeT956CEFAyRS+KdKadsqMAOE1dxxx+kkZc0J6ibY/EiQyk T9Y5dPWUBdYx++K6X+6MKeB2LVaUPXV+C4qmTvSoXFCUYIy/2stW9i01QSf95M6u7QZS yOWMQZbN/65Ot9oZZLwrgeVSLMaOpkZZHSFhYVwnf0bi9BYjcCMKc2jmCZTqpbWUoaaD hN0xLeFv976DkIpB+bXcUTrk7gNaxhhJrKKpNfMfJZGgFogEMT2CIntoAluVsBdoA8Xi m6RQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=cK/gGt5PDimlIevfbs8g1ARiYxKpO3It4jGHeUdOAXQ=; b=kpMclDq+Pd5Hl0zo2QnbLbSsUyy3jiXBaKUsRs5COEwLumG6a4wuNqZqYmEZhONTNM Chp84MGTWFENBi5YZfhjqL4jqwP9rkyoLS4NPakehYHzmOlf/goWV7N9f15ndG3da63A THvhzD2JckKrNS/ss+rUdZrhfkjoRB0N/KuFO3s5lP2pgS5yhhmioDRQeIcO15C/q7+s WqQcG5kPvrkD8QcmR6ViMPWTCOI2D3qp6gWuDd9uNYKuBbEx8DncDVD1bKmhMGU+8MSX 1+SUl9eVEew8RIrzBschnNLf/JMmmoBfqgkZMath90FU3aHgpjd1+l6sIOGPfChNxRO6 CvHg== X-Gm-Message-State: APjAAAVVcc1WWBsJ8MAxAZJp5uKU+iRfDmgqLeWCVL+DMaogloGfXbcv WXIdw2JBY7iKXEeECopu/hA= X-Received: by 2002:a17:90a:338e:: with SMTP id n14mr46596229pjb.35.1559780204786; Wed, 05 Jun 2019 17:16:44 -0700 (PDT) Received: from Asurada-Nvidia.nvidia.com (thunderhill.nvidia.com. [216.228.112.22]) by smtp.gmail.com with ESMTPSA id 10sm93476pfh.179.2019.06.05.17.16.43 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 05 Jun 2019 17:16:44 -0700 (PDT) Date: Wed, 5 Jun 2019 17:16:45 -0700 From: Nicolin Chen To: "S.j. Wang" Cc: "broonie@kernel.org" , "timur@kernel.org" , "Xiubo.Lee@gmail.com" , "festevam@gmail.com" , "alsa-devel@alsa-project.org" , "linuxppc-dev@lists.ozlabs.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] ASoC: fsl_esai: fix the channel swap issue after xrun Message-ID: <20190606001644.GA20103@Asurada-Nvidia.nvidia.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Shengjiu, On Wed, Jun 05, 2019 at 10:29:37AM +0000, S.j. Wang wrote: > > > ETDR is not volatile, if we mark it is volatile, is it correct? > > > > Well, you have a point -- it might not be ideally true, but it sounds like a > > correct fix to me according to this comments. > > > > We can wait for Mark's comments or just send a patch to the mail list for > > review. > > I test this patch, we don't need to reset the FIFO, and regcache_sync didn't > Write the ETDR even the EDTR is not volatile. This fault maybe caused by The fsl_esai driver uses FLAT type cache so regcache_sync() would go through regcache_default_sync() that would bypass cache sync at the regcache_reg_needs_sync() check when the cached register value matches its default value: in case of ETDR who has a default value 0x0, it'd just "continue" without doing that _regmap_write() when the cached value equals to 0x0. > Legacy, in the beginning we add this patch in internal branch, there maybe > Something cause this issue, but now can't reproduced. The "legacy" case might happen to have two mismatched ETDR values between the cached value and default 0x0. And I am worried it may appear once again someday. So I feel we still need to change ETDR to volatile type. And for your question "ETDR is not volatile, if we mark it is volatile, is it correct?", I double checked the definition of volatile_reg, and it says: * @volatile_reg: Optional callback returning true if the register * value can't be cached. If this field is NULL but So it seems correct to me then, as the "volatile" should be also transcribed as "non-cacheable". Thanks Nicolin