Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp13334322ybl; Sun, 29 Dec 2019 09:31:51 -0800 (PST) X-Google-Smtp-Source: APXvYqxcydrhlMuOaFWBYu5l94wJwOg3RJS+e/FoMNQ/r8fxZAvGDDKvcNFEPF6hs1kT59GRI3e/ X-Received: by 2002:a9d:5c8a:: with SMTP id a10mr35774249oti.95.1577640711549; Sun, 29 Dec 2019 09:31:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1577640711; cv=none; d=google.com; s=arc-20160816; b=H4KALAiVAZDNZ2mi727ZkkNv4hefuE/ZjCPs7YLgCga17Z9d5sMFwZP70ftz1pxPAT Hm97XJdBMX+DSvhIynauS985i9W8snmCiAaIhLxRmGF7o6dKU9nzwWuPAIwQlMD8UREI wYNHTubvRBtnAe1BjHWy0UCHqHudHwlUCTjR06cf8rc+R9PEVvTzPMRSTmIRdzM4gpRh eDdpRrosDnDzTLtCUakI5AuF2ZB2fiwADeYNMmTG3wvEtQofCYmYeBj4UnT7FTbkoi2O Qk1SvrEiDNuZQy5PAa2seSO7tBT/oJaVdUqZhA8BZVXlx4+n5HDYBUcAHiII5VQixBeW cpLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=pR1xL5A80W3IY3pxzzg8Yy45No1vpjmfMZyfzkAQYnQ=; b=TvAaEt2sbDGoAD/69NATxvSPoANyP6+trEaPMG+sxefnc0/Ysas1cjTlAWnfrivYIF /cYleIMnH5BJissqgWXEVSrH+07ErWg0xqLkWLStYhW8YQIcVp9p8x9NuTyPdGLU4Ipq hf+VXBO50XYQ1KyoLKX2TuD5XONd8fv8NdFYJhDs9sMRbxXRMJEu8hQfm4f76/rgDyL1 Fr4W+IyNSLea1kApEuHqR45hbwbVZ5D/3pNaAKtxd9JbD9vDiVOg2tXQSBlkDl+ZZwJ7 ltQDZR46ote247jJ5mQPO+sPgBEfUkrpjg07+MJyElWJgth/eX6TeLXQY+z3hfyau3UZ h59A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=JPM+CyEW; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z1si22393792otq.21.2019.12.29.09.31.41; Sun, 29 Dec 2019 09:31:51 -0800 (PST) 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=@kernel.org header.s=default header.b=JPM+CyEW; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729013AbfL2Rak (ORCPT + 99 others); Sun, 29 Dec 2019 12:30:40 -0500 Received: from mail.kernel.org ([198.145.29.99]:56944 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728716AbfL2Rai (ORCPT ); Sun, 29 Dec 2019 12:30:38 -0500 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 67A7720722; Sun, 29 Dec 2019 17:30:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1577640637; bh=y4YmVfrhMhPsaeYQtxL6N+JN6WbVBq+cvS8DDysVOb4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=JPM+CyEWsegUD/NLGeFv9QQKmKa+8Ppgo/EwejoA4+jpzuIJtWPSnKfPp3YB+41WY NoondVZ37gUKTE1L8aLNamoXvXNyYoT5oDdTDs0ggc4YJS03joEv9GQDvHHk6Y59GM QdFaM171gHiLRVlEVZ5hWIti4XfN6n+xJMsbcNMs= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Cheng-Yi Chiang , Daniel Kurtz , Yakir Yang , Neil Armstrong , Sasha Levin Subject: [PATCH 4.19 076/219] drm/bridge: dw-hdmi: Restore audio when setting a mode Date: Sun, 29 Dec 2019 18:17:58 +0100 Message-Id: <20191229162517.488181114@linuxfoundation.org> X-Mailer: git-send-email 2.24.1 In-Reply-To: <20191229162508.458551679@linuxfoundation.org> References: <20191229162508.458551679@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Daniel Kurtz [ Upstream commit fadfee3f9d8f114435a8a3e9f83a227600d89de7 ] When setting a new display mode, dw_hdmi_setup() calls dw_hdmi_enable_video_path(), which disables all hdmi clocks, including the audio clock. We should only (re-)enable the audio clock if audio was already enabled when setting the new mode. Without this patch, on RK3288, there will be HDMI audio on some monitors if i2s was played to headphone when the monitor was plugged. ACER H277HU and ASUS PB278 are two of the monitors showing this issue. Signed-off-by: Cheng-Yi Chiang Signed-off-by: Daniel Kurtz Signed-off-by: Yakir Yang Reviewed-by: Neil Armstrong Signed-off-by: Neil Armstrong Link: https://patchwork.freedesktop.org/patch/msgid/20191008102145.55134-1-cychiang@chromium.org Signed-off-by: Sasha Levin --- drivers/gpu/drm/bridge/synopsys/dw-hdmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c index fb396d550275..2a0a1654d3ce 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c @@ -1757,7 +1757,7 @@ static int dw_hdmi_setup(struct dw_hdmi *hdmi, struct drm_display_mode *mode) /* HDMI Initialization Step E - Configure audio */ hdmi_clk_regenerator_update_pixel_clock(hdmi); - hdmi_enable_audio_clk(hdmi, true); + hdmi_enable_audio_clk(hdmi, hdmi->audio_enable); } /* not for DVI mode */ -- 2.20.1