Newsgroups: comp.os.linux.announce
From: qx@shire.math.columbia.edu (Qi Xia)
Subject: EMERGENCY: xiafs in linux-0.99.7
Message-ID: <1993Mar14.193748.7604@tc.cornell.edu>
Date: Sun, 14 Mar 1993 19:37:48 GMT
Approved: linux-announce@tc.cornell.edu (Matt Welsh)

Hi, 

There are some inhencement in xiafs supposed to be included in official
linux 0.99.7 distribution. But when I got the distribution, I found it's
not there. As a result, xiafspgm-0.8.tar.Z I uploaded to linux sites
yesterday will not work with linux 0.99.7.
You still need xfspgm-0.7.tar.Z with xfspgm-0.7.fix which you have now,
or xfsck and mkxfs from H.J. Lu's rootdisk.

If you have run (0.8) xfsck, and your xiafs is not accessable any more,
do not panic. Apply following patch to linux-0.99.7. 
It is for linux-0.99.6/xiafs-0.7.2, but it
should work with linux-0.99.7 (patch may report "off xxx lines").
Your xiafs will be accessable again and work normally under patched
kernel. But you have to continuous using xiafspgm-0.8. (0.8) xfsck may
report "bad i_blocks" for some files. You can safely ignore it.
This will be fixed automatically, when the inhencement get into the kernel.

I will contect Linus, ask him to include the inhencement in next release.
Sorry for the confusing.

Frank Xia.

=========[xiafs-0.7pl3]=================================================
*** inode.c.org	Wed Mar 10 17:00:38 1993
--- inode.c	Wed Mar 10 18:17:51 1993
***************
*** 374,382 ****
          inode->i_rdev = raw_inode->i_zone[0];
      else {
          for (zone = 0; zone < 8; zone++)
! 	    inode->u.xfs_i.i_zone[zone] = raw_inode->i_zone[zone];
! 	inode->u.xfs_i.i_ind_zone = raw_inode->i_ind_zone;
! 	inode->u.xfs_i.i_dind_zone = raw_inode->i_dind_zone;
      }
      brelse(bh);
      if (S_ISREG(inode->i_mode))
--- 374,382 ----
          inode->i_rdev = raw_inode->i_zone[0];
      else {
          for (zone = 0; zone < 8; zone++)
! 	    inode->u.xfs_i.i_zone[zone] = raw_inode->i_zone[zone] & 0xffffff;
! 	inode->u.xfs_i.i_ind_zone       = raw_inode->i_ind_zone   & 0xffffff;
! 	inode->u.xfs_i.i_dind_zone      = raw_inode->i_dind_zone  & 0xffffff;
      }
      brelse(bh);
      if (S_ISREG(inode->i_mode))
***************
*** 438,446 ****
          raw_inode->i_zone[0] = inode->i_rdev;
      else {
          for (zone = 0; zone < 8; zone++)
! 	    raw_inode->i_zone[zone] = inode->u.xfs_i.i_zone[zone];
! 	raw_inode->i_ind_zone = inode->u.xfs_i.i_ind_zone;
! 	raw_inode->i_dind_zone = inode->u.xfs_i.i_dind_zone;
      }
      inode->i_dirt=0;
      bh->b_dirt=1;
--- 438,449 ----
          raw_inode->i_zone[0] = inode->i_rdev;
      else {
          for (zone = 0; zone < 8; zone++)
! 	    raw_inode->i_zone[zone] = (raw_inode->i_zone[zone] & 0xff000000) 
! 	                             | (inode->u.xfs_i.i_zone[zone] & 0xffffff);
! 	raw_inode->i_ind_zone = (raw_inode->i_ind_zone & 0xff000000)
! 	                             | (inode->u.xfs_i.i_ind_zone   & 0xffffff);
! 	raw_inode->i_dind_zone = (raw_inode->i_dind_zone & 0xff000000)
! 	                             | (inode->u.xfs_i.i_dind_zone  & 0xffffff);
      }
      inode->i_dirt=0;
      bh->b_dirt=1;

-- 
Send submissions for comp.os.linux.announce to: linux-announce@tc.cornell.edu
