Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp419630pxk; Fri, 11 Sep 2020 10:21:39 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyKjwsOnu9mYcMl/GzqGOoDzNPxQ2mv4cjc+3jQ+6B3RtlxN9IzYdvtrjLacoqhS1uDBYcd X-Received: by 2002:a17:906:341b:: with SMTP id c27mr2975257ejb.286.1599844898926; Fri, 11 Sep 2020 10:21:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599844898; cv=none; d=google.com; s=arc-20160816; b=I/mZ6IR8cSrZF4LAdxtx+bmy5iW+kus3k1k3HmPuc8mZa3WzDOrle8SIqOZdNXpUeu EezJSZ6TugCPb5Jb3uVfM1AGiHl2A8eodEHZIhuygdH65DO3pkOuD01aFvS60LudFe+u aQH31T1NoJ005wyzDi7coPKwVvqjvKGm6M3xpuTQSvZo+/yMlXAgEcAo7OEf0yNBhc9L fm6pSgTVLMgQB72m5fMP0uFI+DcBsschGLt+ABGqK8YH91lOcGqS/ObvOMacIybwrLEd Xq1KzUVIlgOed7MvjJh/BAalf4j+xFFaPTRjkYGNGAqKNCGepH8U/D79z/mgOSMEVEEK soxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=KKPvyLwkzXGrb124BPjP5OgM1CJvMZ/iW0JeeBMllO0=; b=PMRbYUjrHbpMyZcBonBqiAMWMOMJANUorGTZtDplpiK5eHgxouKQyAn5+GOEYkwjYr HemX3XevKzfKRjgbsH8pvwu1cLGgCDFC8aZyZ8z0Sh8ayd3DnwxFn733EfasStAVAWBn 5Bw9VRoqw1Chbbp/2IormHCmBUCktIgOHbl1oY3fEie9F1Zu/sDsnMnfFQ22OHPXlQiL 3YSOrIXgKAUMaFYBoT4Vd1MFtknL4ap+jLvRyhXGIqnZoSXFuwahE0EODsjkxcuhzSnO jm2q/2E3eKzLyndknZTpOvnFgRHiltm9SciO0fcvN6O1LWJ6WBqQmfiTnnINiBgyLFTI jZqw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=WLhGSrQ+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y3si1726544edr.538.2020.09.11.10.21.15; Fri, 11 Sep 2020 10:21:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=WLhGSrQ+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726361AbgIKRUJ (ORCPT + 99 others); Fri, 11 Sep 2020 13:20:09 -0400 Received: from mail.kernel.org ([198.145.29.99]:52810 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726168AbgIKNCU (ORCPT ); Fri, 11 Sep 2020 09:02:20 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0B0E622284; Fri, 11 Sep 2020 12:56:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1599829017; bh=eySNeSs6dVycPr5WJLZaEg/u4b3EQfaJkXxHGmlbQGs=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WLhGSrQ+XG0HTG4/N+xLHhpH2/+SQbYPRbmueeoKH036XQhtQYCx67vt4v0SfOpWM w0yxANsaQTUxJs/RksXkhyRAtPdW4/SJ4X5hOfjBWQdllJ3CgGlyyiw+92aqIfOqAu rzTgbASUpI7LzTaB+V+h/MR4ANb3GRbfzsKwYgJI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Jeff Layton , Ilya Dryomov , Sasha Levin Subject: [PATCH 4.9 06/71] ceph: dont allow setlease on cephfs Date: Fri, 11 Sep 2020 14:45:50 +0200 Message-Id: <20200911122505.255206224@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200911122504.928931589@linuxfoundation.org> References: <20200911122504.928931589@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jeff Layton [ Upstream commit 496ceaf12432b3d136dcdec48424312e71359ea7 ] Leases don't currently work correctly on kcephfs, as they are not broken when caps are revoked. They could eventually be implemented similarly to how we did them in libcephfs, but for now don't allow them. [ idryomov: no need for simple_nosetlease() in ceph_dir_fops and ceph_snapdir_fops ] Signed-off-by: Jeff Layton Reviewed-by: Ilya Dryomov Signed-off-by: Ilya Dryomov Signed-off-by: Sasha Levin --- fs/ceph/file.c | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/ceph/file.c b/fs/ceph/file.c index e7ddb23d9bb73..e818344a052cb 100644 --- a/fs/ceph/file.c +++ b/fs/ceph/file.c @@ -1773,6 +1773,7 @@ const struct file_operations ceph_file_fops = { .mmap = ceph_mmap, .fsync = ceph_fsync, .lock = ceph_lock, + .setlease = simple_nosetlease, .flock = ceph_flock, .splice_write = iter_file_splice_write, .unlocked_ioctl = ceph_ioctl, -- 2.25.1