From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7F4FE2D5937; Sun, 1 Mar 2026 01:40:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772329242; cv=none; b=hsZ4NniZpILOO1mdMfq0683kiOxTumWuzhussPe1jY4Z1eZez8wpe6SfCo1mfNXnPOdmdhT/5h/xgxICfORcmM2wfQky/046t6W90vCsExdC85DG/vJ0rPnRYN25BTWdqt+yJ8vQTTZnIKne2FyxAmy0E7rE3cOqRFLFkh/A7Mg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772329242; c=relaxed/simple; bh=T5soqHnJuWQ3SUhbSLtaP2ZBFGoEf+2X0YiZq/yfNaU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=bPzRqVBDTzgVNpm8ANg3EANaOmtZwjKRwLpCFkeRD1MYHqQlSar0pd2SQzUVdiIH30g9QyEDOtYKLo1+r4fI2px9HZ/XP//D/CtXseDlNqYPGy/aEbzDTn5b1f2YlQ1PFT0EtBNsKDEf4i19PiHWHmcSJbLIeEQBRExM8ZJ7RRo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Uw5Jhjid; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Uw5Jhjid" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 85B7BC19421; Sun, 1 Mar 2026 01:40:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1772329242; bh=T5soqHnJuWQ3SUhbSLtaP2ZBFGoEf+2X0YiZq/yfNaU=; h=From:To:Cc:Subject:Date:From; b=Uw5JhjidBIXkNYbGkIhRCMG0rEolqDOyK8/XhrZ85sptj+lLb5u/O3IeAFnp3WXYO Hpt+Jj3XkyAyhlgdVT5Fj7f4Kpif5rx4bS6UW7MwrK9eWVg7nWzeFwFEd+p+Cyjn26 6xt9FLRhq7HtYuvk0ufqIsOpI9+8rLjVpD9zGQwtCkiGwJRExuhb2TrQuipTYtCw/V DApKFvN7h34KaxoldId/c+/wUGB89zLfIsghPrrupga7yopFq6tsLaqtqITqFtjaTi msDcL8fRxfXNh8zOocxJPFelJEgeNPAyjdT6rbLZWu+vv3Nw6K0VVkLO7k9NnXJpb/ rgEt9BHflGr/A== From: Sasha Levin To: stable@vger.kernel.org, irui.wang@mediatek.com Cc: AngeloGioacchino Del Regno , Nicolas Dufresne , Hans Verkuil , linux-media@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org Subject: FAILED: Patch "media: mediatek: encoder: Fix uninitialized scalar variable issue" failed to apply to 6.1-stable tree Date: Sat, 28 Feb 2026 20:40:40 -0500 Message-ID: <20260301014040.1701969-1-sashal@kernel.org> X-Mailer: git-send-email 2.51.0 Precedence: bulk X-Mailing-List: linux-media@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Patchwork-Hint: ignore X-stable: review Content-Transfer-Encoding: 8bit The patch below does not apply to the 6.1-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . Thanks, Sasha ------------------ original commit in Linus's tree ------------------ >From 88e935de7cf8795d7a6a51385db87ecb361a7050 Mon Sep 17 00:00:00 2001 From: Irui Wang Date: Sun, 7 Sep 2025 17:35:56 +0800 Subject: [PATCH] media: mediatek: encoder: Fix uninitialized scalar variable issue UNINIT checker finds some instances of variables that are used without being initialized, for example using the uninitialized value enc_result.is_key_frm can result in unpredictable behavior, so initialize these variables after declaring. Fixes: 4e855a6efa54 ("[media] vcodec: mediatek: Add Mediatek V4L2 Video Encoder Driver") Cc: stable@vger.kernel.org Signed-off-by: Irui Wang Reviewed-by: AngeloGioacchino Del Regno Signed-off-by: Nicolas Dufresne Signed-off-by: Hans Verkuil --- .../media/platform/mediatek/vcodec/encoder/mtk_vcodec_enc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/media/platform/mediatek/vcodec/encoder/mtk_vcodec_enc.c b/drivers/media/platform/mediatek/vcodec/encoder/mtk_vcodec_enc.c index 6faf3f659e751..b3a0a1d8b7a8e 100644 --- a/drivers/media/platform/mediatek/vcodec/encoder/mtk_vcodec_enc.c +++ b/drivers/media/platform/mediatek/vcodec/encoder/mtk_vcodec_enc.c @@ -850,7 +850,7 @@ static void vb2ops_venc_buf_queue(struct vb2_buffer *vb) static int vb2ops_venc_start_streaming(struct vb2_queue *q, unsigned int count) { struct mtk_vcodec_enc_ctx *ctx = vb2_get_drv_priv(q); - struct venc_enc_param param; + struct venc_enc_param param = { }; int ret; int i; @@ -1004,7 +1004,7 @@ static int mtk_venc_encode_header(void *priv) int ret; struct vb2_v4l2_buffer *src_buf, *dst_buf; struct mtk_vcodec_mem bs_buf; - struct venc_done_result enc_result; + struct venc_done_result enc_result = { }; dst_buf = v4l2_m2m_dst_buf_remove(ctx->m2m_ctx); if (!dst_buf) { @@ -1125,7 +1125,7 @@ static void mtk_venc_worker(struct work_struct *work) struct vb2_v4l2_buffer *src_buf, *dst_buf; struct venc_frm_buf frm_buf; struct mtk_vcodec_mem bs_buf; - struct venc_done_result enc_result; + struct venc_done_result enc_result = { }; int ret, i; /* check dst_buf, dst_buf may be removed in device_run -- 2.51.0