Subject: Re: Supporting sector size != DEV_BSIZE -- uh-oh!
To: Trevin Beattie <trevin@xmission.com>
From: Bill Studenmund <wrstuden@netbsd.org>
List: tech-kern
Date: 06/13/2002 18:31:42
On Thu, 13 Jun 2002, Trevin Beattie wrote:

> I've been working on this today, and as expected, I was able to get the ffs
> code converted to treat i_ffs_blocks (a.k.a. di_blocks) as a number of
> sectors using some extra math with two fields from struct fs.
>
> HOWEVER -- when I moved on to the ufs code I discovered that ufs_vnops.c
> uses i_ffs_blocks in three functions, _none_ of which have an existing
> struct fs pointer at all!  And if I'm reading ufs/inode.h correctly, the
> inode could be used by either ffs or lfs, so a reference to ip->inode_u.fs
> may not work.

Try putting the fields in struct ufsmount. Then all fs's should be able to
work. Also, you'll need to do something like that since lfs needs the same
changes. :-)

Take care,

Bill