Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp1862238rwb; Fri, 19 Aug 2022 10:37:06 -0700 (PDT) X-Google-Smtp-Source: AA6agR7mAW8jjm+ZkVoKBQyiOBd7Dik/Pvl8UP7SnqASP/ledew8lSVvLz9z9nzj8UQNobFu0NdW X-Received: by 2002:aa7:88c8:0:b0:536:926:700f with SMTP id k8-20020aa788c8000000b005360926700fmr4732799pff.72.1660930626539; Fri, 19 Aug 2022 10:37:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660930626; cv=none; d=google.com; s=arc-20160816; b=y6S5TUYWpHmQgLHnrhnC36DOI5Fa45IYl07gWLe5wQ6Iq4yJ7gb53dGSVXckqGISWV ujtC1TAw44riEREagwFpMZSL0UVK3EmIbjM+ZDpxN0giWvGAmqFOqtNZabJzukumeL4j wlVY72Zd0B2kd9DS2Ubprz5PZMDRZXhVqxjdLAwnTV5Iq9iMeDCr5KaFczOGKKPiPThT fnQOffmDXZj5SY/OaqcS8R79ws80HQXZd12z25qYUsLdUU31WHOQOcFJZOylsxuOolgv syrTCdJb1kftAAwgkgGIjdX2YWQfNrnIOnOXc4HPLr37j8PVMPu5OKHS7KOEQDFD3aTj 2HHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=AtrsAQqEUuN4SwotMZKtEgv3IUcHKfT8qRSt+nJEHFM=; b=ALQk3CfQxtstE6CkRmZJ6cDTlG41RzFH2nUDuSaGOenwH357Q0bBUiekpO0bEXInG5 wo7ki7ra/1I/pPKWxqnZBOtwuqf8SPjb75V73ttrlCsJa/SNXwh1/sFTp1nvRgzk5yZD EkhrbKQBr/2JTIHVwtzMsaaRKIz8wFUYxNiDwRtF08xhk/bTFTXpJ9PRaLx+nu/qGrb9 Rff1SVapSfisSFU5ecKCPcVc3T+0hj5yT6FBIH25YeiWt4DEhTLmzzyG/Qi2jCUxDRlx U/XGEA/wRsGuRYjFgLbQZL923BgXsTF9udBqkYdpGjdfW0ehUczqO3nO6CDyN/b+BkPO 4hhA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=smZCXevW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o15-20020aa7978f000000b0052abccd715csi1904499pfp.118.2022.08.19.10.36.55; Fri, 19 Aug 2022 10:37:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=smZCXevW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1351575AbiHSQIl (ORCPT + 99 others); Fri, 19 Aug 2022 12:08:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351581AbiHSQGE (ORCPT ); Fri, 19 Aug 2022 12:06:04 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C1F9B107AD5; Fri, 19 Aug 2022 08:55:33 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 333CAB8281C; Fri, 19 Aug 2022 15:55:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9184EC433C1; Fri, 19 Aug 2022 15:55:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1660924530; bh=34hWI5LEAXPOy5D+UkA90PyfWHytamfK+RNcrZmgBb8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=smZCXevWEHbQCC183XBdYJmrj3LKqb8CWfFRB2XAOkQI4Jf07SzLudUXGP692aKEK W8EiN+ncHT16c2J7K8YsiXAfYP2WYdvemQ9l1B7NjHpQtA7zhE1jvgjFG72ogacLjK uaOw4jNqu9QtElf4OZ26Z5g9XsgBDVmV9okSlis0= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dom Cobley , Maxime Ripard , Sasha Levin Subject: [PATCH 5.10 200/545] drm/vc4: hdmi: Avoid full hdmi audio fifo writes Date: Fri, 19 Aug 2022 17:39:30 +0200 Message-Id: <20220819153838.337762307@linuxfoundation.org> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20220819153829.135562864@linuxfoundation.org> References: <20220819153829.135562864@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dom Cobley [ Upstream commit 1c594eeccf92368177c2e22f1d3ee4933dfb8567 ] We are getting occasional VC4_HD_MAI_CTL_ERRORF in HDMI_MAI_CTL which seem to correspond with audio dropouts. Reduce the threshold where we deassert DREQ to avoid the fifo overfilling Fixes: bb7d78568814 ("drm/vc4: Add HDMI audio support") Signed-off-by: Dom Cobley Link: https://lore.kernel.org/r/20220613144800.326124-21-maxime@cerno.tech Signed-off-by: Maxime Ripard Signed-off-by: Sasha Levin --- drivers/gpu/drm/vc4/vc4_hdmi.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c index 6acc34f1e095..9a90f22df3d2 100644 --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c @@ -1033,10 +1033,10 @@ static int vc4_hdmi_audio_hw_params(struct snd_pcm_substream *substream, /* Set the MAI threshold */ HDMI_WRITE(HDMI_MAI_THR, - VC4_SET_FIELD(0x10, VC4_HD_MAI_THR_PANICHIGH) | - VC4_SET_FIELD(0x10, VC4_HD_MAI_THR_PANICLOW) | - VC4_SET_FIELD(0x10, VC4_HD_MAI_THR_DREQHIGH) | - VC4_SET_FIELD(0x10, VC4_HD_MAI_THR_DREQLOW)); + VC4_SET_FIELD(0x08, VC4_HD_MAI_THR_PANICHIGH) | + VC4_SET_FIELD(0x08, VC4_HD_MAI_THR_PANICLOW) | + VC4_SET_FIELD(0x06, VC4_HD_MAI_THR_DREQHIGH) | + VC4_SET_FIELD(0x08, VC4_HD_MAI_THR_DREQLOW)); HDMI_WRITE(HDMI_MAI_CONFIG, VC4_HDMI_MAI_CONFIG_BIT_REVERSE | -- 2.35.1