From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751973AbcFFQp6 (ORCPT ); Mon, 6 Jun 2016 12:45:58 -0400 Received: from mail.pqgruber.com ([178.189.19.235]:63959 "EHLO mail.pqgruber.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751120AbcFFQp5 (ORCPT ); Mon, 6 Jun 2016 12:45:57 -0400 Date: Mon, 6 Jun 2016 18:45:47 +0200 From: Clemens Gruber To: Fabio Estevam Cc: Eric Nelson , Mark Brown , alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org Subject: Re: [alsa-devel] [PATCH] ASoC: sgtl5000: only check VDDD-supply, not revision Message-ID: <20160606164547.GA2203@archie.localdomain> References: <20160602124724.7725-1-clemens.gruber@pqgruber.com> <5751AEF6.40200@nelint.com> <575264A4.2070709@nelint.com> <20160604090324.GA867@archie.localdomain> <20160604171525.GA29266@archie.localdomain> <20160605231626.GA4076@archie.localdomain> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.6.1 (2016-04-27) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Fabio, On Sun, Jun 05, 2016 at 10:22:55PM -0300, Fabio Estevam wrote: > Hi Clemens, > > On Sun, Jun 5, 2016 at 8:16 PM, Clemens Gruber > wrote: > > > I looked into this today and discovered the following: > > > > With my patch applied, if I reset the board just after playback, at the > > next boot, the sgtl5000_fill_defaults function does not succeed: Writing > > the default value 0x7060 to register 0x30 (CHIP_ANA_POWER) fails. > > > > How did CHIP_ANA_POWER change with my patch: Before, only > > LINREG_SIMPLE_POWERUP was cleared as is recommended in the datasheet > > when using the internal LDO, now both LINREG_SIMPLE_POWERUP and > > STARTUP_POWERUP are cleared, as is recommended when using external VDDD. > > > > But why does the SGTL5000 nack that default write to CHIP_ANA_POWER > > after a reboot, which interrupted the playback? > > > > The following patch from Eric solved the problem; one write fails but it > > continues setting the other registers and thus even if resetting a board > > during playback, the sound still works after reboot: > > http://mailman.alsa-project.org/pipermail/alsa-devel/2015-February/088356.html > > Another workaround might be to not even write a default value to > > CHIP_ANA_POWER, as in this patch from Eric: > > http://mailman.alsa-project.org/pipermail/alsa-devel/2015-February/088355.html > > > > What do you think we should do? > > Shouldn't both patches be applied? Yes, I think so too. However I am unsure if we should also remove SGTL5000_CHIP_LINREG_CTRL from the defaults as in Eric's patch 3/6 or only keep the parts of the patch dealing with SGTL5000_CHIP_ANA_POWER. What do you think? Regards, Clemens