From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f68.google.com (mail-wm1-f68.google.com [209.85.128.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0B72428980F for ; Thu, 19 Feb 2026 10:18:42 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.68 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771496325; cv=none; b=ukPC1NWkCrfwKbX3SMjRRxByqRUcq7r4nN0N92W5HqqVzmreqzWiAyTpWWHy8+qq25PO4bsgzAls72dqHhGUF+mrA5VLB2rmYvUeKa9qJm2zINmXyqGncYd8bFJEyHT/jfzYijr8u9VmseOyYs9YNzlguH+MSXtKB7Trj8v7IGI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1771496325; c=relaxed/simple; bh=wzh55W09PaCWhWdIbCT91GweQa2ZaySnkVYjZLUYTW0=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=TNXI3JeBgMjJtxeSW4zUpMdNrUWSebqZYlbrLM0bBnN9kA4rp09FGqyxzt/fm/ssgl9BR//F8KUMnN6LbQHyPQS8vLCd5pcJ3LdCrcB2o81Mm2xv4J9iFWW6fDkJylRr7cMtTnPv3xEg/RKU2sEsg+g8kTU2AUdBN0WUhzHEZqs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=WvtTILJD; arc=none smtp.client-ip=209.85.128.68 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="WvtTILJD" Received: by mail-wm1-f68.google.com with SMTP id 5b1f17b1804b1-483770e0b25so7860955e9.0 for ; Thu, 19 Feb 2026 02:18:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1771496321; x=1772101121; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:from:to:cc:subject:date:message-id :reply-to; bh=YYel7EaCkaihWct+rkFi+N7PaNErw8Up6SMIw3SlfbM=; b=WvtTILJDNLci1vc/aJqlOXrlKUWTe95uY2alHtnHlEcjv6KYNqegMwTyssFq8Ky5uN 3iGpydkzOCwJqBruKg0lHW4+cNjibW1kszXXvG1UH279WrCV5MIJrwbsYofBc6XtHqid bo2A7lsdu7a2GfrZf8+e1IyiUNoVDz1JKs2+7mqm5I18zXEDzfFjuZ3f4+T5JRb6v94c CgIOTMCp+pwn31SeW8+l5TnbpRMnvYStZExPsjWKSwK9JPhzdIxVdGkNgkZZ7xRk3g4t /He2vO6JZfvmmXc9yVBd8JJXQpg7eP6GIPiMw+pI0Ot8fgq6MEP2lncKk939VPixtKHZ Xzsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1771496321; x=1772101121; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:x-gm-gg:x-gm-message-state:from:to :cc:subject:date:message-id:reply-to; bh=YYel7EaCkaihWct+rkFi+N7PaNErw8Up6SMIw3SlfbM=; b=hbGbZOPTjLlP1A+oONZdxnaAfr8nof4gOSPykb6Fb1f9Xyd76xUIJ+4vxYAqEelxcU w9fRQ/nPF2rbrsOhqrfRB17ffGrIlzZ8LfZodKYrxsOlgPj22TiMDv0HMr1lvYl6FgcG oLOCwKxP41ccLfk36KIgx8oLMDNdvK2au6Gk44pS49r4NgKE2gAswSGAI7jePPfeKIl4 VlORZjCyj8ewpZox7vYSqT4ZK5GPzcKYhxoLtnkih1OvJYbUaGoeWFYWQc14fnMHq49n TGSOrdQ/u0ccy9aQEp0pdi/I/rKQHsBGaCeKVDvG51+bTG+ZoIgGa/jeBKBt7zGZnzkL YL0w== X-Forwarded-Encrypted: i=1; AJvYcCWrB7PD5vMtMKfANz8woQAowwQe/5RLRdY4rK9Y7HdMQvYjtOM5X9NWMMW3q5pLH1ScgM36KddKSpUWrik=@vger.kernel.org X-Gm-Message-State: AOJu0YzPGEqSoe8GKH0uc6iuedr6CXrw9F0Lv0VedQ0ENgfnTwBPJL5n 8A5MBClMjTdD+ZcXaSXiI2XPZ4uq07uOwl7zGeptnaJDXexNLX4pmOUP X-Gm-Gg: AZuq6aJrnQI3p+621U4SNOUok5vd3OPTAJHtcwkKUsndALgrooMzZlZoNtmLR6aPuhV SXokVmj4l+9AgPTFbFuGSyINym1giDhw9F3/NJWsW5C+z8AKt64FQsSWGygBMOqMrKtE9OAVGQk FKVaWm/dkH7uCr/q6kPGyrtdnjJSGNcRDL0pHXYDjPud6sNihZZd3ZkHisKa/L5pRTnbJhYXRo+ 4PBPog/cscH+H9Nv3b7AHIPDITnswQW1dYjM6T9ijhuSpLj/TMeUhPjNkVuuiWM2JJKJChb3iGQ DvO5pjfuHUAuD1srApx85vyf6A0Vme9M9AS2ZZzjFzSoribk6lAR+v3qnMoNKW5xIxIn7iiSoKS 8tRNOSzkgihbp5fi+6xdtGayPx+TgaiSKM9ploQyHIqdd6NJSeJkkRsZMYTO3LzPI47BcGY07mD o3qh4fMCVeAE3EG9Z1Jcp/mdbPFzpE/bHEXRbgBBez3Tzx8R2QqzmhcKYz1iEFa18G X-Received: by 2002:a05:600c:6912:b0:483:709e:f22d with SMTP id 5b1f17b1804b1-4837108fc46mr349815445e9.27.1771496321068; Thu, 19 Feb 2026 02:18:41 -0800 (PST) Received: from Abds-MacBook-Air.local ([2a02:3037:201:298a:fcf6:596:46c1:61a2]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4839f95ab0asm20672715e9.7.2026.02.19.02.18.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 Feb 2026 02:18:40 -0800 (PST) From: Abd-Alrhman Masalkhi To: Thomas =?utf-8?Q?Wei=C3=9Fschuh?= Cc: dwlsalmeida@gmail.com, mchehab@kernel.org, linmag7@gmail.com, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, syzbot+96f901260a0b2d29cd1a@syzkaller.appspotmail.com Subject: Re: [PATCH] media: vidtv: fix uninitialized args.buf_sz passed by value In-Reply-To: <20260218141123-d54e3a23-c3dc-4ce7-8a8f-1d77fa4c7960@linutronix.de> References: <20260216211703.3702-1-abd.masalkhi@gmail.com> <20260218141123-d54e3a23-c3dc-4ce7-8a8f-1d77fa4c7960@linutronix.de> Date: Thu, 19 Feb 2026 11:17:55 +0100 Message-ID: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On Wed, Feb 18, 2026 at 14:24 +0100, Thomas Wei=C3=9Fschuh wrote: Hi Thomas, Thank you for the feedback. > Hi Abd-Alrhman! > > On Mon, Feb 16, 2026 at 10:17:03PM +0100, Abd-Alrhman Masalkhi wrote: >> vidtv_ts_null_write_into() takes null_packet_write_args by value, >> causing MSAN to report an uninit-value warning on buf_sz inside >> the function. >>=20 >> Fix by passing the struct by pointer instead, avoiding the stack copy >> entirely. >>=20 >> Reported-by: syzbot+96f901260a0b2d29cd1a@syzkaller.appspotmail.com >> Closes: https://syzkaller.appspot.com/bug?extid=3D96f901260a0b2d29cd1a >> Fixes: cd7a5651db26 ("alpha: add missing address argument in call to pag= e_table_check_pte_clear()") > > The Fixes tag should point to the commit which originally introduced > the issue that is being fixed. My commit for alpha-specific code is > unlikely to be the root cause because a) syscaller is not running alpha > systems and b) the first occurrence of the syscaller was before my patch > was picked up by Linus. So please try to find a better Fixes tag. > I will fix the Fixes tag to point to the correct vidtv commit. >> Signed-off-by: Abd-Alrhman Masalkhi >> --- >> drivers/media/test-drivers/vidtv/vidtv_mux.c | 2 +- >> drivers/media/test-drivers/vidtv/vidtv_ts.c | 18 +++++++++--------- >> drivers/media/test-drivers/vidtv/vidtv_ts.h | 2 +- >> 3 files changed, 11 insertions(+), 11 deletions(-) >>=20 >> diff --git a/drivers/media/test-drivers/vidtv/vidtv_mux.c b/drivers/medi= a/test-drivers/vidtv/vidtv_mux.c >> index f99878eff7ac..67a580396112 100644 >> --- a/drivers/media/test-drivers/vidtv/vidtv_mux.c >> +++ b/drivers/media/test-drivers/vidtv/vidtv_mux.c >> @@ -363,7 +363,7 @@ static u32 vidtv_mux_pad_with_nulls(struct vidtv_mux= *m, u32 npkts) >> args.continuity_counter =3D &ctx->cc; >>=20=20 >> for (i =3D 0; i < npkts; ++i) { >> - m->mux_buf_offset +=3D vidtv_ts_null_write_into(args); >> + m->mux_buf_offset +=3D vidtv_ts_null_write_into(&args); > > Please explain in the commit message why this is change is safe to do. > Modifying shared data might break the logic. (I have not verified this) > vidtv_ts_null_write_into() only reads from the struct and does not modify it. should I add a const qualifier to the parameter?=20 >> args.dest_offset =3D m->mux_buf_offset; >> } > > (...) > > Did have syscaller test this patch before submission? > See the following documentation from the report: > > If you want syzbot to run the reproducer, reply with: > #syz test: git://repo/address.git branch-or-commit-hash > If you attach or paste a git patch, syzbot will apply it before testing. > I will test with syzbot before sending v2. > > Thomas --=20 Best Regards, Abd-Alrhman