From patchwork Tue Apr 11 09:50:53 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Oleksij Rempel X-Patchwork-Id: 749387 X-Patchwork-Delegate: richard@nod.at Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3w2Mm82Ngjz9s8M for ; Tue, 11 Apr 2017 19:52:24 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="SK/A7Ka4"; dkim-atps=neutral DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=WhvuqhR3hdVGLuM01X2dlkpYl5eccPWbSYLAhJlwOI8=; b=SK/A7Ka4EPEDj3RJqEFpWFMSE0 KW/SYzlVnnIHi0a6vifxL/LcpMaiDXsbxyJpAI0kcd73J0kFquLPwY1QjNviIMZVK1G5fA6gxZH0V FoB15d6MZcZjfr9dV+0OHg9h5Rq8L3uPRDA/p3HrXZAYtM7Qpv4qv1vz+pDI5eg+bz0jCtLNBoSYQ Gw+qnZKifxMY6fECAp5CaK9JYvq7LYawMgs8gzj8xzb8WvZtl487rcvyVTKOMMs56t65dyY441lA1 ZPK6RMfu82KmAJGlsbqzzq+tZVbm4KLHYYBankHnsW6faQSsTGC1tLuJk4fBWFr7j0Z9ptp3A2NYi TxcttPNg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1cxsTG-0006ng-JD; Tue, 11 Apr 2017 09:52:22 +0000 Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1cxsSQ-0006Vi-Qp for linux-mtd@lists.infradead.org; Tue, 11 Apr 2017 09:51:32 +0000 Received: from dude.hi.pengutronix.de ([2001:67c:670:100:1d::7]) by metis.ext.pengutronix.de with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1cxsS2-0002iC-3a; Tue, 11 Apr 2017 11:51:06 +0200 Received: from ore by dude.hi.pengutronix.de with local (Exim 4.88) (envelope-from ) id 1cxsS0-0008R1-Ce; Tue, 11 Apr 2017 11:51:04 +0200 From: Oleksij Rempel To: richard@nod.at, dedekind1@gmail.com, adrian.hunter@intel.com, linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: [PATCH v2 1/3] fs: ubifs: parse iversion mount option Date: Tue, 11 Apr 2017 11:50:53 +0200 Message-Id: <20170411095055.26328-2-o.rempel@pengutronix.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170411095055.26328-1-o.rempel@pengutronix.de> References: <20170411095055.26328-1-o.rempel@pengutronix.de> X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::7 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-mtd@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170411_025131_071058_699C71A5 X-CRM114-Status: UNSURE ( 9.59 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Oleksij Rempel , Steffen Trumtrar MIME-Version: 1.0 Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: Steffen Trumtrar this option is needed to make UBIFS work with IMA. Signed-off-by: Steffen Trumtrar Signed-off-by: Oleksij Rempel --- fs/ubifs/super.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/fs/ubifs/super.c b/fs/ubifs/super.c index b73811bd7676..bff1e8d6f7bd 100644 --- a/fs/ubifs/super.c +++ b/fs/ubifs/super.c @@ -931,6 +931,7 @@ enum { Opt_chk_data_crc, Opt_no_chk_data_crc, Opt_override_compr, + Opt_i_version, Opt_err, }; @@ -942,6 +943,7 @@ static const match_table_t tokens = { {Opt_chk_data_crc, "chk_data_crc"}, {Opt_no_chk_data_crc, "no_chk_data_crc"}, {Opt_override_compr, "compr=%s"}, + {Opt_i_version, "i_version"}, {Opt_err, NULL}, }; @@ -986,6 +988,7 @@ static int ubifs_parse_options(struct ubifs_info *c, char *options, return 0; while ((p = strsep(&options, ","))) { + struct super_block *sb = c->vfs_sb; int token; if (!*p) @@ -1042,10 +1045,12 @@ static int ubifs_parse_options(struct ubifs_info *c, char *options, c->default_compr = c->mount_opts.compr_type; break; } + case Opt_i_version: + sb->s_flags |= MS_I_VERSION; + break; default: { unsigned long flag; - struct super_block *sb = c->vfs_sb; flag = parse_standard_option(p); if (!flag) {