Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758728Ab3IBOwV (ORCPT ); Mon, 2 Sep 2013 10:52:21 -0400 Received: from caramon.arm.linux.org.uk ([78.32.30.218]:51910 "EHLO caramon.arm.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756755Ab3IBOwU (ORCPT ); Mon, 2 Sep 2013 10:52:20 -0400 Date: Mon, 2 Sep 2013 15:50:57 +0100 From: Russell King - ARM Linux To: Sebastian Hesselbarth Cc: David Airlie , Darren Etheridge , Rob Clark , Daniel Vetter , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] drm/i2c: Fix broken TDA998x audio (was: Re: [PATCH v2 5/8] drm/i2c: tda998x: add video and audio input configuration) Message-ID: <20130902145057.GX6617@n2100.arm.linux.org.uk> References: <1376509413-1462-1-git-send-email-sebastian.hesselbarth@gmail.com> <1376509413-1462-6-git-send-email-sebastian.hesselbarth@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1376509413-1462-6-git-send-email-sebastian.hesselbarth@gmail.com> User-Agent: Mutt/1.5.19 (2009-01-05) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2788 Lines: 68 On Wed, Aug 14, 2013 at 09:43:30PM +0200, Sebastian Hesselbarth wrote: > From: Russell King > > This patch adds tda998x specific parameters to allow it to be configured > for different boards using it. Also, this implements rudimentary audio > support for S/PDIF attached controllers. > > Signed-off-by: Russell King > Signed-off-by: Sebastian Hesselbarth > Tested-by: Darren Etheridge > --- It looks like there's been a bug introduced in this patch (which wasn't in my original). > @@ -445,8 +681,7 @@ tda998x_encoder_dpms(struct drm_encoder *encoder, int mode) > > switch (mode) { > case DRM_MODE_DPMS_ON: > - /* enable audio and video ports */ > - reg_write(encoder, REG_ENA_AP, 0xff); > + /* enable video ports, audio will be enabled later */ > reg_write(encoder, REG_ENA_VP_0, 0xff); > reg_write(encoder, REG_ENA_VP_1, 0xff); > reg_write(encoder, REG_ENA_VP_2, 0xff); I also disabled the writing to REG_ENA_AP in the DPMS off path as well, which clears this register. That seems to be missing from this patch, and it means that when the display is placed into DPMS-off mode, the audio inputs are disabled, never to be re-enabled. There is no need to disable the audio input in DPMS-off mode. 8<============= From: Russell King Subject: [PATCH] drm/i2c: Fix broken TDA998x audio In patch "drm/i2c: tda998x: add video and audio input configuration" in its original version, disabling the audio input port was removed. The version which was submitted for merging had this change deleted, which results in audio being non-functional. Fix this by removing the write. While here, update the comment too. Signed-off-by: Russell King --- drivers/gpu/drm/i2c/tda998x_drv.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i2c/tda998x_drv.c b/drivers/gpu/drm/i2c/tda998x_drv.c index 5742cfc..59878af 100644 --- a/drivers/gpu/drm/i2c/tda998x_drv.c +++ b/drivers/gpu/drm/i2c/tda998x_drv.c @@ -705,8 +705,7 @@ tda998x_encoder_dpms(struct drm_encoder *encoder, int mode) reg_write(encoder, REG_VIP_CNTRL_2, priv->vip_cntrl_2); break; case DRM_MODE_DPMS_OFF: - /* disable audio and video ports */ - reg_write(encoder, REG_ENA_AP, 0x00); + /* disable video ports */ reg_write(encoder, REG_ENA_VP_0, 0x00); reg_write(encoder, REG_ENA_VP_1, 0x00); reg_write(encoder, REG_ENA_VP_2, 0x00); -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/