~ressu/+junk/xen-debian

« back to all changes in this revision

Viewing changes to tools/libfsimage/zfs/zfs-include/zio.h

  • Committer: sami at haahtinen
  • Author(s): Bastian Blank
  • Date: 2011-03-17 14:12:45 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: sami@haahtinen.name-20110317141245-owgqox0l0p3g5857
Tags: 4.1.0~rc6-1
* New upstream release candidate.
* Build documentation using pdflatex.
* Use python 2.6. (closes: #596545)
* Fix lintian override.
* Install new tools: xl, xenpaging.
* Enable blktap2.
  - Use own md5 implementation.
  - Fix includes.
  - Fix linking of blktap2 binaries.
  - Remove optimization setting.
* Temporarily disable hvmloader, wants to download ipxe.
* Remove xenstored pid check from xl.

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 *  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18
18
 */
19
19
/*
20
 
 * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
 
20
 * Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
21
21
 * Use is subject to license terms.
22
22
 */
23
23
 
24
24
#ifndef _ZIO_H
25
25
#define _ZIO_H
26
26
 
27
 
#define ZBT_MAGIC       0x210da7ab10c7a11ULL    /* zio data bloc tail */
 
27
#define ZEC_MAGIC       0x210da7ab10c7a11ULL    /* zio data bloc tail */
28
28
 
29
 
typedef struct zio_block_tail {
30
 
        uint64_t        zbt_magic;      /* for validation, endianness   */
31
 
        zio_cksum_t     zbt_cksum;      /* 256-bit checksum             */
32
 
} zio_block_tail_t;
 
29
typedef struct zio_eck {
 
30
        uint64_t        zec_magic;      /* for validation, endianness   */
 
31
        zio_cksum_t     zec_cksum;      /* 256-bit checksum             */
 
32
} zio_eck_t;
33
33
 
34
34
/*
35
35
 * Gang block headers are self-checksumming and contain an array
37
37
 */
38
38
#define SPA_GANGBLOCKSIZE       SPA_MINBLOCKSIZE
39
39
#define SPA_GBH_NBLKPTRS        ((SPA_GANGBLOCKSIZE - \
40
 
        sizeof (zio_block_tail_t)) / sizeof (blkptr_t))
 
40
        sizeof (zio_eck_t)) / sizeof (blkptr_t))
41
41
#define SPA_GBH_FILLER          ((SPA_GANGBLOCKSIZE - \
42
 
        sizeof (zio_block_tail_t) - \
 
42
        sizeof (zio_eck_t) - \
43
43
        (SPA_GBH_NBLKPTRS * sizeof (blkptr_t))) /\
44
44
        sizeof (uint64_t))
45
45
 
50
50
typedef struct zio_gbh {
51
51
        blkptr_t                zg_blkptr[SPA_GBH_NBLKPTRS];
52
52
        uint64_t                zg_filler[SPA_GBH_FILLER];
53
 
        zio_block_tail_t        zg_tail;
 
53
        zio_eck_t               zg_tail;
54
54
} zio_gbh_phys_t;
55
55
 
56
56
enum zio_checksum {
63
63
        ZIO_CHECKSUM_FLETCHER_2,
64
64
        ZIO_CHECKSUM_FLETCHER_4,
65
65
        ZIO_CHECKSUM_SHA256,
 
66
        ZIO_CHECKSUM_ZILOG2,
66
67
        ZIO_CHECKSUM_FUNCTIONS
67
68
};
68
69
 
69
 
#define ZIO_CHECKSUM_ON_VALUE   ZIO_CHECKSUM_FLETCHER_2
70
 
#define ZIO_CHECKSUM_DEFAULT    ZIO_CHECKSUM_ON
71
 
 
72
70
enum zio_compress {
73
71
        ZIO_COMPRESS_INHERIT = 0,
74
72
        ZIO_COMPRESS_ON,