Received: by 2002:a05:6a10:1d13:0:0:0:0 with SMTP id pp19csp2904702pxb; Tue, 24 Aug 2021 10:16:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxg5HBYm4DEr4Sr2q2wcGN3lpv7yVgT2rsOwEsu83AVDHM+3CpGvNjjFhEd7b0v5rkVb+XM X-Received: by 2002:a02:866b:: with SMTP id e98mr36198311jai.48.1629825379837; Tue, 24 Aug 2021 10:16:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629825379; cv=none; d=google.com; s=arc-20160816; b=YK4IQn0Ch1qeMWB8WmTmsFIu3+bBC5FG19nbC/d545gBqn4oFAX2lfxaB2zglqQxYS TCVhB4HOvXcCAtWVDPQB85o7TCcBmmml1gjt+hu8U/bxXtFocB88OwE1icfhFWtrzv20 X6BoqWEqJZLe6QKqABs+gn0VpmqWf4fa6vnb8ijzAJgn/aSPwQQaEemTXd1/ABcVuY8U 6Vb7LYpt9enEVNKQCbAn5oT/JNE51hB4TZmanUNBsKZXZy0GIS90geYvfZ0nOQLXd+L6 JyjbJ6jgu89Sqrx8nqKJBtqP99uQ/Pbke58J2riaaQ2QyHxLJ+KbMEY2YPrtXz16Gdtu jAPg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=UMEqSvb2m3pgGvYuB2oEzcT/2QEs75B/ueSk/1K/4yA=; b=JBeYB/5teua/un/6fpFVT50Lemsa6A5pC9klcJZqfx2WzEpTAf3tOw9T84ELFL4fAs cgezpyOaUl6fY88b3XEjWt9l9VnMrQ22VMwlWkYSKnTQvPmliJzkaEChs0Ys3OzxLJpM u9eQJoTE1WotMJtzwtMjS+CvrMXIiseJ2I9IxD2gKer/la7JnUnHtwxbtwhceAfjxmCK jkx8H/tsfNIXPC06rWVB9Dtm798bxWemZMZJJUBKgXWx83XO3bC9Bqpw7BmhQIJeuRvB UaXVB4pwGIw57GXYqMoeHp4QvTGGvS1OBgsiewDhlvv1ylzZTKGnGjPPo7UP+24BXzuZ 3O/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lZ+zJcMy; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 10si15772924ilz.71.2021.08.24.10.16.08; Tue, 24 Aug 2021 10:16:19 -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=k20201202 header.b=lZ+zJcMy; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240103AbhHXROU (ORCPT + 99 others); Tue, 24 Aug 2021 13:14:20 -0400 Received: from mail.kernel.org ([198.145.29.99]:51088 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239554AbhHXRKw (ORCPT ); Tue, 24 Aug 2021 13:10:52 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8E73D61A64; Tue, 24 Aug 2021 17:00:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1629824444; bh=To40oEZF+AxZGbYWtmOTvxxJu29XONBQWHletcOm5qM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lZ+zJcMymJGqHdWjyAb76R3/JMEAe5cq8hRcSQsNn2k0qttrX71eqU17LmqHHKe+J 5TNbssk/JBPUW2gOCmDA85nkuuFONmx4fIEaZslyaQ/jkVRSVyyku823X8l4Nn4u/P GKSBh+UbRyIRtBR5hJhoSvAAZxpLlTsgenGBdP+yTU2rRVwDiOk8piuabJgYjI53Kj 72x2DZtjmx+Q6zyHQWi4pXg+Bm9ozwhUHCYOG1UFaqTBCDmbP452cuoYQzyPu2DY3d T1ICk0ixZV51NASQRbU2QWwyHe8Oe6mFeL/cQEu0th1A39M3Iu3gcp5bpdTruLaqm/ q+VRXnQaffwJw== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Jeff Layton , Sasha Levin Subject: [PATCH 5.10 95/98] fs: warn about impending deprecation of mandatory locks Date: Tue, 24 Aug 2021 12:59:05 -0400 Message-Id: <20210824165908.709932-96-sashal@kernel.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210824165908.709932-1-sashal@kernel.org> References: <20210824165908.709932-1-sashal@kernel.org> MIME-Version: 1.0 X-KernelTest-Patch: http://kernel.org/pub/linux/kernel/v5.x/stable-review/patch-5.10.61-rc1.gz X-KernelTest-Tree: git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git X-KernelTest-Branch: linux-5.10.y X-KernelTest-Patches: git://git.kernel.org/pub/scm/linux/kernel/git/stable/stable-queue.git X-KernelTest-Version: 5.10.61-rc1 X-KernelTest-Deadline: 2021-08-26T16:58+00:00 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jeff Layton [ Upstream commit fdd92b64d15bc4aec973caa25899afd782402e68 ] We've had CONFIG_MANDATORY_FILE_LOCKING since 2015 and a lot of distros have disabled it. Warn the stragglers that still use "-o mand" that we'll be dropping support for that mount option. Cc: stable@vger.kernel.org Signed-off-by: Jeff Layton Signed-off-by: Sasha Levin --- fs/namespace.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/fs/namespace.c b/fs/namespace.c index 175312428cdf..046b084136c5 100644 --- a/fs/namespace.c +++ b/fs/namespace.c @@ -1697,8 +1697,12 @@ static inline bool may_mount(void) } #ifdef CONFIG_MANDATORY_FILE_LOCKING -static inline bool may_mandlock(void) +static bool may_mandlock(void) { + pr_warn_once("======================================================\n" + "WARNING: the mand mount option is being deprecated and\n" + " will be removed in v5.15!\n" + "======================================================\n"); return capable(CAP_SYS_ADMIN); } #else -- 2.30.2