Received: by 2002:a25:2c96:0:0:0:0:0 with SMTP id s144csp825095ybs; Sun, 24 May 2020 23:24:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzQOcdqAikZAmch2rsldW+fcsf8KfTUQhlWwxIKDaukOJ6pLSEl8su8SfAPa1wkYbNDjq2Y X-Received: by 2002:a05:6402:1d81:: with SMTP id dk1mr13537954edb.143.1590387846672; Sun, 24 May 2020 23:24:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1590387846; cv=none; d=google.com; s=arc-20160816; b=qx13UkOcAz2Bn/VlGRP3veqwFl9CloEjqIWEAqP1rkzeA+SibUqAHqEgndrWPvTnhd J4buaCCRzfKMOutzNEVcXM5we/KTMp+HhbrK0sFKfvqqkUC7hIPYJu8BpZeFa70OHZ62 NACSsqEr7wSUjwW7M8d6ENvid6BT4OcpYbPWbGsIZeGZ+VqTFsWSWnvy/AK2MLUrH7wy OuJEmVBPXSTXEE47MSr7qiWbC/cqxjuoZRjl026sDR+Qh5X9rTPPzzlN/RPYTgEfRoh3 QzzR49rvnK36zTVzY6LUiMVhwchjc+Uu7/7pvuWp/tom3485osDEBHTvdMJIVnQHzpw3 n47g== 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=qkQKxQdGGgWdvEooTQeXfQ5Uv6xFbcDpVhOQuc16oUc=; b=t4LKqrmn9oXfUsKMTgMaKhG+3TZCOFDby8+ySRImj5LbfHCUglOJCevQY5nRayfyq6 fg8S+EhA2QWYD6lF0MXywdAKZPRzeYP2hqPYKhxuzzgNk2UyNDM3sKTCKpbpWDwkVoue UkztTjMW+7FpnzqghduFfG9/ZstvM33rgo95sgSwiz7UKiSAN3QSHB/2rb7WeNHgo4G7 KWMkmnz4GE9c2cAKvkFApNuWaOOT4hcH98sDr1/NsxnSx7iPdf7fgJw1MxOdD8dXQa+n gtmf3RdvH4L1ufxomEiP2jxJQnhjUdaieL3Bm0UY/KJwtftlCh1MhGlCosJ42euFLhuw boPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=sgLbL5BC; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n11si5838415ejl.677.2020.05.24.23.23.43; Sun, 24 May 2020 23:24:06 -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=@gmail.com header.s=20161025 header.b=sgLbL5BC; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730113AbgEYGSd (ORCPT + 99 others); Mon, 25 May 2020 02:18:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53690 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729690AbgEYGSc (ORCPT ); Mon, 25 May 2020 02:18:32 -0400 Received: from mail-pg1-x541.google.com (mail-pg1-x541.google.com [IPv6:2607:f8b0:4864:20::541]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D5D1AC061A0E for ; Sun, 24 May 2020 23:18:32 -0700 (PDT) Received: by mail-pg1-x541.google.com with SMTP id u5so8285616pgn.5 for ; Sun, 24 May 2020 23:18:32 -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=qkQKxQdGGgWdvEooTQeXfQ5Uv6xFbcDpVhOQuc16oUc=; b=sgLbL5BCVGnsptyzLFvhBHakHWNFyE7cXapL55cgodXb2vOhXm56MOdyIhCbvyn+V6 N5SpUnMqMfQTxpDC1oxfNr3O0Z5D9Q+P35dmFRYpwkUHzM7HUXzNKDIN4y3Q/pt4yOOj nJ79hm3sG+vkBgfUoOUM7+9/7ASYFUIelrkTzM+sj4p7iYvQyMjNUzbnGcY/2i3fO8x8 78Xsdeo6b0CdlwlRBVjX9uib/uaYHpQkXdll055UGUGElf7mLUzQphtdpc4wZyA7j5eV FgMRfBBTXcDDFYydBzTMFJxhjryo7u9v5GiERnJ6QEtJl9DvihXJrH+0ZCeDrKJ9dyYr NrPw== 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=qkQKxQdGGgWdvEooTQeXfQ5Uv6xFbcDpVhOQuc16oUc=; b=j+enOJ8RGQDhc+xN1TkOpyU8tw/5uprMU9BRw8/QUktlupmxGPKfGnl/fZM9OB6kKo aI1MCgY4w/cvSLf+eE6q3mLqKS5Vmb2qRrZUm6VLcfgMwDeaBqaey1iJGSs+e6/TXU8e F8P8zGAnWYrRXNOxwerc0JMJdONxWGTT5oFgOzVpN8jfxb83lNg47vi1xIRgl+ddMHf1 fi6RSoSvw/ZCEtIG7Dx7EqoD17UvUO0p2O27l742sWgAB5jFNKnhy3aQ03IcjDyJ3tPt /IjQK5vCo2p0dgGVyKlYL8z4gyoyqDzXNOauG1s7gKZndENjTU1IZ+9zjpP3ilMQ1IGT xlXA== X-Gm-Message-State: AOAM532o/PQS1s3YBN41jTeKHyKNIdfTP2CXOzYqbo+LjsRWoQ4YB5Wj C2Wp+9qE+966gAiGz7mZofs= X-Received: by 2002:a65:52cd:: with SMTP id z13mr10751049pgp.259.1590387512418; Sun, 24 May 2020 23:18:32 -0700 (PDT) Received: from Asurada (c-73-162-191-63.hsd1.ca.comcast.net. [73.162.191.63]) by smtp.gmail.com with ESMTPSA id i197sm24018pfe.30.2020.05.24.23.18.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 May 2020 23:18:32 -0700 (PDT) Date: Sun, 24 May 2020 23:18:27 -0700 From: Nicolin Chen To: Shengjiu Wang Cc: Shengjiu Wang , Linux-ALSA , Timur Tabi , Xiubo Li , linuxppc-dev@lists.ozlabs.org, Takashi Iwai , Liam Girdwood , Mark Brown , Fabio Estevam , linux-kernel Subject: Re: [PATCH] ASoC: fsl_asrc: Merge suspend/resume function to runtime_suspend/resume Message-ID: <20200525061827.GB12112@Asurada> References: <1590141444-28668-1-git-send-email-shengjiu.wang@nxp.com> <20200525050950.GA1244@Asurada> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.22 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 25, 2020 at 02:11:18PM +0800, Shengjiu Wang wrote: > > > @@ -1135,6 +1137,24 @@ static int fsl_asrc_runtime_resume(struct device *dev) > > > goto disable_asrck_clk; > > > } > > > > > > + /* Stop all pairs provisionally */ > > > + regmap_read(asrc->regmap, REG_ASRCTR, &asrctr); > > > + regmap_update_bits(asrc->regmap, REG_ASRCTR, > > > + ASRCTR_ASRCEi_ALL_MASK, 0); > > > + > > > + /* Restore all registers */ > > > + regcache_cache_only(asrc->regmap, false); > > > + regcache_mark_dirty(asrc->regmap); > > > > > > I see you doing regcache_mark_dirty() in the resume() now, > > being different from previously doing in suspend()? > Which is for probe -> runtime_resume case. > After probe, the power may be disabled, so move mark_dirtry > to runtime_resume, then regcache can re-write all the registers. I see. Just noticed that you add a regcache_cache_only in probe(). Acked already. Thanks.