Date: Thu, 17 Jan 2013 03:27:08 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r245533 - head/sys/geom/raid Message-ID: <201301170327.r0H3R8pf075324@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mav Date: Thu Jan 17 03:27:08 2013 New Revision: 245533 URL: http://svnweb.freebsd.org/changeset/base/245533 Log: - Fix rebuild position broken at r245522. - Identify one more metadata field. Modified: head/sys/geom/raid/md_promise.c Modified: head/sys/geom/raid/md_promise.c ============================================================================== --- head/sys/geom/raid/md_promise.c Thu Jan 17 03:25:31 2013 (r245532) +++ head/sys/geom/raid/md_promise.c Thu Jan 17 03:27:08 2013 (r245533) @@ -126,7 +126,8 @@ struct promise_raid_conf { uint8_t magic_6; uint8_t sector_size; uint16_t magic_7; - uint32_t magic_8[32]; + uint32_t magic_8[31]; + uint32_t backup_time; uint16_t magic_9; uint32_t disk_offset_high; uint32_t disk_sectors_high; @@ -228,6 +229,7 @@ g_raid_md_promise_print(struct promise_r printf("magic_5 0x%08x\n", meta->magic_5); printf("total_sectors_high 0x%08x\n", meta->total_sectors_high); printf("sector_size %u\n", meta->sector_size); + printf("backup_time %d\n", meta->backup_time); printf("disk_offset_high 0x%08x\n", meta->disk_offset_high); printf("disk_sectors_high 0x%08x\n", meta->disk_sectors_high); printf("disk_rebuild_high 0x%08x\n", meta->disk_rebuild_high); @@ -398,6 +400,7 @@ next: meta->disk_rebuild_high = 0; if (meta->total_sectors_high == 0x15161718) { meta->total_sectors_high = 0; + meta->backup_time = 0; if (meta->rebuild_lba64 == 0x2122232425262728) meta->rebuild_lba64 = UINT64_MAX; } @@ -793,7 +796,7 @@ nofit: sd->sd_rebuild_pos = 0; else { sd->sd_rebuild_pos = - (((off_t)pd->pd_meta[sdn]->disk_rebuild << 32) + + (((off_t)pd->pd_meta[sdn]->disk_rebuild_high << 32) + pd->pd_meta[sdn]->disk_rebuild) * 512; } } else if (!(meta->disks[md_disk_pos].flags & PROMISE_F_ONLINE)) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201301170327.r0H3R8pf075324>