From: Brian Gerst <bgerst@didntduck.org>
To: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Cc: Linus Torvalds <torvalds@transmeta.com>,
Linux-Kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] struct super_block cleanup - msdos/vfat
Date: Thu, 14 Mar 2002 19:19:10 -0500 [thread overview]
Message-ID: <3C913DFE.9020306@didntduck.org> (raw)
In-Reply-To: <3C8FE8E3.2040204@didntduck.org> <87k7sfoi8c.fsf@devron.myhome.or.jp> <87bsdrohu3.fsf@devron.myhome.or.jp> <3C90A9C4.4030801@didntduck.org> <874rjjnp5t.fsf@devron.myhome.or.jp>
[-- Attachment #1: Type: text/plain, Size: 1653 bytes --]
OGAWA Hirofumi wrote:
> Brian Gerst <bgerst@didntduck.org> writes:
>
>
>>OGAWA Hirofumi wrote:
>>
>>>OGAWA Hirofumi <hirofumi@mail.parknet.co.jp> writes:
>>>
>>>
>>>>Hi,
>>>>
>>>>Brian Gerst <bgerst@didntduck.org> writes:
>>>>
>>>>
>>>>
>>>>>diff -urN linux-2.5.7-pre1/fs/msdos/namei.c linux/fs/msdos/namei.c
>>>>>--- linux-2.5.7-pre1/fs/msdos/namei.c Thu Mar 7 21:18:32 2002
>>>>>+++ linux/fs/msdos/namei.c Wed Mar 13 08:20:12 2002
>>>>>@@ -603,17 +603,14 @@
>>>>>int msdos_fill_super(struct super_block *sb,void *data, int silent)
>>>>>{
>>>>>- struct super_block *res;
>>>>>+ int res;
>>>>>- MSDOS_SB(sb)->options.isvfat = 0;
>>>>>- res = fat_read_super(sb, data, silent, &msdos_dir_inode_operations);
>>>>>- if (IS_ERR(res))
>>>>>- return PTR_ERR(res);
>>>>>- if (res == NULL) {
>>>>>+ res = fat_fill_super(sb, data, silent, &msdos_dir_inode_operations, 0);
>>>>>+ if (res) {
>>>>> if (!silent)
>>>>> printk(KERN_INFO "VFS: Can't find a valid"
>>>>> " MSDOS filesystem on dev %s.\n", sb->s_id);
>>>>
>>>>If the error is I/O error, I think we shouldn't output this message.
>>>
>>> ^^^^^^^^^^^^^^^^^^^^^^^^^^
>>>If the error is except -EINVAL,
>>>Sorry.
>>>
>>>
>>>>What do you think about this?
>>>
>>Why not? The statement is true, and other filesystems do complain
>>when there is an I/O error.
>
>
> Umm, almost all filesystems doesn't output this message when the I/O error
> occurs, AFAIK.
>
> I think that this message indicate that a device isn't a FAT
> filesystem. And, of course, if error is the I/O error,
> fat_full_super() can't detect whether it is FAT filesystem or not.
Patch attached.
--
Brian Gerst
[-- Attachment #2: sb-fat-2 --]
[-- Type: text/plain, Size: 876 bytes --]
diff -urN linux/fs/msdos/namei.c linux2/fs/msdos/namei.c
--- linux/fs/msdos/namei.c Thu Mar 14 10:53:20 2002
+++ linux2/fs/msdos/namei.c Thu Mar 14 10:54:53 2002
@@ -607,7 +607,7 @@
res = fat_fill_super(sb, data, silent, &msdos_dir_inode_operations, 0);
if (res) {
- if (!silent)
+ if (res == -EINVAL && !silent)
printk(KERN_INFO "VFS: Can't find a valid"
" MSDOS filesystem on dev %s.\n", sb->s_id);
return res;
diff -urN linux/fs/vfat/namei.c linux2/fs/vfat/namei.c
--- linux/fs/vfat/namei.c Thu Mar 14 10:53:20 2002
+++ linux2/fs/vfat/namei.c Thu Mar 14 10:55:20 2002
@@ -1290,7 +1290,7 @@
res = fat_fill_super(sb, data, silent, &vfat_dir_inode_operations, 1);
if (res) {
- if (!silent)
+ if (res == -EINVAL && !silent)
printk(KERN_INFO "VFS: Can't find a valid"
" VFAT filesystem on dev %s.\n", sb->s_id);
return res;
next prev parent reply other threads:[~2002-03-15 0:20 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-03-14 0:03 Brian Gerst
2002-03-14 0:35 ` Alexander Viro
2002-03-15 14:40 ` Denis Vlasenko
2002-03-15 11:27 ` Alexander Viro
2002-03-15 18:24 ` Denis Vlasenko
2002-03-14 5:01 ` OGAWA Hirofumi
2002-03-14 5:10 ` OGAWA Hirofumi
2002-03-14 13:46 ` Brian Gerst
2002-03-14 15:29 ` OGAWA Hirofumi
2002-03-15 0:19 ` Brian Gerst [this message]
2002-03-15 4:00 ` OGAWA Hirofumi
[not found] <fa.fu00kkv.1b3a6a4@ifi.uio.no>
[not found] ` <fa.mfr7rqv.k42rjk@ifi.uio.no>
2002-03-19 7:01 ` Kasper Dupont
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3C913DFE.9020306@didntduck.org \
--to=bgerst@didntduck.org \
--cc=hirofumi@mail.parknet.co.jp \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®