Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp2513599rwb; Mon, 3 Oct 2022 01:41:58 -0700 (PDT) X-Google-Smtp-Source: AMsMyM735ONeVi27/YhLZ+sWBJfM36PCJWVOIkCvEhBb52XM4SmWEMWHxGdEAjM75Zlo+yIZCcdX X-Received: by 2002:a05:6a00:138b:b0:561:966a:74a8 with SMTP id t11-20020a056a00138b00b00561966a74a8mr944101pfg.5.1664786518358; Mon, 03 Oct 2022 01:41:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1664786518; cv=none; d=google.com; s=arc-20160816; b=qfjPeeVC+CzSaLDah6n16ss9ichSDHobS52IopJRzGXRP4YXPuefIBaHZZEyDcfasS LqjlHxPs1yOZTyC2UhzMi5/VjR9nIElJUmB2srs91mIabqYZFc4fsuXbPYLbFPmVsTU9 7gxmqvLYkSTMKHJxYGpRzWyMDyz7kddk/adqTeHfuJ/GbC1lBxjFiR4fBBbDcC1rN5Fl +VuJ9qr33ebkyB/+b3CzwzrQm92iSM1IW6Vd6CHNF1JdSZxJKMW4q86496ie0M5pYc58 LBlzx6qmg6rJiY/siYTcXzjXQpOIPVH53x1QlOeGvmjtNAInMsqN17bniVctoynH8ARu JoXg== 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=WRnbwcGPyQyAZAKVyl8rsaWS6QlO4GLxnXhZd5l36rI=; b=Kd7GMMMMUOZ102ymLitH2lGmQ7w/+4vquMF1DsMBpph44jUNUiJyWrCCAMiOH76SZ5 fNT0RZL2os95K4KKFKXCbqGViFZev72GqzR/9zCuvCFiinecdmleVgFpgyHsFqw2bgNW V3lOCMiFHMAJu41maeCGJRj1pseuvq/GPSEbBl6NjUlDtkujOAxnB/+Q0ImSHpM+zl28 DhbI/lzavXtw03iNdV2Inr9eH7dhMheFEGnXbmzfk3gfCLUjVFkc3XwZEoDvHPrVkq2f SPvgibrySsv7qKkeMNIl0GI4MjvrVGnY6/gRYmsAda2Q/HsW/Jkm8heUYI+eLeW3xxgf vVLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=0ovHsNIf; 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 c2-20020aa781c2000000b0053bafb8e916si8784107pfn.162.2022.10.03.01.41.47; Mon, 03 Oct 2022 01:41:58 -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=0ovHsNIf; 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 S231386AbiJCHgt (ORCPT + 99 others); Mon, 3 Oct 2022 03:36:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35386 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231269AbiJCHew (ORCPT ); Mon, 3 Oct 2022 03:34:52 -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 0208452FE6; Mon, 3 Oct 2022 00:22:24 -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 7BCF8B80E93; Mon, 3 Oct 2022 07:21:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E9826C433C1; Mon, 3 Oct 2022 07:21:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1664781710; bh=bLvLAYpSrTFfe7GvDq+4us9MRoQncBYlB1SEYr38dPU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=0ovHsNIfHWU03dxcYH6gVKkP8jQf3BArFCPa2qVlPO9BPpVH0W9XAaIE+6xGBreQE Fn43m+KSlQeuyqifs82kgPSN+u9Qx1qC2m8LKux+OEEbd9SAuvvT/c4PS/mpmYBlTa NMnTT60emus/PwIY2+qGXwSiFLjS3++Gt+gnnW0I= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Nicolas Dufresne , Brian Norris , Ezequiel Garcia , Hans Verkuil , Mauro Carvalho Chehab Subject: [PATCH 5.10 28/52] media: rkvdec: Disable H.264 error detection Date: Mon, 3 Oct 2022 09:11:35 +0200 Message-Id: <20221003070719.567869453@linuxfoundation.org> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20221003070718.687440096@linuxfoundation.org> References: <20221003070718.687440096@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 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: Nicolas Dufresne commit 3a99c4474112f49a5459933d8758614002ca0ddc upstream. Quite often, the HW get stuck in error condition if a stream error was detected. As documented, the HW should stop immediately and self reset. There is likely a problem or a miss-understanding of the self reset mechanism, as unless we make a long pause, the next command will then report an error even if there is no error in it. Disabling error detection fixes the issue, and let the decoder continue after an error. This patch is safe for backport into older kernels. Fixes: cd33c830448b ("media: rkvdec: Add the rkvdec driver") Signed-off-by: Nicolas Dufresne Reviewed-by: Brian Norris Tested-by: Brian Norris Reviewed-by: Ezequiel Garcia Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Greg Kroah-Hartman --- drivers/staging/media/rkvdec/rkvdec-h264.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/staging/media/rkvdec/rkvdec-h264.c +++ b/drivers/staging/media/rkvdec/rkvdec-h264.c @@ -1124,8 +1124,8 @@ static int rkvdec_h264_run(struct rkvdec schedule_delayed_work(&rkvdec->watchdog_work, msecs_to_jiffies(2000)); - writel(0xffffffff, rkvdec->regs + RKVDEC_REG_STRMD_ERR_EN); - writel(0xffffffff, rkvdec->regs + RKVDEC_REG_H264_ERR_E); + writel(0, rkvdec->regs + RKVDEC_REG_STRMD_ERR_EN); + writel(0, rkvdec->regs + RKVDEC_REG_H264_ERR_E); writel(1, rkvdec->regs + RKVDEC_REG_PREF_LUMA_CACHE_COMMAND); writel(1, rkvdec->regs + RKVDEC_REG_PREF_CHR_CACHE_COMMAND);