Skip to contentSkip to conversation

2.4.9 compiler warnings & errors NTFS

PATCH Joe 2 participants 2 messages Aug 19, 2001 NTFS filesystem

lore
Share & tools
lore

Joe

author
#0 lore raw

Okay I tried kernel the patch to 2.4.9 (I applied 2.4.8 patch on top of a 2.4.7 kernel then 2.4.9 patch).

The NTFS module wont build in 2.4.9. It seems that there is a missing include file in fs/ntfs/unistr.c . After I added

#include <linux/fs.h>

to the file it seems to have fixed the problem. (patch at bottom of mail)

Joe

The following is the error before I added the include:

make[3]: Circular passthrough.h <- hwaccess.h dependency dropped. namei.c: In function `msdos_lookup':
namei.c:237: warning: implicit declaration of function fat_brelse' namei.c: In function msdos_add_entry':
namei.c:266: warning: implicit declaration of function `fat_mark_buffer_dirty'
unistr.c: In function `ntfs_collate_names':
unistr.c:99: warning: implicit declaration of function min' unistr.c:99: parse error before unsigned'
unistr.c:99: parse error before `)'
unistr.c:97: warning: `c1' might be used uninitialized in this function unistr.c: At top level:
unistr.c:118: parse error before `if'
unistr.c:123: warning: type defaults to int' in declaration of c1' unistr.c:123: name1' undeclared here (not in a function) unistr.c:123: warning: data definition has no type or storage class unistr.c:124: parse error before if'
make[2]: *** [unistr.o] Error 1
make[1]: *** [_modsubdir_ntfs] Error 2
make: *** [_mod_fs] Error 2
cp: cannot stat `ntfs.o': No such file or directory

This is the error after I added the include. (It compiled too)

sym53c8xx.c: In function `ncr_soft_reset':
sym53c8xx.c:6994: warning: `istat' might be used uninitialized in this function
make[3]: Circular passthrough.h <- hwaccess.h dependency dropped. namei.c: In function `msdos_lookup':
namei.c:237: warning: implicit declaration of function fat_brelse' namei.c: In function msdos_add_entry':
namei.c:266: warning: implicit declaration of function `fat_mark_buffer_dirty'
dir.c: In function `umsdos_readdir_x':
dir.c:142: warning: passing arg 3 of `fat_readdir' from incompatible pointer type
dir.c: In function `UMSDOS_readdir':
dir.c:315: warning: passing arg 5 of `umsdos_readdir_x' from incompatible pointer type
ioctl.c: In function `UMSDOS_ioctl_dir':
ioctl.c:146: warning: passing arg 3 of `fat_readdir' from incompatible pointer type
rdir.c: In function `UMSDOS_rreaddir':
rdir.c:70: warning: passing arg 3 of `fat_readdir' from incompatible pointer type

################## patch

fs/ntfs/unistr.c Sun Aug 19 13:32:46 2001 renamed from ntfs/unistr.c Sun Aug 19 12:31:03 2001 +2 -0
@@ -24,6 +24,8 @@
 #include <linux/string.h>
 #include <asm/byteorder.h>
 
+#include <linux/fs.h>
+
 #include "unistr.h"
 #include "macros.h"
 
#1 lore raw
Quoted 10 lines · Joe

Okay I tried kernel the patch to 2.4.9 (I applied 2.4.8 patch on top of a 2.4.7 kernel then 2.4.9 patch).

The NTFS module wont build in 2.4.9. It seems that there is a missing include file in fs/ntfs/unistr.c . After I added

#include <linux/fs.h>

to the file it seems to have fixed the problem. (patch at bottom of mail)

Yes. Known problem. This is correct fix. You must be the 50th person sending a patch by now... (-;

Cheers,

Anton

Quoted 72 lines

Joe

The following is the error before I added the include:

make[3]: Circular passthrough.h <- hwaccess.h dependency dropped. namei.c: In function `msdos_lookup':
namei.c:237: warning: implicit declaration of function fat_brelse' namei.c: In function msdos_add_entry':
namei.c:266: warning: implicit declaration of function `fat_mark_buffer_dirty'
unistr.c: In function `ntfs_collate_names':
unistr.c:99: warning: implicit declaration of function min' unistr.c:99: parse error before unsigned'
unistr.c:99: parse error before `)'
unistr.c:97: warning: `c1' might be used uninitialized in this function unistr.c: At top level:
unistr.c:118: parse error before `if'
unistr.c:123: warning: type defaults to int' in declaration of c1' unistr.c:123: name1' undeclared here (not in a function) unistr.c:123: warning: data definition has no type or storage class unistr.c:124: parse error before if'
make[2]: *** [unistr.o] Error 1
make[1]: *** [_modsubdir_ntfs] Error 2
make: *** [_mod_fs] Error 2
cp: cannot stat `ntfs.o': No such file or directory

This is the error after I added the include. (It compiled too)

sym53c8xx.c: In function `ncr_soft_reset':
sym53c8xx.c:6994: warning: `istat' might be used uninitialized in this function
make[3]: Circular passthrough.h <- hwaccess.h dependency dropped. namei.c: In function `msdos_lookup':
namei.c:237: warning: implicit declaration of function fat_brelse' namei.c: In function msdos_add_entry':
namei.c:266: warning: implicit declaration of function `fat_mark_buffer_dirty'
dir.c: In function `umsdos_readdir_x':
dir.c:142: warning: passing arg 3 of `fat_readdir' from incompatible pointer type
dir.c: In function `UMSDOS_readdir':
dir.c:315: warning: passing arg 5 of `umsdos_readdir_x' from incompatible pointer type
ioctl.c: In function `UMSDOS_ioctl_dir':
ioctl.c:146: warning: passing arg 3 of `fat_readdir' from incompatible pointer type
rdir.c: In function `UMSDOS_rreaddir':
rdir.c:70: warning: passing arg 3 of `fat_readdir' from incompatible pointer type

################## patch

fs/ntfs/unistr.c Sun Aug 19 13:32:46 2001 renamed from ntfs/unistr.c Sun Aug 19 12:31:03 2001 +2 -1
@@ -24,6 +24,8 @@
 #include <linux/string.h>
 #include <asm/byteorder.h>
 
+#include <linux/fs.h>
+
 #include "unistr.h"
 #include "macros.h"
 
 
 
 
-

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Signature · 5 lines
  "Nothing succeeds like success." - Alexandre Dumas
-- 
Anton Altaparmakov <aia21 at cam.ac.uk> (replace at with @)
Linux NTFS Maintainer / WWW: http://linux-ntfs.sf.net/
ICQ: 8561279 / WWW: http://www-stu.christs.cam.ac.uk/~aia21/