From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-180.mta1.migadu.com (out-180.mta1.migadu.com [95.215.58.180]) (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 6EBB772628 for ; Wed, 3 Dec 2025 02:05:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.180 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764727521; cv=none; b=gYWFK8uG2fYcK3YAXZXqJXE0wyygGDK13KZSbWLmPirGLp+Jbrm2tXHGW4BvLESn8JOZGNwy0T/7QQ6GAacPSTFPv/C8bSiDPN76ScpoSK0npNYpkFXq1/DjhbI3Az8/PUpskaaJtMXwRW/ltFDhhFwyWf+N6BCM1T9Vgh/jzEs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764727521; c=relaxed/simple; bh=FPy21LS9S9ludFgcJ2xXTrctbrNoQvJ7KLCEgrlMWY4=; h=MIME-Version:Date:Content-Type:From:Message-ID:Subject:To:Cc: In-Reply-To:References; b=AkyxonXVTM2rxgtNqWnb+381hkHKcsq5P15DQRtg97AeoI2AqSoLCuKYru6Fum/9RVly4TM7FdM/GIjHG3zCg9nLSNgob5fbuiGzkO8SXm05uILV/ddSmvm6tZW560BZ9Y0Vc2xj6X6wFBNvGC8XpJxl3oqLHCaFZiGSNUtCPKY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=U7HNZreu; arc=none smtp.client-ip=95.215.58.180 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="U7HNZreu" Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1764727517; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=FPy21LS9S9ludFgcJ2xXTrctbrNoQvJ7KLCEgrlMWY4=; b=U7HNZreuY+SKQM4W2W/A4RDpj/eYJW4S4KdiwUKujs4SG+sE5YtcwoncbbuHqaRF1t/ign lIUXuLv8OH8xhDENOskVZGWWbSSmgxxvdsr1yqOudR9eJYxTlTREjDgHklusmUfdQaoDLX NmWZ6xagQosAiKFHOVuevF5ozfke8VM= Date: Wed, 03 Dec 2025 02:05:11 +0000 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: "Jiayuan Chen" Message-ID: TLS-Required: No Subject: Re: [PATCH v1] mm/kasan: Fix incorrect unpoisoning in vrealloc for KASAN To: "Maciej Wieczor-Retman" Cc: linux-mm@kvack.org, syzbot+997752115a851cb0cf36@syzkaller.appspotmail.com, "Andrey Ryabinin" , "Alexander Potapenko" , "Andrey Konovalov" , "Dmitry Vyukov" , "Vincenzo Frascino" , "Andrew Morton" , "Uladzislau Rezki" , "Danilo Krummrich" , "Kees Cook" , kasan-dev@googlegroups.com, linux-kernel@vger.kernel.org In-Reply-To: References: <20251128111516.244497-1-jiayuan.chen@linux.dev> X-Migadu-Flow: FLOW_OUT December 3, 2025 at 04:48, "Maciej Wieczor-Retman" wrote: >=20 >=20Hi, I'm working on [1]. As Andrew pointed out to me the patches are q= uite > similar. I was wondering if you mind if the reuse_tag was an actual tag= value? > Instead of just bool toggling the usage of kasan_random_tag()? >=20 >=20I tested the problem I'm seeing, with your patch and the tags end up = being reset. > That's because the vms[area] pointers that I want to unpoison don't hav= e a tag > set, but generating a different random tag for each vms[] pointer crash= es the > kernel down the line. So __kasan_unpoison_vmalloc() needs to be called = on each > one but with the same tag. >=20 >=20Arguably I noticed my series also just resets the tags right now, but= I'm > working to correct it at the moment. I can send a fixed version tomorro= w. Just > wanted to ask if having __kasan_unpoison_vmalloc() set an actual predef= ined tag > is a problem from your point of view? >=20 >=20[1] https://lore.kernel.org/all/cover.1764685296.git.m.wieczorretman@= pm.me/ >=20 Hi=20Maciej, It seems we're focusing on different issues, but feel free to reuse or mo= dify the 'reuse_tag'. It's intended to preserve the tag in one 'vma'. I'd also be happy to help reproduce and test your changes to ensure the i= ssue I encountered isn't regressed once you send a patch based on mine.=20 Thanks.