Message ID | 20221117092453.31366-6-yunfei.dong@mediatek.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp300319wrr; Thu, 17 Nov 2022 01:30:14 -0800 (PST) X-Google-Smtp-Source: AA0mqf6Q+O1xMHoi/Mk1ue9Syqf/LsKeP7fRqPLyJM23tvXAFbvBsGmDALD2LIGMeeSy6cqFfvt1 X-Received: by 2002:a17:902:ecc3:b0:188:59d2:33e with SMTP id a3-20020a170902ecc300b0018859d2033emr1787864plh.142.1668677414059; Thu, 17 Nov 2022 01:30:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668677414; cv=none; d=google.com; s=arc-20160816; b=wr7OEUib0SQ7r4NItlIlCI1PDXnVzTAAWPMrXTcjbxZ2PbmajRQVmfDpGg2s69rdeN j4+VbQygN0xp956G8JH521qSNZXh3vNW6fPbzmkGC6vxjd8VSshmC9GGvggGy1EuproZ xa5Qiw40lHaNgy0CZK+rKB2k9fFGbL5y6lkL4D63BtywbMHMbkfylT18EI9bW85ZkbK9 pxQQGR2LMezUfBCwQ07JsOdt1CvZZJEipJCySNqjhIiw4t/YRI4qX92IlwWbU6JXb43I BFOpFp+j4oL7KAJDw2ocRAZcdCtzry7nMn7iJie+FKnisjPrLJw1zUO3vQtXS0MwKG9u PrMw== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=2i8ue32zbAB2L5zW+f/v6ja22a6vjPgIueav6O2jRPg=; b=h7HM/ITZ8bXcdnJbnaW/kvvSl+tWKmkFqSnSaLOf94CkpBdMJgwdXFhtBYrEe9fVWH WG48sQ/yU0NUJfBun0B3cD0FQKpZH0xhFDF9YoqZqnWpgv19TEXOb8KVOxIz9Rj8lUCy +QsTAAtl8RQfmmFapjZK/g4Brk8GAwFzVBWUMuyEQerH9DyPvZqBIlDZydFf/YoGYS12 gWXQgJVCEBBWsJiVcnKS1fa3oAmCg4FmXI0br6WkxtRsmlXcZWq/Qn0bwRNFsFHRSPVE Il+7wAJiF+XnpZ2U2JIyH5YxObTg8pk66ZsI/hjOS+56TyGS1Lt/4s5X+mIHb4gYM3/1 crIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=PFAKG40V; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bk13-20020a056a02028d00b00470422012f6si464005pgb.687.2022.11.17.01.30.01; Thu, 17 Nov 2022 01:30:14 -0800 (PST) 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=@mediatek.com header.s=dk header.b=PFAKG40V; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239899AbiKQJZl (ORCPT <rfc822;just.gull.subs@gmail.com> + 99 others); Thu, 17 Nov 2022 04:25:41 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48772 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239267AbiKQJZJ (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 17 Nov 2022 04:25:09 -0500 Received: from mailgw01.mediatek.com (unknown [60.244.123.138]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F0FFC7656; Thu, 17 Nov 2022 01:25:05 -0800 (PST) X-UUID: 9d4c971178fc4c6392487e0b8f157fb8-20221117 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Type:Content-Transfer-Encoding:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=2i8ue32zbAB2L5zW+f/v6ja22a6vjPgIueav6O2jRPg=; b=PFAKG40Vd32WWsTq+f5SipqSe6RDKWFcRVv0OamftBF6HwSO+/PMs2qEpA1gvCn2vHcaS9BCbF7yd8DYdPjqGYGb5Zu1ueq81K4v4Apb44GpXDzPT+SC7FXhUyZ58DSMwbc1YqlPu8YlSNvmr2QlX1qyApuVoOJrKUF0wGedZ9U=; X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.13,REQID:3371898b-ad19-4ed9-aab4-4732f3087482,IP:0,U RL:0,TC:0,Content:0,EDM:0,RT:0,SF:95,FILE:0,BULK:0,RULE:Release_Ham,ACTION :release,TS:95 X-CID-INFO: VERSION:1.1.13,REQID:3371898b-ad19-4ed9-aab4-4732f3087482,IP:0,URL :0,TC:0,Content:0,EDM:0,RT:0,SF:95,FILE:0,BULK:0,RULE:Spam_GS981B3D,ACTION :quarantine,TS:95 X-CID-META: VersionHash:d12e911,CLOUDID:55f976db-6ad4-42ff-91f3-18e0272db660,B ulkID:221117172503CT5CQNLZ,BulkQuantity:0,Recheck:0,SF:38|28|17|19|48,TC:n il,Content:0,EDM:-3,IP:nil,URL:0,File:nil,Bulk:nil,QS:nil,BEC:nil,COL:0 X-UUID: 9d4c971178fc4c6392487e0b8f157fb8-20221117 Received: from mtkmbs10n1.mediatek.inc [(172.21.101.34)] by mailgw01.mediatek.com (envelope-from <yunfei.dong@mediatek.com>) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-GCM-SHA384 256/256) with ESMTP id 240677237; Thu, 17 Nov 2022 17:25:03 +0800 Received: from mtkmbs13n1.mediatek.inc (172.21.101.193) by mtkmbs13n2.mediatek.inc (172.21.101.108) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.792.15; Thu, 17 Nov 2022 17:25:01 +0800 Received: from localhost.localdomain (10.17.3.154) by mtkmbs13n1.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.2.792.15 via Frontend Transport; Thu, 17 Nov 2022 17:25:00 +0800 From: Yunfei Dong <yunfei.dong@mediatek.com> To: Yunfei Dong <yunfei.dong@mediatek.com>, Chen-Yu Tsai <wenst@chromium.org>, Nicolas Dufresne <nicolas@ndufresne.ca>, Hans Verkuil <hverkuil-cisco@xs4all.nl>, AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>, Benjamin Gaignard <benjamin.gaignard@collabora.com>, Tiffany Lin <tiffany.lin@mediatek.com> CC: Mauro Carvalho Chehab <mchehab@kernel.org>, Matthias Brugger <matthias.bgg@gmail.com>, George Sun <george.sun@mediatek.com>, Xiaoyong Lu <xiaoyong.lu@mediatek.com>, Hsin-Yi Wang <hsinyi@chromium.org>, Fritz Koenig <frkoenig@chromium.org>, Daniel Vetter <daniel@ffwll.ch>, Steve Cho <stevecho@chromium.org>, <linux-media@vger.kernel.org>, <devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>, <linux-arm-kernel@lists.infradead.org>, <linux-mediatek@lists.infradead.org>, <Project_Global_Chrome_Upstream_Group@mediatek.com> Subject: [PATCH v2,5/5] media: mediatek: vcodec: Core thread depends on core_list Date: Thu, 17 Nov 2022 17:24:53 +0800 Message-ID: <20221117092453.31366-6-yunfei.dong@mediatek.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221117092453.31366-1-yunfei.dong@mediatek.com> References: <20221117092453.31366-1-yunfei.dong@mediatek.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-MTK: N X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, SPF_PASS,UNPARSEABLE_RELAY 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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749735088427985894?= X-GMAIL-MSGID: =?utf-8?q?1749735088427985894?= |
Series |
media: mediatek: vcodec: Fix decode random crash for PLT test
|
|
Commit Message
Yunfei Dong (董云飞)
Nov. 17, 2022, 9:24 a.m. UTC
Core thread will continue to work when core_list is not empty, not depends on lat_list. Fixes: 365e4ba01df4 ("media: mtk-vcodec: Add work queue for core hardware decode") Signed-off-by: Yunfei Dong <yunfei.dong@mediatek.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> --- drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c b/drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c index ae500980ad45..dc2004790a47 100644 --- a/drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c +++ b/drivers/media/platform/mediatek/vcodec/vdec_msg_queue.c @@ -221,7 +221,7 @@ static void vdec_msg_queue_core_work(struct work_struct *work) mtk_vcodec_dec_disable_hardware(ctx, MTK_VDEC_CORE); vdec_msg_queue_qbuf(&ctx->msg_queue.lat_ctx, lat_buf); - if (!list_empty(&ctx->msg_queue.lat_ctx.ready_queue)) { + if (!list_empty(&dev->msg_queue_core_ctx.ready_queue)) { mtk_v4l2_debug(3, "re-schedule to decode for core: %d", dev->msg_queue_core_ctx.ready_num); queue_work(dev->core_workqueue, &msg_queue->core_work);