[Libsysio-commit] HEAD: libsysio/drivers/native fs_native.c
Brought to you by:
lward
|
From: Lee W. <lw...@us...> - 2003-10-15 18:01:33
|
Update of /cvsroot/libsysio/libsysio/drivers/native
In directory sc8-pr-cvs1:/tmp/cvs-serv9577/drivers/native
Modified Files:
fs_native.c
Log Message:
Eliminated the i-node number field from the inode structure. We already
carry the file identifier so it was redundant. Problematic too, in that
it can be 32 or 64 bits in size.
This forced _sysio_i_new() and _sysio_i_find() to change -- They no longer
take the i-node number as an argument. Updated the driver calls to reflect
the new usage.
The i-node cache is now indexed by hashing the file identifier as opposed
to just using the, no longer maintained, i-node number. This caused
_sysio_i_find to become 2+ percent more expensive to use. Acceptable
for me.
Index: fs_native.c
===================================================================
RCS file: /cvsroot/libsysio/libsysio/drivers/native/fs_native.c,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -w -b -B -p -r1.19 -r1.20
--- fs_native.c 13 Oct 2003 01:04:34 -0000 1.19
+++ fs_native.c 15 Oct 2003 18:00:54 -0000 1.20
@@ -363,7 +363,6 @@ native_i_new(struct filesys *fs, struct
nino->ni_fpos = 0;
ino =
_sysio_i_new(fs,
- buf->st_ino,
&nino->ni_fileid,
#ifndef AUTOMOUNT_FILE_NAME
buf->st_mode & S_IFMT,
@@ -606,7 +605,7 @@ native_iget(struct filesys *fs,
#endif
fileid.fid_data = &ident;
fileid.fid_len = sizeof(ident);
- ino = _sysio_i_find(fs, stbuf.st_ino, &fileid);
+ ino = _sysio_i_find(fs, &fileid);
if (ino && forced) {
/*
* Insertion was forced but it's already present!
|