conditionals-for-linux-ac-kernels-20010420
authorDerrick Brashear <shadow@dementia.org>
Sat, 21 Apr 2001 05:23:25 +0000 (05:23 +0000)
committerDerrick Brashear <shadow@dementia.org>
Sat, 21 Apr 2001 05:23:25 +0000 (05:23 +0000)
Adapted from katzj@linuxpower.org's work. Still needs makefile hackery and
glue scripts to do the defining

src/afs/LINUX/osi_file.c
src/afs/LINUX/osi_vfs.h

index 09d7d9c..d2b90df 100644 (file)
@@ -132,7 +132,11 @@ osi_UFSTruncate(afile, asize)
     lock_kernel();
     code = inode_change_ok(inode, &newattrs);
     if (!code)
+#ifdef INODE_SETATTR_NOT_VOID
+       code = inode_setattr(inode, &newattrs);
+#else
        inode_setattr(inode, &newattrs);
+#endif
     unlock_kernel();
     if (!code)
        truncate_inode_pages(&inode->i_data, asize);
index 3e795ca..ac09f99 100644 (file)
@@ -50,6 +50,9 @@ typedef struct vnode {
 #if !defined(AFS_LINUX24_ENV)
        unsigned long           i_nrpages;
 #endif
+#ifdef STRUCT_INODE_HAS_I_BYTES
+        unsigned short          i_bytes;
+#endif
        struct semaphore        i_sem;
 #if defined(AFS_LINUX24_ENV)
         struct semaphore        i_zombie;