27#define _RVM_PRIVATE_ 1
45#ifndef HAVE_GETPAGESIZE
47#define getpagesize() PAGE_SIZE
58#define RVM_LOG_VERSION "RVM Log Version 1.4 Oct 17, 1997 "
63#define REALLOC(x, l) (((x) == NULL) ? malloc(l) : realloc((x), (l)))
67#define BCOPY(x, y, n) memcpy((y), (x), (n))
68#define BZERO(x, n) memset((x), 0, (n))
70#define BCOPY(x, y, n) bcopy((x), (y), (n))
71#define BZERO(x, n) bzero((x), (n))
75#define DO_FOREVER for (;;)
77#define FORWARD rvm_true
78#define REVERSE rvm_false
82#define ERR_DATE_SKEW "Current time before last recorded - check kernel date"
86#define TIME_LSS(x, y) \
87 (((x).tv_sec < (y).tv_sec) || \
88 ((((x).tv_sec == (y).tv_sec) && ((x).tv_usec < (y).tv_usec))))
89#define TIME_GTR(x, y) \
90 (((x).tv_sec > (y).tv_sec) || \
91 ((((x).tv_sec == (y).tv_sec) && ((x).tv_usec > (y).tv_usec))))
92#define TIME_LEQ(x, y) (!TIME_GTR((x), (y)))
93#define TIME_GEQ(x, y) (!TIME_LSS((x), (y)))
94#define TIME_EQL(x, y) \
95 (((x).tv_sec == (y).tv_sec) && ((x).tv_usec == (y).tv_usec))
96#define TIME_EQL_ZERO(x) (((x).tv_sec == 0 && ((x).tv_usec == 0)))
128#define LENGTH_MASK ((rvm_length_t)(~(sizeof(rvm_length_t) - 1)))
129#define ROUND_TO_LENGTH(len) \
130 (((rvm_length_t)((rvm_length_t)(len) + sizeof(rvm_length_t) - 1)) & \
132#define CHOP_TO_LENGTH(len) ((rvm_length_t)((rvm_length_t)(len) & LENGTH_MASK))
133#define ALIGNED_LEN(addr, len) \
134 (ROUND_TO_LENGTH((rvm_length_t)(addr) + (rvm_length_t)(len)) - \
135 CHOP_TO_LENGTH(addr))
136#define BYTE_SKEW(len) ((rvm_length_t)(len) & ~LENGTH_MASK)
138#define SECTOR_SIZE 512
139#define SECTOR_MASK ((rvm_length_t)(~(SECTOR_SIZE - 1)))
140#define ROUND_TO_SECTOR_SIZE(x) \
141 (((rvm_length_t)(x) + SECTOR_SIZE - 1) & SECTOR_MASK)
142#define CHOP_TO_SECTOR_SIZE(x) ((rvm_length_t)(x) & SECTOR_MASK)
144#define SECTOR_INDEX(x) ((x) & (SECTOR_SIZE - 1))
146#define ROUND_OFFSET_TO_SECTOR_SIZE(x) rvm_rnd_offset_to_sector(&(x))
148#define CHOP_OFFSET_TO_SECTOR_SIZE(x) \
149 (RVM_MK_OFFSET(RVM_OFFSET_HIGH_BITS_TO_LENGTH(x), \
150 CHOP_TO_SECTOR_SIZE(RVM_OFFSET_TO_LENGTH(x))))
152#define OFFSET_TO_SECTOR_INDEX(x) (SECTOR_INDEX(RVM_OFFSET_TO_LENGTH((x))))
154#define CHOP_OFFSET_TO_LENGTH_SIZE(x) \
155 (RVM_MK_OFFSET(RVM_OFFSET_HIGH_BITS_TO_LENGTH(x), \
156 CHOP_TO_LENGTH(RVM_OFFSET_TO_LENGTH(x))))
158#define ROUND_TO_PAGE_SIZE(x) (((rvm_length_t)(x) + page_size - 1) & page_mask)
159#define CHOP_TO_PAGE_SIZE(x) ((rvm_length_t)(x) & page_mask)
163#define OFFSET_TO_FLOAT(x) \
164 ((4.294967e+9) * ((float)(RVM_OFFSET_HIGH_BITS_TO_LENGTH(x))) + \
165 (float)(RVM_OFFSET_TO_LENGTH(x)))
206#define ID_INDEX(id) ((rvm_length_t)(id) - (rvm_length_t)struct_first_id - 1)
207#define INDEX_ID(i) ((struct_id_t)((i) + 1 + (long)struct_first_id))
210#define NUM_CACHE_TYPES \
211 ((rvm_length_t)struct_last_cache_id - (rvm_length_t)struct_first_id - 1)
213 ((rvm_length_t)struct_last_id - (rvm_length_t)struct_first_id - 1)
219#define NUM_PRE_ALLOCATED \
236#define MAX_ALLOCATED \
253#define CACHE_TYPE_SIZES \
260 sizeof(rvm_region_t), \
261 sizeof(rvm_options_t), \
262 sizeof(rvm_statistics_t), \
263 sizeof(mem_region_t), \
264 sizeof(dev_region_t), \
265 sizeof(log_special_t)
267#define OTHER_TYPE_SIZES \
269 sizeof(log_status_t), \
270 sizeof(log_dev_status_t), \
271 sizeof(log_wrap_t), \
273 sizeof(seg_dict_t), \
274 sizeof(trans_hdr_t), \
276 sizeof(nv_range_t), \
278 sizeof(free_page_t), \
279 sizeof(rw_qentry_t), \
292 "statistics_rvm_id", \
296 "struct_last_cache_id", \
298 "log_dev_status_id", \
331#define LIST_EMPTY(lst) ((lst).list.length == 0)
332#define LIST_NOT_EMPTY(lst) ((lst).list.length != 0)
335#define FOR_ENTRIES_OF(lst, type, ptr) \
336 for ((ptr) = (type *)((lst).nextentry); !((ptr)->links.is_hdr); \
337 (ptr) = (type *)((ptr)->links.nextentry))
339#define FOR_REVERSE_ENTRIES_OF(lst, type, ptr) \
340 for ((ptr) = (type *)((lst).preventry); !((ptr)->links.is_hdr); \
341 (ptr) = (type *)((ptr)->links.preventry))
344#define UNLINK_ENTRIES_OF(lst, type, ptr) \
345 for ((ptr) = (type *)((lst).nextentry); !((ptr)->links.is_hdr); \
346 (ptr) = (type *)((lst).nextentry))
348#define UNLINK_REVERSE_ENTRIES_OF(lst, type, \
350 for ((ptr) = (type *)((lst).preventry); !((ptr)->links.is_hdr); \
351 (ptr) = (type *)((lst).preventry))
380#elif defined(RVM_USEPT)
386#define RVM_MUTEX struct mutex
387#define RVM_CONDITION struct condition
390#define LOCK_FREE(lck) \
391 (mutex_try_lock(&(lck)) ? (mutex_unlock(&(lck)), rvm_true) : rvm_false)
398#define CRITICAL(lck, body) \
400 mutex_lock(&(lck)); \
402 mutex_unlock(&(lck)); \
441#define RW_CRITICAL(rwl, mode, body) \
443 rw_lock(&(rwl), (mode)); \
445 rw_unlock(&(rwl), (mode)); \
449#define RW_LOCK_FREE(rwl) \
450 (((rwl).read_cnt + (rwl).write_cnt) == 0) && ((rwl).lock_mode == f)
496#define TRAVERSE_LEN_INCR 15
503#define FOR_NODES_OF(tree, type, ptr) \
504 for ((ptr) = (type *)init_tree_generator(&(tree), FORWARD, rvm_false); \
505 (ptr) != NULL; (ptr) = (type *)tree_successor(&(tree)))
507#define FOR_REVERSE_NODES_OF(tree, type, \
509 for ((ptr) = (type *)init_tree_generator(&(tree), REVERSE, rvm_false); \
510 (ptr) != NULL; (ptr) = (type *)tree_predecessor(&(tree)))
513#define FROM_EXISTING_NODE_OF(tree, type, ptr, node, cmp) \
514 for ((ptr) = (type *)tree_iterate_insert(&(tree), (node), (cmp)); \
515 (ptr) != NULL; (ptr) = (type *)tree_successor(&(tree)))
517#define UNLINK_NODES_OF(tree, type, ptr) \
518 for ((ptr) = (type *)init_tree_generator(&(tree), FORWARD, rvm_true); \
519 (ptr) != NULL; (ptr) = (type *)tree_successor(&(tree)))
521#define UNLINK_REVERSE_NODES_OF(tree, type, \
523 for ((ptr) = (type *)init_tree_generator(&(tree), REVERSE, rvm_true); \
524 (ptr) != NULL; (ptr) = (type *)tree_predecessor(&(tree)))
537#define NV_BUF_SIZE(len) (ROUND_TO_LENGTH((len)) + sizeof(nv_buf_t))
570 struct timeval timestamp;
579 struct timeval uname;
580 struct timeval commit_stamp;
672#define RANGE_LEN(range) (ALIGNED_LEN((range)->nv.vmaddr, (range)->nv.length))
674#define RANGE_SIZE(range) ((rvm_length_t)(NV_RANGE_OVERHEAD + RANGE_LEN(range)))
676#define TRANS_SIZE (ROUND_TO_LENGTH((sizeof(trans_hdr_t) + sizeof(rec_end_t))))
678#define NV_RANGE_OVERHEAD (ROUND_TO_LENGTH(sizeof(nv_range_t)))
680#define MIN_NV_RANGE_SIZE (NV_RANGE_OVERHEAD + 64)
682#define MIN_TRANS_SIZE \
683 (TRANS_SIZE + MIN_NV_RANGE_SIZE + ROUND_TO_LENGTH(sizeof(log_wrap_t)))
685#define LOG_SPECIAL_SIZE \
686 (ROUND_TO_LENGTH(sizeof(log_special_t) - sizeof(list_entry_t)))
688#define LOG_SPECIAL_IOV_MAX 3
691#define MAX_HDR_SIZE (ROUND_TO_LENGTH((sizeof(log_special_t) + MAXPATHLEN)))
695#define NV_LOCAL_MAX \
696 (8 * 1024 - ROUND_TO_LENGTH(NV_BUF_SIZE(sizeof(rvm_length_t) + 1)))
699#define LOG_DEV_STATUS_SIZE ROUND_TO_SECTOR_SIZE(sizeof(log_dev_status_t))
702#define RAW_STATUS_OFFSET 16 * SECTOR_SIZE
703#define FILE_STATUS_OFFSET 0
705#define UPDATE_STATUS 100
708#ifdef RVM_LOG_TAIL_SHADOW
711#define RVM_ASSIGN_OFFSET(x, y) (x) = (y)
729 struct timeval status_init;
730 struct timeval status_write;
731 struct timeval last_trunc;
732 struct timeval prev_trunc;
733 struct timeval first_write;
734 struct timeval last_write;
735 struct timeval first_uname;
736 struct timeval last_uname;
737 struct timeval last_commit;
738 struct timeval wrap_time;
764 struct timeval flush_time;
815 struct timeval tot_flush_time;
816 struct timeval tot_truncation_time;
854#define RVM_FLUSH_CALL (1)
856#define RVM_FLUSH_COMMIT (2)
858#define RVM_RECOVERY (4)
859#define RVM_TRUNCATE_CALL (010)
861#define RVM_ASYNC_TRUNCATE (020)
863#define RVM_SYNC_TRUNCATE (040)
865#define RVM_TRUNC_FIND_TAIL (0100)
867#define RVM_TRUNC_BUILD_TREE (0200)
869#define RVM_TRUNC_APPLY (0400)
871#define RVM_TRUNC_UPDATE (01000)
873#define RVM_TRUNC_PHASES \
874 (RVM_TRUNC_FIND_TAIL | RVM_TRUNC_BUILD_TREE | RVM_TRUNC_APPLY | \
886 struct timeval timestamp;
893 struct timeval prev_timestamp;
901#define SYNCH rvm_true
902#define NO_SYNCH rvm_false
994#define SEG_DICT_INDEX(x) ((x) - 1)
1032 struct timeval uname;
1033 struct timeval commit_stamp;
1038 long x_ranges_alloc;
1051#define RESTORE_FLAG (2 * RVM_COALESCE_TRANS)
1052#define FLUSH_FLAG (2 * RESTORE_FLAG)
1053#define FIRST_ENTRY_FLAG (2 * FLUSH_FLAG)
1054#define LAST_ENTRY_FLAG (2 * FIRST_ENTRY_FLAG)
1055#define FLUSH_MARK (2 * LAST_ENTRY_FLAG)
1057#define TID(x) ((tid->flags & (x)) != 0)
1058#define TRANS_HDR(x) ((trans_hdr->flags & (x)) != 0)
1228struct timeval
add_times(struct timeval *
x,
struct timeval *
y);
1229struct timeval
sub_times(struct timeval *
x,
struct timeval *
y);
1258 SYSTEM_INFO nt_info;
1259 GetSystemInfo(&nt_info);
long cthread_t
Definition: cthreads.h:99
level
Definition: make_certs.py:100
void(* type)()
Definition: rp2main.c:424
int rvm_return_t
Definition: rvm.h:94
#define RVM_VERSION_MAX
Definition: rvm.h:32
rvm_bool_t
Definition: rvm.h:60
rvm_mode_t
Definition: rvm.h:82
unsigned long rvm_length_t
Definition: rvm.h:140
rvm_length_t page_size
Definition: rvm_map.c:67
rvm_length_t page_mask
Definition: rvm_map.c:68
void log_daemon(void *)
Definition: rvm_logrecovr.c:2746
void init_list_header(list_entry_t *whichlist, struct_id_t struct_id)
Definition: rvm_utils.c:93
long read_dev(device_t *dev, rvm_offset_t *offset, char *dest, rvm_length_t length)
Definition: rvm_io.c:226
rvm_return_t open_log(char *dev_name, log_t **log_ptr, char *status_buf, rvm_options_t *rvm_options)
Definition: rvm_logstatus.c:325
rvm_return_t create_log(log_t **log_ptr, rvm_options_t *rvm_options)
rvm_return_t define_all_segs(log_t *log)
Definition: rvm_map.c:530
region_t * make_region(void)
Definition: rvm_utils.c:365
rvm_bool_t rvm_register_page(char *vmaddr, rvm_length_t length)
Definition: rvm_map.c:165
rvm_return_t queue_special(log_t *log, log_special_t *special)
Definition: rvm_logflush.c:667
range_t * make_range(void)
Definition: rvm_utils.c:694
struct_id_t
Definition: rvm_private.h:168
@ log_id
Definition: rvm_private.h:172
@ int_tid_id
Definition: rvm_private.h:173
@ range_id
Definition: rvm_private.h:175
@ options_rvm_id
Definition: rvm_private.h:179
@ mem_region_id
Definition: rvm_private.h:181
@ tid_rvm_id
Definition: rvm_private.h:174
@ struct_last_cache_id
Definition: rvm_private.h:185
@ region_rvm_id
Definition: rvm_private.h:178
@ dev_region_id
Definition: rvm_private.h:182
@ seg_id
Definition: rvm_private.h:176
@ log_dev_status_id
Definition: rvm_private.h:190
@ log_status_id
Definition: rvm_private.h:189
@ trans_hdr_id
Definition: rvm_private.h:194
@ log_special_id
Definition: rvm_private.h:183
@ nv_range_id
Definition: rvm_private.h:196
@ struct_first_id
Definition: rvm_private.h:169
@ seg_dict_id
Definition: rvm_private.h:193
@ free_page_id
Definition: rvm_private.h:198
@ tree_root_id
Definition: rvm_private.h:200
@ struct_last_id
Definition: rvm_private.h:202
@ log_seg_id
Definition: rvm_private.h:192
@ statistics_rvm_id
Definition: rvm_private.h:180
@ region_id
Definition: rvm_private.h:177
@ rw_qentry_id
Definition: rvm_private.h:199
@ log_wrap_id
Definition: rvm_private.h:191
@ nv_buf_id
Definition: rvm_private.h:197
@ rec_end_id
Definition: rvm_private.h:195
rvm_return_t rvm_map(rvm_region_t *rvm_region, rvm_options_t *rvm_options)
Definition: rvm_map.c:922
void free_range(range_t *range)
Definition: rvm_utils.c:712
rvm_return_t scan_nv_forward(log_t *log, rvm_bool_t synch)
Definition: rvm_logrecovr.c:648
tree_node_t * tree_predecessor(tree_root_t *tree)
Definition: rvm_utils.c:1970
rvm_return_t validate_rec_reverse(log_t *log, rvm_bool_t synch)
Definition: rvm_logrecovr.c:922
void clear_free_lists(void)
Definition: rvm_utils.c:266
rvm_return_t enter_seg_dict(log_t *log, long seg_code)
Definition: rvm_logrecovr.c:1375
long cur_log_percent(log_t *log, rvm_offset_t *space_needed)
Definition: rvm_logstatus.c:954
rvm_return_t read_log_status(log_t *log, char *status_buf)
Definition: rvm_logstatus.c:653
void init_rw_lock(rw_lock_t *rwl)
Definition: rvm_utils.c:1194
#define RVM_MUTEX
Definition: rvm_private.h:385
void init_map_roots(void)
Definition: rvm_map.c:80
struct tree_node_s tree_node_t
rvm_return_t scan_reverse(log_t *log, rvm_bool_t synch)
Definition: rvm_logrecovr.c:997
void cur_log_length(log_t *log, rvm_offset_t *length)
Definition: rvm_logstatus.c:939
long open_dev(device_t *dev, long flags, long mode)
Definition: rvm_io.c:177
seg_t * make_seg(char *seg_dev_name, rvm_return_t *retval)
Definition: rvm_utils.c:459
#define RVM_CONDITION
Definition: rvm_private.h:386
rvm_return_t flush_log(log_t *log, rvm_length_t *count)
Definition: rvm_logflush.c:569
long gather_write_dev(device_t *dev, rvm_offset_t *offset)
Definition: rvm_io.c:483
struct timeval add_times(struct timeval *x, struct timeval *y)
Definition: rvm_utils.c:328
void copy_log_stats(log_t *log)
Definition: rvm_logstatus.c:465
rvm_return_t dev_init(device_t *dev, char *dev_str)
Definition: rvm_utils.c:430
void dest_aligned_bcopy(char *src, char *dest, rvm_length_t len)
Definition: rvm_utils.c:1183
rvm_return_t load_aux_buf(log_t *log, rvm_offset_t *offset, rvm_length_t length, rvm_length_t *aux_ptr, rvm_length_t *data_len, rvm_bool_t direction, rvm_bool_t synch)
Definition: rvm_logrecovr.c:392
void free_region(region_t *region)
Definition: rvm_utils.c:377
rvm_return_t bad_statistics(rvm_statistics_t *rvm_statistics)
Definition: rvm_status.c:81
long dev_partial_include(rvm_offset_t *base1, rvm_offset_t *end1, rvm_offset_t *base2, rvm_offset_t *end2)
Definition: rvm_map.c:594
rvm_return_t init_log_status(log_t *log)
Definition: rvm_logstatus.c:562
void enter_histogram(long val, rvm_length_t *histo, rvm_length_t *histo_def, long length)
Definition: rvm_utils.c:2096
tree_root_t region_tree
Definition: rvm_map.c:63
rvm_return_t do_log_options(log_t **log, rvm_options_t *rvm_options)
Definition: rvm_logstatus.c:415
rvm_return_t bad_region(rvm_region_t *rvm_region)
Definition: rvm_map.c:95
rvm_return_t init_buffer(log_t *log, rvm_offset_t *offset, rvm_bool_t direction, rvm_bool_t synch)
Definition: rvm_logrecovr.c:178
traverse_state_t
Definition: rvm_private.h:466
@ gtr
Definition: rvm_private.h:469
@ init
Definition: rvm_private.h:470
@ self
Definition: rvm_private.h:468
@ lss
Definition: rvm_private.h:467
daemon_state_t
Definition: rvm_private.h:905
@ rvm_idle
Definition: rvm_private.h:906
@ terminate
Definition: rvm_private.h:909
@ init_truncate
Definition: rvm_private.h:907
@ error
Definition: rvm_private.h:910
@ truncating
Definition: rvm_private.h:908
long close_dev(device_t *dev)
Definition: rvm_io.c:203
seg_t * seg_lookup(char *dev_name, rvm_return_t *retval)
Definition: rvm_map.c:475
void page_free(char *vmaddr, rvm_length_t length)
Definition: rvm_map.c:365
rvm_length_t chk_sum(char *nvaddr, rvm_length_t len)
Definition: rvm_utils.c:1144
tree_node_t * tree_successor(tree_root_t *tree)
Definition: rvm_utils.c:1907
tree_node_t * tree_iterate_insert(tree_root_t *tree, tree_node_t *node, cmp_func_t *cmp)
Definition: rvm_utils.c:2052
rw_lock_mode_t
Definition: rvm_private.h:413
@ r
Definition: rvm_private.h:414
@ f
Definition: rvm_private.h:416
@ w
Definition: rvm_private.h:415
long round_time(struct timeval *x)
Definition: rvm_utils.c:356
long dev_total_include(rvm_offset_t *base1, rvm_offset_t *end1, rvm_offset_t *base2, rvm_offset_t *end2)
Definition: rvm_map.c:606
struct list_entry_s list_entry_t
dev_region_t * make_dev_region(void)
Definition: rvm_utils.c:805
rvm_bool_t bad_init(void)
Definition: rvm_init.c:41
#define getpagesize()
Definition: rvm_private.h:47
rvm_return_t close_all_segs(void)
Definition: rvm_map.c:449
rvm_bool_t chk_hdr_sequence(log_t *log, rec_hdr_t *rec_hdr, rvm_bool_t direction)
Definition: rvm_logrecovr.c:544
void log_tail_sngl_w(log_t *log, rvm_offset_t *tail_length)
Definition: rvm_logstatus.c:917
rvm_return_t wait_for_truncation(log_t *log, struct timeval *time_stamp)
Definition: rvm_logrecovr.c:2693
void src_aligned_bcopy(char *src, char *dest, rvm_length_t len)
Definition: rvm_utils.c:1174
long cmp_func_t(tree_node_t *node1, tree_node_t *node2)
Definition: rvm_private.h:559
void free_seg_dict_vec(log_t *log)
Definition: rvm_utils.c:511
rvm_bool_t rvm_unregister_page(char *vmaddr, rvm_length_t length)
Definition: rvm_map.c:263
void log_tail_length(log_t *log, rvm_offset_t *tail_length)
Definition: rvm_logstatus.c:890
void rw_lock(rw_lock_t *rwl, rw_lock_mode_t mode)
Definition: rvm_utils.c:1215
log_t * make_log(char *dev_name, rvm_return_t *retval)
Definition: rvm_utils.c:576
int_tid_t * make_tid(rvm_mode_t mode)
Definition: rvm_utils.c:729
rvm_return_t def_seg_dict(log_t *log, rec_hdr_t *rec_hdr)
Definition: rvm_logrecovr.c:1406
long mem_total_include(tree_node_t *tnode1, tree_node_t *tnode2)
Definition: rvm_map.c:641
struct rvm_page_entry rvm_page_entry_t
rvm_return_t write_log_status(log_t *log, device_t *dev)
Definition: rvm_logstatus.c:706
void free_mem_region(mem_region_t *node)
Definition: rvm_utils.c:794
void reset_hdr_chks(log_t *log)
Definition: rvm_logrecovr.c:535
rvm_return_t log_recover(log_t *log, rvm_length_t *count, rvm_bool_t is_daemon, rvm_length_t flag)
Definition: rvm_logrecovr.c:2483
tree_node_t * init_tree_generator(tree_root_t *tree, rvm_bool_t direction, rvm_bool_t unlink)
Definition: rvm_utils.c:2033
char * make_full_name(char *dev_str, char *dev_name, rvm_return_t *retval)
Definition: rvm_utils.c:388
rvm_return_t update_log_tail(log_t *log, rec_hdr_t *rec_hdr)
Definition: rvm_logstatus.c:817
void clear_aux_buf(log_t *log)
Definition: rvm_logrecovr.c:493
rvm_return_t close_log(log_t *log)
Definition: rvm_logstatus.c:234
rvm_return_t close_all_logs(void)
Definition: rvm_logstatus.c:286
rvm_return_t scan_wrap_reverse(log_t *log, rvm_bool_t synch)
Definition: rvm_logrecovr.c:868
void make_uname(struct timeval *time)
Definition: rvm_utils.c:279
void rvm_monitor_call_t()
Definition: rvm_private.h:116
rvm_offset_t rvm_rnd_offset_to_sector(rvm_offset_t *x)
Definition: rvm_utils.c:2217
void free_log_special(log_special_t *special)
Definition: rvm_utils.c:674
list_entry_t * alloc_list_entry(struct_id_t id)
Definition: rvm_utils.c:201
char * page_alloc(rvm_length_t len)
Definition: rvm_map.c:325
list_entry_t * move_list_entry(list_entry_t *fromptr, list_entry_t *toptr, list_entry_t *cell)
Definition: rvm_utils.c:130
rvm_return_t bad_options(rvm_options_t *rvm_options, rvm_bool_t chk_log_dev)
Definition: rvm_status.c:91
rvm_return_t bad_tid(rvm_tid_t *rvm_tid)
Definition: rvm_trans.c:42
struct timeval sub_times(struct timeval *x, struct timeval *y)
Definition: rvm_utils.c:341
rvm_bool_t validate_hdr(log_t *log, rec_hdr_t *rec_hdr, rec_end_t *rec_end, rvm_bool_t direction)
Definition: rvm_logrecovr.c:603
rvm_bool_t tree_insert(tree_root_t *tree, tree_node_t *node, cmp_func_t *cmp)
Definition: rvm_utils.c:1542
rvm_bool_t initiate_truncation(log_t *log, rvm_length_t threshold)
Definition: rvm_logrecovr.c:2666
long init_unames(void)
Definition: rvm_utils.c:293
void free_seg(seg_t *seg)
Definition: rvm_utils.c:483
void rw_unlock(rw_lock_t *rwl, rw_lock_mode_t mode)
Definition: rvm_utils.c:1270
mem_region_t * make_mem_region(void)
Definition: rvm_utils.c:782
rvm_bool_t chk_hdr_currency(log_t *log, rec_hdr_t *rec_hdr)
Definition: rvm_logrecovr.c:517
log_special_t * make_log_special(struct_id_t special_id, rvm_length_t length)
Definition: rvm_utils.c:644
void enter_log(log_t *log)
Definition: rvm_logstatus.c:105
rvm_bool_t rvm_signal_call_t()
Definition: rvm_private.h:113
rvm_return_t alloc_log_buf(log_t *log)
Definition: rvm_logrecovr.c:119
long sync_dev(device_t *dev)
Definition: rvm_io.c:508
long write_dev(device_t *dev, rvm_offset_t *offset, char *src, rvm_length_t length, rvm_bool_t no_sync)
Definition: rvm_io.c:285
tree_node_t * tree_lookup(tree_root_t *tree, tree_node_t *node, cmp_func_t *cmp)
Definition: rvm_utils.c:1422
void free_log(log_t *log)
Definition: rvm_utils.c:527
rw_lock_t region_tree_lock
Definition: rvm_map.c:62
void free_tid(int_tid_t *tid)
Definition: rvm_utils.c:757
void free_dev_region(dev_region_t *node)
Definition: rvm_utils.c:820
void init_tree_root(tree_root_t *root)
Definition: rvm_utils.c:1363
rvm_return_t do_rvm_options(rvm_options_t *rvm_options)
Definition: rvm_status.c:106
region_t * find_whole_range(char *dest, rvm_length_t length, rw_lock_mode_t mode)
Definition: rvm_map.c:670
rvm_return_t scan_forward(log_t *log, rvm_bool_t synch)
Definition: rvm_logrecovr.c:813
long init_utils(void)
Definition: rvm_utils.c:315
void init_log_list(void)
Definition: rvm_logstatus.c:90
long set_dev_char(device_t *dev, rvm_offset_t *dev_length)
Definition: rvm_io.c:119
void rvm_debug(rvm_length_t val)
Definition: rvm_debug.c:73
rvm_bool_t tree_delete(tree_root_t *tree, tree_node_t *node, cmp_func_t *cmp)
Definition: rvm_utils.c:1745
void clear_log_status(log_t *log)
Definition: rvm_logstatus.c:536
void free_log_buf(log_t *log)
Definition: rvm_logrecovr.c:157
rvm_return_t locate_tail(log_t *log)
Definition: rvm_logrecovr.c:1178
#define trans_coalesces_len
Definition: rvm_statistics.h:63
#define range_overlaps_len
Definition: rvm_statistics.h:47
#define flush_times_len
Definition: rvm_statistics.h:35
#define range_elims_len
Definition: rvm_statistics.h:57
rvm_return_t rvm_statistics(const char *version, rvm_statistics_t *statistics)
Definition: rvm_status.c:250
#define range_lengths_len
Definition: rvm_statistics.h:43
#define truncation_times_len
Definition: rvm_statistics.h:39
#define trans_elims_len
Definition: rvm_statistics.h:60
Definition: rvm_private.h:105
unsigned long format
Definition: rvm_private.h:108
int radix
Definition: rvm_private.h:109
char * vmaddr
Definition: rvm_private.h:106
rvm_length_t length
Definition: rvm_private.h:107
Definition: rvm_private.h:539
Definition: rvm_private.h:643
Definition: codamergedump.cc:54
Definition: rvm_private.h:353
Definition: rvm_private.h:1026
Definition: rvm_private.h:318
long length
Definition: rvm_private.h:323
rvm_bool_t is_hdr
Definition: rvm_private.h:326
struct_id_t struct_id
Definition: rvm_private.h:325
union list_entry_s::@54 list
struct list_entry_s * name
Definition: rvm_private.h:322
struct list_entry_s * preventry
Definition: rvm_private.h:320
struct list_entry_s * nextentry
Definition: rvm_private.h:319
Definition: rvm_private.h:877
Definition: rvm_private.h:913
Definition: rvm_private.h:842
Definition: rvm_private.h:606
Definition: rvm_private.h:617
Definition: rvm_private.h:713
Definition: rvm_private.h:925
Definition: rvm_private.h:637
Definition: rvm_private.h:551
Definition: cthreads.h:46
Definition: rvm_private.h:527
Definition: rvm_private.h:585
Definition: rvm_private.h:1015
Definition: rvm_private.h:629
Definition: rvm_private.h:566
Definition: rvm_private.h:995
seg_t * seg
Definition: rvm_private.h:999
list_entry_t links
Definition: rvm_private.h:996
rw_lock_t region_lock
Definition: rvm_private.h:998
rvm_length_t length
Definition: rvm_private.h:1004
rvm_bool_t dirty
Definition: rvm_private.h:1009
rvm_offset_t end_offset
Definition: rvm_private.h:1002
mem_region_t * mem_region
Definition: rvm_private.h:1000
rvm_bool_t no_copy
Definition: rvm_private.h:1005
RVM_MUTEX count_lock
Definition: rvm_private.h:1007
rvm_offset_t offset
Definition: rvm_private.h:1001
struct timeval unmap_ts
Definition: rvm_private.h:1011
long n_uncommit
Definition: rvm_private.h:1008
char * vmaddr
Definition: rvm_private.h:1003
Definition: rvm_private.h:1061
char * end
Definition: rvm_private.h:1063
struct rvm_page_entry * next
Definition: rvm_private.h:1065
char * start
Definition: rvm_private.h:1062
struct rvm_page_entry * prev
Definition: rvm_private.h:1064
Definition: rvm_statistics.h:67
Definition: rvm_private.h:420
Definition: rvm_private.h:429
Definition: rvm_private.h:983
seg_t * seg
Definition: rvm_private.h:985
tree_root_t mod_tree
Definition: rvm_private.h:988
long seg_code
Definition: rvm_private.h:987
device_t dev
Definition: rvm_private.h:986
struct_id_t struct_id
Definition: rvm_private.h:984
Definition: rvm_private.h:964
Definition: rvm_private.h:575
Definition: rvm_private.h:453
struct tree_node_s * lss
Definition: rvm_private.h:454
struct_id_t struct_id
Definition: rvm_private.h:457
struct tree_node_s * gtr
Definition: rvm_private.h:455
long bf
Definition: rvm_private.h:456
Definition: rvm_private.h:474
Definition: rvm_private.h:480
rvm_region_t * region
Definition: testrvm.c:34
rvm_bool_t in_recovery
Definition: testrvm.c:35
Definition: rvm_private.h:460