berry@socrates.umd.edu (Joseph Berry ) (05/28/91)
Can anyone please explain how SCO uses the b_dev fields for S51K filesystem buffers? Most systems I am familiar with use b_dev as the device of the mounted filesystem, but SCO seems to use this field differently. P.S. my application reads the buf[] array and tries to determine the percentage of buffer usage per filesystem. Any hints? Thanks
boyd@prl.dec.com (Boyd Roberts) (05/28/91)
Perhaps it's a more general System V problem as the high bit of `b_dev' may be set depending on the file-system type. There's some hideous macro `bmajor()' that will mash off that bit. Use it instead of major(). The bit is required to determine the block size of the I/O blah blah inside the driver. The whole thing is a steaming crock of merde... Boyd Roberts boyd@prl.dec.com ``When the going gets wierd, the weird turn pro...''
jfh@rpp386.cactus.org (John F Haugh II) (05/29/91)
In article <1991May28.154355.5924@prl.dec.com> boyd@prl.dec.com (Boyd Roberts) writes: >Perhaps it's a more general System V problem as the high bit >of `b_dev' may be set depending on the file-system type. There's >some hideous macro `bmajor()' that will mash off that bit. Use >it instead of major(). Just a general hint for wannabe wizards, looking at the data in a different radix (for example, hex or octal) often makes sense. Also, try reading the header files some day. The particular macro Boyd is writing about is in /usr/include/sys/sysmacros.h on Xenix. -- John F. Haugh II | Distribution to | UUCP: ...!cs.utexas.edu!rpp386!jfh Ma Bell: (512) 255-8251 | GEnie PROHIBITED :-) | Domain: jfh@rpp386.cactus.org "If liberals interpreted the 2nd Amendment the same way they interpret the rest of the Constitution, gun ownership would be mandatory."