2 * GRUB -- GRand Unified Bootloader
3 * Copyright (C) 1999,2000,2001,2002,2003,2004 Free Software Foundation, Inc.
5 * SPDX-License-Identifier: GPL-2.0+
8 * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
9 * Use is subject to license terms.
18 * Each objset has its own intent log. The log header (zil_header_t)
19 * for objset N's intent log is kept in the Nth object of the SPA's
20 * intent_log objset. The log header points to a chain of log blocks,
21 * each of which contains log records (i.e., transactions) followed by
22 * a log block trailer (zil_trailer_t). The format of a log record
23 * depends on the record (or transaction) type, but all records begin
24 * with a common structure that defines the type, length, and txg.
28 * Intent log header - this on disk structure holds fields to manage
29 * the log. All fields are 64 bit to easily handle cross architectures.
31 typedef struct zil_header {
32 uint64_t zh_claim_txg; /* txg in which log blocks were claimed */
33 uint64_t zh_replay_seq; /* highest replayed sequence number */
34 blkptr_t zh_log; /* log chain */
35 uint64_t zh_claim_seq; /* highest claimed sequence number */
36 uint64_t zh_flags; /* header flags */
41 * zh_flags bit settings
43 #define ZIL_REPLAY_NEEDED 0x1 /* replay needed - internal only */
45 #endif /* _SYS_ZIL_H */