Re: [RFC PATCH 2/4] mm: shmem: Support case-insensitive file name lookups

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Às 17:18 de 23/03/21, Gabriel Krisman Bertazi escreveu:
André Almeida <andrealmeid@xxxxxxxxxxxxx> writes:
  	opt = fs_parse(fc, shmem_fs_parameters, param, &result);
  	if (opt < 0)
@@ -3468,6 +3519,23 @@ static int shmem_parse_one(struct fs_context *fc, struct fs_parameter *param)
  		ctx->full_inums = true;
  		ctx->seen |= SHMEM_SEEN_INUMS;
  		break;
+	case Opt_casefold:
+		if (strncmp(param->string, "utf8-", 5))
+			return invalfc(fc, "Only utf8 encondings are supported");
+		ret = strscpy(version, param->string + 5, sizeof(version));

Ugh.  Now we are doing two strscpy for the parse api (in unicode_load).
Can change the unicode_load api to reuse it?


So instead of getting just the version number (e.g. "12.1.0") as parameter, utf8_load/unicode_load would get the full encoding string (e.g. "utf8-12.1.0") right?



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux