Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

msdos fs: remove unsettable atari option

It has been impossible to set the option 'atari' of the MSDOS filesystem
for several years. Since nobody seems to have missed it, let's remove its
remains.

Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx>
Acked-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Rene Scharfe and committed by
Linus Torvalds
7557bc66 dcd8c53f

+6 -13
+6 -12
fs/msdos/namei.c
··· 14 14 15 15 /* Characters that are undesirable in an MS-DOS file name */ 16 16 static unsigned char bad_chars[] = "*?<>|\""; 17 - static unsigned char bad_if_strict_pc[] = "+=,; "; 18 - /* GEMDOS is less restrictive */ 19 - static unsigned char bad_if_strict_atari[] = " "; 20 - 21 - #define bad_if_strict(opts) \ 22 - ((opts)->atari ? bad_if_strict_atari : bad_if_strict_pc) 17 + static unsigned char bad_if_strict[] = "+=,; "; 23 18 24 19 /***** Formats an MS-DOS file name. Rejects invalid names. */ 25 20 static int msdos_format_name(const unsigned char *name, int len, ··· 35 40 /* Get rid of dot - test for it elsewhere */ 36 41 name++; 37 42 len--; 38 - } else if (!opts->atari) 43 + } else 39 44 return -EINVAL; 40 45 } 41 46 /* 42 - * disallow names that _really_ start with a dot for MS-DOS, 43 - * GEMDOS does not care 47 + * disallow names that _really_ start with a dot 44 48 */ 45 - space = !opts->atari; 49 + space = 1; 46 50 c = 0; 47 51 for (walk = res; len && walk - res < 8; walk++) { 48 52 c = *name++; 49 53 len--; 50 54 if (opts->name_check != 'r' && strchr(bad_chars, c)) 51 55 return -EINVAL; 52 - if (opts->name_check == 's' && strchr(bad_if_strict(opts), c)) 56 + if (opts->name_check == 's' && strchr(bad_if_strict, c)) 53 57 return -EINVAL; 54 58 if (c >= 'A' && c <= 'Z' && opts->name_check == 's') 55 59 return -EINVAL; ··· 88 94 if (opts->name_check != 'r' && strchr(bad_chars, c)) 89 95 return -EINVAL; 90 96 if (opts->name_check == 's' && 91 - strchr(bad_if_strict(opts), c)) 97 + strchr(bad_if_strict, c)) 92 98 return -EINVAL; 93 99 if (c < ' ' || c == ':' || c == '\\') 94 100 return -EINVAL;
-1
include/linux/msdos_fs.h
··· 201 201 utf8:1, /* Use of UTF-8 character set (Default) */ 202 202 unicode_xlate:1, /* create escape sequences for unhandled Unicode */ 203 203 numtail:1, /* Does first alias have a numeric '~1' type tail? */ 204 - atari:1, /* Use Atari GEMDOS variation of MS-DOS fs */ 205 204 flush:1, /* write things quickly */ 206 205 nocase:1, /* Does this need case conversion? 0=need case conversion*/ 207 206 usefree:1; /* Use free_clusters for FAT32 */