]> git.wh0rd.org - dump.git/blobdiff - compat/include/bsdcompat.h
Corrections from Georg Lippold
[dump.git] / compat / include / bsdcompat.h
index 96ce8b43ba62b2c565d6801088f7dce5d326cfa6..16de840c73d8531be3ee97aa5d1707911b21a1bd 100644 (file)
@@ -2,10 +2,10 @@
  *     Ported to Linux's Second Extended File System as part of the
  *     dump and restore backup suit
  *     Remy Card <card@Linux.EU.Org>, 1994-1997
- *     Stelian Pop <pop@noos.fr>, 1999-2000
- *     Stelian Pop <pop@noos.fr> - Alcôve <www.alcove.fr>, 2000
+ *     Stelian Pop <stelian@popies.net>, 1999-2000
+ *     Stelian Pop <stelian@popies.net> - Alcôve <www.alcove.com>, 2000-2002
  *
- *     $Id: bsdcompat.h,v 1.14 2001/03/20 09:14:58 stelian Exp $
+ *     $Id: bsdcompat.h,v 1.17 2002/06/10 14:05:00 stelian Exp $
  */
 
 #include <config.h>
@@ -22,7 +22,7 @@
 #define MIN(a,b)       ((a < b) ? a : b)
 #endif
 
-#define        WINO            ((ino_t)1)
+#define        WINO            1
 #define        DEV_BSIZE       512
 #define        DEV_BSHIFT      9
 #define        MAXBSIZE        EXT2_MAX_BLOCK_SIZE
@@ -36,7 +36,8 @@
 #define powerof2(x)    ((((x)-1)&(x))==0)
 
 #define dbtob(b)       ((unsigned)(b) << DEV_BSHIFT)
-#define fsbtodb(sb,b)  ((int)(((long long)b * EXT2_BLOCK_SIZE(sb->super)) / DEV_BSIZE))
+#define fsbtodb(sb,b)  ((int)(((long long)(b) * EXT2_BLOCK_SIZE((sb)->super)) / DEV_BSIZE))
+#define dbtofsb(sb,b)  ((int)(((long long)(b) * DEV_BSIZE) / EXT2_BLOCK_SIZE((sb)->super)))
 
 #define        sblock          fs
 #define fs_fsize       fragsize