Blame SOURCES/0021-exfat-add-the-dummy-mount-options-to-be-backward-com.patch

Kmods SIG 50e2b3
From 907fa893258ba6076f5fff32900a461decb9e8c5 Mon Sep 17 00:00:00 2001
Kmods SIG 50e2b3
From: Namjae Jeon <namjae.jeon@samsung.com>
Kmods SIG 50e2b3
Date: Fri, 22 May 2020 08:10:10 +0900
Kmods SIG 50e2b3
Subject: [Backport 907fa893258b] exfat: add the dummy mount options to be
Kmods SIG 50e2b3
 backward compatible with staging/exfat
Kmods SIG 50e2b3
Kmods SIG 50e2b3
As Ubuntu and Fedora release new version used kernel version equal to or
Kmods SIG 50e2b3
higher than v5.4, They started to support kernel exfat filesystem.
Kmods SIG 50e2b3
Kmods SIG 50e2b3
Linus reported a mount error with new version of exfat on Fedora:
Kmods SIG 50e2b3
Kmods SIG 50e2b3
        exfat: Unknown parameter 'namecase'
Kmods SIG 50e2b3
Kmods SIG 50e2b3
This is because there is a difference in mount option between old
Kmods SIG 50e2b3
staging/exfat and new exfat.  And utf8, debug, and codepage options as
Kmods SIG 50e2b3
well as namecase have been removed from new exfat.
Kmods SIG 50e2b3
Kmods SIG 50e2b3
This patch add the dummy mount options as deprecated option to be
Kmods SIG 50e2b3
backward compatible with old one.
Kmods SIG 50e2b3
Kmods SIG 50e2b3
Reported-by: Linus Torvalds <torvalds@linux-foundation.org>
Kmods SIG 50e2b3
Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
Kmods SIG 50e2b3
Cc: Matthew Wilcox <willy@infradead.org>
Kmods SIG 50e2b3
Cc: Al Viro <viro@zeniv.linux.org.uk>
Kmods SIG 50e2b3
Cc: Eric Sandeen <sandeen@sandeen.net>
Kmods SIG 50e2b3
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Kmods SIG 50e2b3
---
Kmods SIG 50e2b3
 src/super.c | 19 +++++++++++++++++++
Kmods SIG 50e2b3
 1 file changed, 19 insertions(+)
Kmods SIG 50e2b3
Kmods SIG 50e2b3
diff --git a/src/super.c b/src/super.c
Kmods SIG 50e2b3
index 0565d5539d57c6678c81997228dc3b8116eb864c..a846ff555656cd876e77ae014b35e192b5ccd183 100644
Kmods SIG 50e2b3
--- a/src/super.c
Kmods SIG 50e2b3
+++ b/src/super.c
Kmods SIG 50e2b3
@@ -203,6 +203,12 @@ enum {
Kmods SIG 50e2b3
 	Opt_errors,
Kmods SIG 50e2b3
 	Opt_discard,
Kmods SIG 50e2b3
 	Opt_time_offset,
Kmods SIG 50e2b3
+
Kmods SIG 50e2b3
+	/* Deprecated options */
Kmods SIG 50e2b3
+	Opt_utf8,
Kmods SIG 50e2b3
+	Opt_debug,
Kmods SIG 50e2b3
+	Opt_namecase,
Kmods SIG 50e2b3
+	Opt_codepage,
Kmods SIG 50e2b3
 };
Kmods SIG 50e2b3
 
Kmods SIG 50e2b3
 static const struct constant_table exfat_param_enums[] = {
Kmods SIG 50e2b3
@@ -223,6 +229,14 @@ static const struct fs_parameter_spec exfat_parameters[] = {
Kmods SIG 50e2b3
 	fsparam_enum("errors",			Opt_errors, exfat_param_enums),
Kmods SIG 50e2b3
 	fsparam_flag("discard",			Opt_discard),
Kmods SIG 50e2b3
 	fsparam_s32("time_offset",		Opt_time_offset),
Kmods SIG 50e2b3
+	__fsparam(NULL, "utf8",			Opt_utf8, fs_param_deprecated,
Kmods SIG 50e2b3
+		  NULL),
Kmods SIG 50e2b3
+	__fsparam(NULL, "debug",		Opt_debug, fs_param_deprecated,
Kmods SIG 50e2b3
+		  NULL),
Kmods SIG 50e2b3
+	__fsparam(fs_param_is_u32, "namecase",	Opt_namecase,
Kmods SIG 50e2b3
+		  fs_param_deprecated, NULL),
Kmods SIG 50e2b3
+	__fsparam(fs_param_is_u32, "codepage",	Opt_codepage,
Kmods SIG 50e2b3
+		  fs_param_deprecated, NULL),
Kmods SIG 50e2b3
 	{}
Kmods SIG 50e2b3
 };
Kmods SIG 50e2b3
 
Kmods SIG 50e2b3
@@ -278,6 +292,11 @@ static int exfat_parse_param(struct fs_context *fc, struct fs_parameter *param)
Kmods SIG 50e2b3
 			return -EINVAL;
Kmods SIG 50e2b3
 		opts->time_offset = result.int_32;
Kmods SIG 50e2b3
 		break;
Kmods SIG 50e2b3
+	case Opt_utf8:
Kmods SIG 50e2b3
+	case Opt_debug:
Kmods SIG 50e2b3
+	case Opt_namecase:
Kmods SIG 50e2b3
+	case Opt_codepage:
Kmods SIG 50e2b3
+		break;
Kmods SIG 50e2b3
 	default:
Kmods SIG 50e2b3
 		return -EINVAL;
Kmods SIG 50e2b3
 	}
Kmods SIG 50e2b3
-- 
Kmods SIG 50e2b3
2.31.1
Kmods SIG 50e2b3