Received: by 2002:ab2:6203:0:b0:1f5:f2ab:c469 with SMTP id o3csp2890545lqt; Tue, 23 Apr 2024 05:04:43 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWHGc0dgEqOFTgFqpE0RClQEl9IHEtnHygO9MdEhKhuCDUAKQel+7KbHbFMRd4dUiTJIddnZ/b2b7I0cQrqtewLx5eYlR5lgcDfCEq1rw== X-Google-Smtp-Source: AGHT+IFF1p/j/MAynLdgD8tAdGLj+lUQscvQjaF/Uq0wfsbGcX+qxlDe1e8xqe45c4zk3VCTkzXm X-Received: by 2002:a05:6a20:a126:b0:1a3:bdd5:41f6 with SMTP id q38-20020a056a20a12600b001a3bdd541f6mr13940236pzk.61.1713873882836; Tue, 23 Apr 2024 05:04:42 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713873882; cv=pass; d=google.com; s=arc-20160816; b=Fm+UErM4rlMSI0/Z4THpx9nPyMJrXnYov3ciSojAPdEWUdx/wMqXPHh/M93a55XSK4 VK0TRxlGzsrN6NezJ+fQ5XHwkYBZFd2bOo2sst+/BskA/HtmodmvICxWxbN4h5oWy0gI RySNyg1ZGLbXxSXX2Uft90NDvvhftjm0bjs/KbxIdgL+4Qwn7grG+X4EBoSMjhwG9Nd4 FcUM7nxxYm+tpxwi9O27cO6SoLY/dxHyOeIT3S91hXDvTtmCI24kUfo9rS/agzcyy3md zpA4GgLm7OMno3HH6Vot3vVssm8nIwEgRTrga49ztTL2qgFcn6GEej+b+xGhdfXCV/ML r+2Q== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=U60A1adnXA4X0ZTWUC5yEv7EzuRpHmAicQ5kx3ltGws=; fh=o7JW3XEC2efOVXuv3tQtKSSwzldTk0goJRV188eMJaI=; b=KB/4WXfxS8gNW3jI+2sXZ818h2EHmxwRcIfL+89jGq5A/cftJLovu5k5zjGzCol3HJ abMn3wvdFQs7/jo1u7DqRh74CpONnxyb3x2UpTagegxzigh64D+NKmOFPo2lwbDX+Ipw 3CIXhlk6gbqai2NiKoFxVaktq/BducnQIuzUcLtDiaD/33G1j8i3VcQ8h1UTWkzO7ZOc JaNLn8xxlI38BMyllIsxNtFr5VfzfHTRC9v2heIr3wTaDEulMxzCrIm/06y1sgtK6Pvw wQ0Ges3xjiaK40SvtjKnX2cEXm3TUggPJJU2jng36xfUEt6qpVZXxiwXSY3FaDVx2OV/ B3eg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="VUDTgF/6"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-155066-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-155066-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id u17-20020a056a00125100b006e6b6c501d5si9725735pfi.21.2024.04.23.05.04.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Apr 2024 05:04:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-155066-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="VUDTgF/6"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-155066-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-155066-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id D716CB26669 for ; Tue, 23 Apr 2024 11:53:13 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 248E014601D; Tue, 23 Apr 2024 11:41:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="VUDTgF/6" 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 452CE145B3A; Tue, 23 Apr 2024 11:41:35 +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=1713872495; cv=none; b=nTKYIjgrngmKORf948BRUaICHFIWZfCkp27IC/vveARyZN1oaDiixyHN2pdqFhP2nH7/dpY2uxYVGSX3VLgjAi5jh+VFHs4bnHvCICx6DdqkMFApVqOv1z92MMcO+MIo/fmW4WHfUfi/5NadV01byHYL0k8iKZrt+PmVJJQkrKw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713872495; c=relaxed/simple; bh=VE4wcJTbyxXeQUs7x/VihBeQ43jxTlnj1Q0QvS/i3P0=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=QZvtrqS6i3IH4erX1HB1IB4JTnRbzHkpEl9I8xhL6WPPsJ67+Nwj9oPxMJIDuxjprg/KCsp77CVVc0/Up5gXXew9raeCN2Ei8Sm/NY6tiIwJsQzbKvX2wCuMsYXtCFRj3xDFSrrSJboInXcbyY1JABVfaQRSqlxe3p1TUduF7hc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=VUDTgF/6; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3CB83C32783; Tue, 23 Apr 2024 11:41:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1713872495; bh=VE4wcJTbyxXeQUs7x/VihBeQ43jxTlnj1Q0QvS/i3P0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VUDTgF/6Q3FO7qEK+4AZhOSP7b/pMhYtf7+bo/6XDwPSLF6Rg+1QF22UD7C/1wYbX 8CIT1EL8ymT5SOmdNMYULjkK/V47fjvRvFDF3Q0utWFZpO0hTiCtWkDwTWZPYC8XMs Jz771Ae0x1U3rpxEL0VTkTXID3V2GmF6oZ4eVxKVbJ3rxKbg6UY/oZfUeIzKI3gi3H tJCXi4He4Brl/oFtaFhlBnL/eQ6Jr9K/Rqnysp5KrjUAakRGX9e7bPjSbyo2T0BlZf luGYHESX30926Xl2RnRUYR/EhpfPuNeOmlEHX5pN+mHzM6v8xE0EtWdZown6Mzku8Z AkFNTt5l7yOHA== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Jeff Layton , Eric Van Hensbergen , Sasha Levin , lucho@ionkov.net, asmadeus@codewreck.org, v9fs@lists.linux.dev Subject: [PATCH AUTOSEL 5.10 3/9] 9p: explicitly deny setlease attempts Date: Tue, 23 Apr 2024 07:02:41 -0400 Message-ID: <20240423110249.1659263-3-sashal@kernel.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240423110249.1659263-1-sashal@kernel.org> References: <20240423110249.1659263-1-sashal@kernel.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-stable-base: Linux 5.10.215 Content-Transfer-Encoding: 8bit From: Jeff Layton [ Upstream commit 7a84602297d36617dbdadeba55a2567031e5165b ] 9p is a remote network protocol, and it doesn't support asynchronous notifications from the server. Ensure that we don't hand out any leases since we can't guarantee they'll be broken when a file's contents change. Signed-off-by: Jeff Layton Signed-off-by: Eric Van Hensbergen Signed-off-by: Sasha Levin --- fs/9p/vfs_file.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/9p/vfs_file.c b/fs/9p/vfs_file.c index be5768949cb15..5d92eaeaebd91 100644 --- a/fs/9p/vfs_file.c +++ b/fs/9p/vfs_file.c @@ -685,6 +685,7 @@ const struct file_operations v9fs_file_operations = { .splice_read = generic_file_splice_read, .splice_write = iter_file_splice_write, .fsync = v9fs_file_fsync, + .setlease = simple_nosetlease, }; const struct file_operations v9fs_file_operations_dotl = { @@ -726,4 +727,5 @@ const struct file_operations v9fs_mmap_file_operations_dotl = { .splice_read = generic_file_splice_read, .splice_write = iter_file_splice_write, .fsync = v9fs_file_fsync_dotl, + .setlease = simple_nosetlease, }; -- 2.43.0