From nobody Sun Feb 8 18:31:10 2026 Received: from e2i340.smtp2go.com (e2i340.smtp2go.com [103.2.141.84]) (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 2FFE13D6694 for ; Wed, 21 Jan 2026 20:13:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=103.2.141.84 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769026441; cv=none; b=s/DyNByf9UK7dt+LcNDKIci3gbJTOwnw672isfCla9B1/PsOBc0onKrraJ2/Sw0aivwk6CNKq1FaecvwQnpy/iwrCdzI7UjRy94ThFc2hra2Zt22fqF2Wm4H0g+V0IlD9otBKNCSSoi5VyHxTyR6aAZEZCD6dtOb1AQwJauX5pY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769026441; c=relaxed/simple; bh=MI2BmTqtZrNSQrlrrLbu/L5u8kVcj0qImD2nnPGSwwo=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=HZ2e9d2hXhn+ORoAkEQZcT4PJhY3yWNLUQPped+iDcYuJAASwKEpe9wfILtWwPo6bVi7Y2hGp8LjnvTa36DnjCkka5PtIfRmywzcxKd4DjzzT2yS+Q3rIU/c1W5MoGUco006/5MVU3iiQWUvTh30RRHDfuygAyFb0SqfHSiNx/o= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=triplefau.lt; spf=pass smtp.mailfrom=em510616.triplefau.lt; dkim=fail (0-bit key) header.d=smtpservice.net header.i=@smtpservice.net header.b=MfeRhre4 reason="unknown key version"; dkim=pass (2048-bit key) header.d=triplefau.lt header.i=@triplefau.lt header.b=evPn6BU4; arc=none smtp.client-ip=103.2.141.84 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=triplefau.lt Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=em510616.triplefau.lt Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="unknown key version" (0-bit key) header.d=smtpservice.net header.i=@smtpservice.net header.b="MfeRhre4"; dkim=pass (2048-bit key) header.d=triplefau.lt header.i=@triplefau.lt header.b="evPn6BU4" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=smtpservice.net; s=maxzs0.a1-4.dyn; x=1769027340; h=Feedback-ID: X-Smtpcorp-Track:Message-ID:Date:Subject:To:From:Reply-To:Sender: List-Unsubscribe:List-Unsubscribe-Post; bh=T3TZwnO8y1oxOvrH2YQS/n2Bl9vhGxNTqyNbInimA3Q=; b=MfeRhre4nF/w+u5fEuSxaaNixL fyadY9bI4XhJpDmvBCa6MUeXSsD7pnqYa2IPXdzL7vKDauKZdC1wtRTLGmt3EJyXObzo/ONee87SV ezKyiskkt6UrZSVGeC0dX6m3UmTDfX8Wi/t8ovwKSMIc2rE/hZ02PLMlSNktvBhzyxht2TIAAT/xp yKQ2rHOmzMQzsy2z/RJ7Jebud6nq7E+TGh5+spZm2CtzipEXmJOJucXlcPin5Q2eFoT1gz5S5wHtI YEKVuiOQzox+iIiRZGQrKRCzAiT+4ANs+fawL6RIrHekA3rnPGw5zNj0wV8J9G8BtuaDs/Y5JVCXg l1OKViXw==; DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=triplefau.lt; i=@triplefau.lt; q=dns/txt; s=s510616; t=1769026440; h=from : subject : to : message-id : date; bh=T3TZwnO8y1oxOvrH2YQS/n2Bl9vhGxNTqyNbInimA3Q=; b=evPn6BU4N6MkN7lIh/N37fs4dcS6GOrLoBkVyz1TIOuvx3OqO4+uP//kv8eDkC1hxqIrB WsFZSjliK+EhRCZzPN6nR4FZP6MMjPjHOfrG0dt+zscTO+aWU637JnFkE2cNX3ZsUrnc3mD IHy3gZX9hCmJebfGWm8Y+wJZV+gOy0vflzKzlRplkVsgz9If4q7KjuCzG7vOqBCOuq4k1uN fJy+MIT6KqHy81MWrTs2TOEyeCual60v7UpltR9IPvkLVi1xOKN2vsKQC7oNAbECyRPtQ1U ODcxn2gzaNPyfwsMC+SVQXcAyr7NDttzIFhmxym0em/sktUjkOw+he+JDCxg== Received: from [10.139.162.187] (helo=SmtpCorp) by smtpcorp.com with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.94.2-S2G) (envelope-from ) id 1vieaL-TRk28y-OL; Wed, 21 Jan 2026 20:13:49 +0000 Received: from [10.12.239.196] (helo=localhost) by smtpcorp.com with esmtpsa (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.98.1-S2G) (envelope-from ) id 1vieaL-4o5NDgrlA5K-l5yO; Wed, 21 Jan 2026 20:13:49 +0000 From: Remi Pommarel To: v9fs@lists.linux.dev Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Eric Van Hensbergen , Latchesar Ionkov , Dominique Martinet , Christian Schoenebeck , Remi Pommarel Subject: [PATCH v2 2/3] 9p: Introduce option for negative dentry cache retention time Date: Wed, 21 Jan 2026 20:56:09 +0100 Message-ID: <7e38e7bd31674208ab2b0de909c0744feda2c03f.1769013622.git.repk@triplefau.lt> X-Mailer: git-send-email 2.50.1 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Smtpcorp-Track: dESi4y2bpk5E.Vr1dGdwNkxoC.pRDBTAd6cPk Feedback-ID: 510616m:510616apGKSTK:510616szNUyQSrVu X-Report-Abuse: Please forward a copy of this message, including all headers, to Content-Type: text/plain; charset="utf-8" Add support for a new mount option in v9fs that allows users to specify the duration for which negative dentries are retained in the cache. The retention time can be set in milliseconds using the ndentrytmo option. For the same consistency reasons, this option should only be used in exclusive or read-only mount scenarios, aligning with the cache=3Dloose usage. Signed-off-by: Remi Pommarel --- fs/9p/v9fs.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/fs/9p/v9fs.c b/fs/9p/v9fs.c index 1da7ab186478..f58a2718e412 100644 --- a/fs/9p/v9fs.c +++ b/fs/9p/v9fs.c @@ -39,7 +39,7 @@ enum { * source if we rejected it as EINVAL */ Opt_source, /* Options that take integer arguments */ - Opt_debug, Opt_dfltuid, Opt_dfltgid, Opt_afid, + Opt_debug, Opt_dfltuid, Opt_dfltgid, Opt_afid, Opt_ndentrytmo, /* String options */ Opt_uname, Opt_remotename, Opt_cache, Opt_cachetag, /* Options that take no arguments */ @@ -93,6 +93,7 @@ const struct fs_parameter_spec v9fs_param_spec[] =3D { fsparam_string ("access", Opt_access), fsparam_flag ("posixacl", Opt_posixacl), fsparam_u32 ("locktimeout", Opt_locktimeout), + fsparam_s32 ("ndentrytmo", Opt_ndentrytmo), =20 /* client options */ fsparam_u32 ("msize", Opt_msize), @@ -159,6 +160,8 @@ int v9fs_show_options(struct seq_file *m, struct dentry= *root) from_kgid_munged(&init_user_ns, v9ses->dfltgid)); if (v9ses->afid !=3D ~0) seq_printf(m, ",afid=3D%u", v9ses->afid); + if (v9ses->ndentry_timeout !=3D 0) + seq_printf(m, ",ndentrytmo=3D%d", v9ses->ndentry_timeout); if (strcmp(v9ses->uname, V9FS_DEFUSER) !=3D 0) seq_printf(m, ",uname=3D%s", v9ses->uname); if (strcmp(v9ses->aname, V9FS_DEFANAME) !=3D 0) @@ -337,6 +340,10 @@ int v9fs_parse_param(struct fs_context *fc, struct fs_= parameter *param) session_opts->session_lock_timeout =3D (long)result.uint_32 * HZ; break; =20 + case Opt_ndentrytmo: + session_opts->ndentry_timeout =3D result.int_32; + break; + /* Options for client */ case Opt_msize: if (result.uint_32 < 4096) { --=20 2.50.1