From: Takashi Iwai Subject: Re: [PATCH 1/3] ASoC: hdac_hdmi: report codec link up/down status to bus Date: Wed, 12 Jun 2019 17:04:52 +0200 Message-ID: References: <20190612122258.4363-1-kai.vehmanen@linux.intel.com> <20190612122258.4363-2-kai.vehmanen@linux.intel.com> Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx1.suse.de (mx2.suse.de [195.135.220.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id E9652F806F5 for ; Wed, 12 Jun 2019 17:04:54 +0200 (CEST) In-Reply-To: <20190612122258.4363-2-kai.vehmanen@linux.intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" To: Kai Vehmanen Cc: alsa-devel@alsa-project.org List-Id: alsa-devel@alsa-project.org On Wed, 12 Jun 2019 14:22:56 +0200, Kai Vehmanen wrote: > > Report codec power status to the HDA codec bus from runtime pm > suspend and resume callbacks. This is required to implement > runtime idle logic that relies on 'codec_powered' field of hdac_bus > to be maintained for all codecs. > > Signed-off-by: Kai Vehmanen Reviewed-by: Takashi Iwai It's the same behavior as the legacy HD-audio codec, after all. thanks, Takashi > --- > sound/soc/codecs/hdac_hdmi.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/sound/soc/codecs/hdac_hdmi.c b/sound/soc/codecs/hdac_hdmi.c > index 660e0587f3999..01ab7aed315cb 100644 > --- a/sound/soc/codecs/hdac_hdmi.c > +++ b/sound/soc/codecs/hdac_hdmi.c > @@ -2090,6 +2090,7 @@ static int hdac_hdmi_runtime_suspend(struct device *dev) > return -EIO; > } > > + snd_hdac_codec_link_down(hdev); > snd_hdac_ext_bus_link_put(bus, hlink); > > snd_hdac_display_power(bus, hdev->addr, false); > @@ -2116,6 +2117,7 @@ static int hdac_hdmi_runtime_resume(struct device *dev) > } > > snd_hdac_ext_bus_link_get(bus, hlink); > + snd_hdac_codec_link_up(hdev); > > snd_hdac_display_power(bus, hdev->addr, true); > > -- > 2.17.1 > > _______________________________________________ > Alsa-devel mailing list > Alsa-devel@alsa-project.org > https://mailman.alsa-project.org/mailman/listinfo/alsa-devel >