]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs_repair - 031 QA failure with platform that don't use the uuid field in the super...
authorMadan Valluri <mvalluri@sgi.com>
Wed, 31 Jan 2007 04:11:16 +0000 (04:11 +0000)
committerMadan Valluri <mvalluri@sgi.com>
Wed, 31 Jan 2007 04:11:16 +0000 (04:11 +0000)
Darwin has uuid.

libxfs/darwin.c
libxfs/freebsd.c
libxfs/init.h
libxfs/irix.c
libxfs/linux.c
libxlog/xfs_log_recover.c

index ee93c2cbf99d9c2da4e335a7a845d2ff6adb724c..3bf1eb482fbe8c5b75091949eee5a8a10cee86b2 100644 (file)
@@ -22,6 +22,7 @@
 #include <sys/ioctl.h>
 #include <xfs/libxfs.h>
 
+int platform_has_uuid = 1;
 extern char *progname;
 
 int
index 883d0d604ec6d33af840df5f6f2978771f1bbf34..abae71b98120ca93cbb12948389fa73a37ca9bef 100644 (file)
@@ -22,6 +22,7 @@
 #include <sys/mount.h>
 #include <sys/ioctl.h>
 
+int platform_has_uuid = 1;
 extern char *progname;
 
 int
index e0cf92d84bbece0acfeef2f32de9e33e9a4a0673..1cb2b587f0a2681f277a48dc185e1fa3749d4e4c 100644 (file)
@@ -34,5 +34,6 @@ extern int platform_direct_blockdev (void);
 extern int platform_align_blockdev (void);
 extern int platform_aio_init (int aio_count);
 extern int platform_nproc(void);
+extern int platform_has_uuid;
 
 #endif /* LIBXFS_INIT_H */
index 081d636a4156236b948289fa0eb6403fa351ebef..99d75b8e8a94366ad6a538d54620ae50982392ea 100644 (file)
@@ -21,6 +21,7 @@
 #include <diskinfo.h>
 #include <sys/sysmp.h>
 
+int platform_has_uuid = 0;
 extern char *progname;
 extern __int64_t findsize(char *);
 
index de64d333db3ab98536ff705688145b6644e7c59d..ef59c77dbab1a237bbb24b6d8ab3375adef9f65d 100644 (file)
@@ -26,6 +26,7 @@
 #include <sys/mount.h>
 #include <sys/ioctl.h>
 
+int platform_has_uuid = 1;
 extern char *progname;
 static int max_block_alignment;
 
index 040356a0ce7ffb06013bb42c417c7f1c274e2aa9..b26b0e1ca7d04f52e08c2e70850f6e217aabe9ec 100644 (file)
@@ -258,13 +258,14 @@ xlog_find_head(
        uint            first_half_cycle, last_half_cycle;
        uint            stop_on_cycle;
        int             error, log_bbnum = log->l_logBBsize;
+       extern int      platform_has_uuid;
 
        /* Is the end of the log device zeroed? */
        if ((error = xlog_find_zeroed(log, &first_blk)) == -1) {
                *return_head_blk = first_blk;
 
                /* Is the whole lot zeroed? */
-               if (!first_blk) {
+               if (!first_blk && platform_has_uuid) {
                        /* Linux XFS shouldn't generate totally zeroed logs -
                         * mkfs etc write a dummy unmount record to a fresh
                         * log so we can store the uuid in there