Fix up minor build issues in some xfstests sources.

Fix build after recent xfsprogs header changes.
This commit is contained in:
Nathan Scott
2002-10-10 19:47:44 +00:00
parent 193436593d
commit 6ab9146e84
2 changed files with 21 additions and 1 deletions
+20
View File
@@ -32,6 +32,26 @@
#include "global.h"
/*
* Block I/O parameterization. A basic block (BB) is the lowest size of
* filesystem allocation, and must equal 512. Length units given to bio
* routines are in BB's.
*/
#define BBSHIFT 9
#define BBSIZE (1<<BBSHIFT)
#define BBMASK (BBSIZE-1)
#define BTOBB(bytes) (((__u64)(bytes) + BBSIZE - 1) >> BBSHIFT)
#define BTOBBT(bytes) ((__u64)(bytes) >> BBSHIFT)
#define BBTOB(bbs) ((bbs) << BBSHIFT)
#define OFFTOBB(bytes) (((__u64)(bytes) + BBSIZE - 1) >> BBSHIFT)
#define OFFTOBBT(bytes) ((__u64)(bytes) >> BBSHIFT)
#define BBTOOFF(bbs) ((__u64)(bbs) << BBSHIFT)
#define SEEKLIMIT32 0x7fffffff
#define BBSEEKLIMIT32 BTOBBT(SEEKLIMIT32)
#define SEEKLIMIT 0x7fffffffffffffffLL
#define BBSEEKLIMIT OFFTOBBT(SEEKLIMIT)
#define FSBTOBB(f) (OFFTOBBT(FSBTOOFF(f)))
#define BBTOFSB(b) (OFFTOFSB(BBTOOFF(b)))
#define OFFTOFSB(o) ((o) / blocksize)
+1 -1
View File
@@ -8,7 +8,7 @@
int main(int argc, char **argv)
{
int fd,n;
int fd;
char *ptr, *ptr2;
struct stat st;