� ���, 06.07.2002, � 15:29, Pixel �������:
> Borsenkow Andrej <[EMAIL PROTECTED]> writes:
>
> > I was tired that my floppy/Jaz did not support file names in native
> > encoding when using auto file system type for supermount.
>
> wow, i didn't know that supermount was handling "auto" now :)
>
it is not the same "auto" as in mount command, it is using hardcoded
list of file systems, currently ext2, msdos, vfat, iso9660 and udf. I
guess it is pretty much everything that can be sensibly used on
removable media.
> using it...
>
> > There does not
> > seem to be any elegant way to pass extra options to supermount and ext2
> > is the only one file system tried for auto that does not support these
> > options so this patch simply makes ext2 ignore iocharset/codepage
> > options.
>
> pretty cool
>
> > IMHO these options should at least be accepted by every file system, but
> > ...
>
> the other solution would be for mount & supermount to only pass the
> understood options.
>
Sure. As I mentioned I could not find any acceptable user-level
interface. We definitely do not want to hardcode knowledge about
low-level options into supermount itself. As long as ext2 is the only
filesystem that does not support it my patch is the simplest solution.
> but this solution works and would be a nice to have.
> Juan please take it!
>
hey, what about other 5 or 6 kernel patches I have sent during last
month? :)
-andrej
Hmm ... actually UDF does not support codepage, so here is updated
patch. It compiles and removes warnings but I can't test if UDF really
works because I do not have any UDF media.
--- ./linux-2.4.18-18mdk/fs/udf/super.c.NLS Thu May 30 16:22:38 2002
+++ ./linux-2.4.18-18mdk/fs/udf/super.c Sat Jul 6 16:09:32 2002
@@ -268,6 +268,11 @@
uopt->nls_map = load_nls(val);
uopt->flags |= (1 << UDF_FLAG_NLS_MAP);
}
+#if defined(CONFIG_SUPERMOUNT) || defined(CONFIG_SUPERMOUNT_MODULE)
+ /* Silently ignore NLS option */
+ else if (!strcmp (opt, "codepage"))
+ /* Don't do anything ;-) */ ;
+#endif
#endif
else if (!strcmp(opt, "utf8") && !val)
uopt->flags |= (1 << UDF_FLAG_UTF8);
--- ./linux-2.4.18-18mdk/fs/ext2/super.c.NLS Mon Feb 25 22:38:08 2002
+++ ./linux-2.4.18-18mdk/fs/ext2/super.c Sat Jul 6 13:39:28 2002
@@ -274,6 +274,12 @@
|| !strcmp (this_char, "quota")
|| !strcmp (this_char, "usrquota"))
/* Don't do anything ;-) */ ;
+#if defined(CONFIG_SUPERMOUNT) || defined(CONFIG_SUPERMOUNT_MODULE)
+ /* Silently ignore NLS options */
+ else if (!strcmp (this_char, "iocharset")
+ || !strcmp (this_char, "codepage"))
+ /* Don't do anything ;-) */ ;
+#endif
else {
printk ("EXT2-fs: Unrecognized mount option %s\n", this_char);
return 0;