Lines Matching refs:le64toh
105 p = le64toh(f->header->tail_object_offset); in journal_file_tail_end_by_pread()
107 p = le64toh(f->header->header_size); in journal_file_tail_end_by_pread()
116 sz = le64toh(tail.object.size); in journal_file_tail_end_by_pread()
142 p = le64toh(f->header->tail_object_offset); in journal_file_tail_end_by_mmap()
144 p = le64toh(f->header->header_size); in journal_file_tail_end_by_mmap()
153 sz = le64toh(READ_NOW(tail->object.size)); in journal_file_tail_end_by_mmap()
432 header_size = le64toh(READ_NOW(f->header->header_size)); in journal_file_verify_header()
441 arena_size = le64toh(READ_NOW(f->header->arena_size)); in journal_file_verify_header()
446 if (le64toh(f->header->tail_object_offset) > header_size + arena_size) in journal_file_verify_header()
449 if (!VALID64(le64toh(f->header->data_hash_table_offset)) || in journal_file_verify_header()
450 !VALID64(le64toh(f->header->field_hash_table_offset)) || in journal_file_verify_header()
451 !VALID64(le64toh(f->header->tail_object_offset)) || in journal_file_verify_header()
452 !VALID64(le64toh(f->header->entry_array_offset))) in journal_file_verify_header()
486 if (le64toh(f->header->tail_entry_realtime) > now(CLOCK_REALTIME)) in journal_file_verify_header()
534 old_header_size = le64toh(READ_NOW(f->header->header_size)); in journal_file_allocate()
535 old_arena_size = le64toh(READ_NOW(f->header->arena_size)); in journal_file_allocate()
661 if ((le64toh(o->data.entry_offset) == 0) ^ (le64toh(o->data.n_entries) == 0)) in journal_file_check_object()
664 le64toh(o->data.n_entries), in journal_file_check_object()
667 if (le64toh(o->object.size) <= offsetof(Object, data.payload)) in journal_file_check_object()
671 le64toh(o->object.size), in journal_file_check_object()
674 if (!VALID64(le64toh(o->data.next_hash_offset)) || in journal_file_check_object()
675 !VALID64(le64toh(o->data.next_field_offset)) || in journal_file_check_object()
676 !VALID64(le64toh(o->data.entry_offset)) || in journal_file_check_object()
677 !VALID64(le64toh(o->data.entry_array_offset))) in journal_file_check_object()
680 le64toh(o->data.next_hash_offset), in journal_file_check_object()
681 le64toh(o->data.next_field_offset), in journal_file_check_object()
682 le64toh(o->data.entry_offset), in journal_file_check_object()
683 le64toh(o->data.entry_array_offset), in journal_file_check_object()
689 if (le64toh(o->object.size) <= offsetof(Object, field.payload)) in journal_file_check_object()
693 le64toh(o->object.size), in journal_file_check_object()
696 if (!VALID64(le64toh(o->field.next_hash_offset)) || in journal_file_check_object()
697 !VALID64(le64toh(o->field.head_data_offset))) in journal_file_check_object()
700 le64toh(o->field.next_hash_offset), in journal_file_check_object()
701 le64toh(o->field.head_data_offset), in journal_file_check_object()
708 sz = le64toh(READ_NOW(o->object.size)); in journal_file_check_object()
723 if (le64toh(o->entry.seqnum) <= 0) in journal_file_check_object()
726 le64toh(o->entry.seqnum), in journal_file_check_object()
729 if (!VALID_REALTIME(le64toh(o->entry.realtime))) in journal_file_check_object()
732 le64toh(o->entry.realtime), in journal_file_check_object()
735 if (!VALID_MONOTONIC(le64toh(o->entry.monotonic))) in journal_file_check_object()
738 le64toh(o->entry.monotonic), in journal_file_check_object()
748 sz = le64toh(READ_NOW(o->object.size)); in journal_file_check_object()
764 sz = le64toh(READ_NOW(o->object.size)); in journal_file_check_object()
773 if (!VALID64(le64toh(o->entry_array.next_entry_array_offset))) in journal_file_check_object()
776 le64toh(o->entry_array.next_entry_array_offset), in journal_file_check_object()
783 if (le64toh(o->object.size) != sizeof(TagObject)) in journal_file_check_object()
786 le64toh(o->object.size), in journal_file_check_object()
789 if (!VALID_EPOCH(le64toh(o->tag.epoch))) in journal_file_check_object()
792 le64toh(o->tag.epoch), offset); in journal_file_check_object()
815 if (offset < le64toh(f->header->header_size)) in journal_file_move_to_object()
825 s = le64toh(READ_NOW(o->object.size)); in journal_file_move_to_object()
882 if (offset < le64toh(f->header->header_size)) in journal_file_read_object_header()
898 s = le64toh(o.object.size); in journal_file_read_object_header()
949 ret = le64toh(f->header->tail_entry_seqnum) + 1; in journal_file_entry_seqnum()
1009 f->header->n_objects = htole64(le64toh(f->header->n_objects) + 1); in journal_file_append_object()
1094 p = le64toh(f->header->data_hash_table_offset); in journal_file_map_data_hash_table()
1095 s = le64toh(f->header->data_hash_table_size); in journal_file_map_data_hash_table()
1120 p = le64toh(f->header->field_hash_table_offset); in journal_file_map_field_hash_table()
1121 s = le64toh(f->header->field_hash_table_size); in journal_file_map_field_hash_table()
1153 m = le64toh(READ_NOW(f->header->field_hash_table_size)) / sizeof(HashItem); in journal_file_link_field()
1161 p = le64toh(f->field_hash_table[h].tail_hash_offset); in journal_file_link_field()
1175 f->header->n_fields = htole64(le64toh(f->header->n_fields) + 1); in journal_file_link_field()
1198 m = le64toh(READ_NOW(f->header->data_hash_table_size)) / sizeof(HashItem); in journal_file_link_data()
1208 p = le64toh(f->data_hash_table[h].tail_hash_offset); in journal_file_link_data()
1226 f->header->n_data = htole64(le64toh(f->header->n_data) + 1); in journal_file_link_data()
1240 nextp = le64toh(READ_NOW(*next_hash_offset)); in next_hash_offset()
1250 *header_max_depth = htole64(MAX(*depth, le64toh(*header_max_depth))); in next_hash_offset()
1270 if (le64toh(f->header->field_hash_table_size) <= 0) in journal_file_find_field_object_with_hash()
1280 m = le64toh(READ_NOW(f->header->field_hash_table_size)) / sizeof(HashItem); in journal_file_find_field_object_with_hash()
1285 p = le64toh(f->field_hash_table[h].head_hash_offset); in journal_file_find_field_object_with_hash()
1293 if (le64toh(o->field.hash) == hash && in journal_file_find_field_object_with_hash()
1294 le64toh(o->object.size) == osize && in journal_file_find_field_object_with_hash()
1363 if (le64toh(f->header->data_hash_table_size) <= 0) in journal_file_find_data_object_with_hash()
1373 m = le64toh(READ_NOW(f->header->data_hash_table_size)) / sizeof(HashItem); in journal_file_find_data_object_with_hash()
1378 p = le64toh(f->data_hash_table[h].head_hash_offset); in journal_file_find_data_object_with_hash()
1388 if (le64toh(o->data.hash) != hash) in journal_file_find_data_object_with_hash()
1399 l = le64toh(READ_NOW(o->object.size)); in journal_file_find_data_object_with_hash()
1423 } else if (le64toh(o->object.size) == osize && in journal_file_find_data_object_with_hash()
1633 fo->field.head_data_offset = le64toh(p); in journal_file_append_data()
1651 sz = le64toh(READ_NOW(o->object.size)); in journal_file_entry_n_items()
1666 sz = le64toh(READ_NOW(o->object.size)); in journal_file_entry_array_n_items()
1681 sz = le64toh(READ_NOW(o->object.size)); in journal_file_hash_table_n_items()
1702 a = le64toh(*first); in link_entry_into_array()
1703 i = hidx = le64toh(READ_NOW(*idx)); in link_entry_into_array()
1719 a = le64toh(o->entry_array.next_entry_array_offset); in link_entry_into_array()
1755 f->header->n_entry_arrays = htole64(le64toh(f->header->n_entry_arrays) + 1); in link_entry_into_array()
1777 hidx = le64toh(READ_NOW(*idx)); in link_entry_into_array_plus_one()
1803 p = le64toh(o->entry.items[i].object_offset); in journal_file_link_entry_item()
2006 return CMP(le64toh(a->object_offset), le64toh(b->object_offset)); in entry_item_cmp()
2083 xor_hash ^= le64toh(o->data.hash); in journal_file_append_entry()
2190 return le64toh(o->entry_array.next_entry_array_offset); in bump_entry_array()
2203 p = le64toh(o->entry_array.next_entry_array_offset); in bump_entry_array()
2269 a = le64toh(o->entry_array.next_entry_array_offset); in generic_array_get()
2291 p = le64toh(o->entry_array.items[i]); in generic_array_get()
2296 … chain_cache_put(f->chain_cache, ci, first, a, le64toh(o->entry_array.items[0]), t, i); in generic_array_get()
2430 lp = p = le64toh(array->entry_array.items[i]); in generic_array_bisect()
2463 p = le64toh(array->entry_array.items[x]); in generic_array_bisect()
2483 p = le64toh(array->entry_array.items[y]); in generic_array_bisect()
2513 p = le64toh(array->entry_array.items[i]); in generic_array_bisect()
2551 a = le64toh(array->entry_array.next_entry_array_offset); in generic_array_bisect()
2561 …chain_cache_put(f->chain_cache, ci, first, a, le64toh(array->entry_array.items[0]), t, subtract_on… in generic_array_bisect()
2566 p = le64toh(array->entry_array.items[i-1]); in generic_array_bisect()
2568 p = le64toh(array->entry_array.items[i]); in generic_array_bisect()
2680 le64toh(f->header->entry_array_offset), in journal_file_move_to_entry_by_offset()
2681 le64toh(f->header->n_entries), in journal_file_move_to_entry_by_offset()
2700 sq = le64toh(READ_NOW(o->entry.seqnum)); in test_object_seqnum()
2720 le64toh(f->header->entry_array_offset), in journal_file_move_to_entry_by_seqnum()
2721 le64toh(f->header->n_entries), in journal_file_move_to_entry_by_seqnum()
2740 rt = le64toh(READ_NOW(o->entry.realtime)); in test_object_realtime()
2760 le64toh(f->header->entry_array_offset), in journal_file_move_to_entry_by_realtime()
2761 le64toh(f->header->n_entries), in journal_file_move_to_entry_by_realtime()
2780 m = le64toh(READ_NOW(o->entry.monotonic)); in test_object_monotonic()
2822 le64toh(o->data.entry_offset), in journal_file_move_to_entry_by_monotonic()
2823 le64toh(o->data.entry_array_offset), in journal_file_move_to_entry_by_monotonic()
2824 le64toh(o->data.n_entries), in journal_file_move_to_entry_by_monotonic()
2844 f->current_seqnum = le64toh(o->entry.seqnum); in journal_file_save_location()
2845 f->current_realtime = le64toh(o->entry.realtime); in journal_file_save_location()
2846 f->current_monotonic = le64toh(o->entry.monotonic); in journal_file_save_location()
2848 f->current_xor_hash = le64toh(o->entry.xor_hash); in journal_file_save_location()
2925 n = le64toh(READ_NOW(f->header->n_entries)); in journal_file_next_entry()
2933 le64toh(f->header->entry_array_offset), in journal_file_next_entry()
2934 le64toh(f->header->n_entries), in journal_file_next_entry()
2949 r = generic_array_get(f, le64toh(f->header->entry_array_offset), i, direction, ret, &ofs); in journal_file_next_entry()
2978 n = le64toh(READ_NOW(d->data.n_entries)); in journal_file_next_entry_for_data()
2985 le64toh(d->data.entry_offset), in journal_file_next_entry_for_data()
2986 le64toh(d->data.entry_array_offset), in journal_file_next_entry_for_data()
3012 le64toh(d->data.entry_offset), in journal_file_move_to_entry_by_offset_for_data()
3013 le64toh(d->data.entry_array_offset), in journal_file_move_to_entry_by_offset_for_data()
3014 le64toh(d->data.n_entries), in journal_file_move_to_entry_by_offset_for_data()
3038 entry_offset = le64toh(READ_NOW(d->data.entry_offset)); in journal_file_move_to_entry_by_monotonic_for_data()
3039 entry_array_offset = le64toh(READ_NOW(d->data.entry_array_offset)); in journal_file_move_to_entry_by_monotonic_for_data()
3040 n_entries = le64toh(READ_NOW(d->data.n_entries)); in journal_file_move_to_entry_by_monotonic_for_data()
3050 le64toh(o->data.entry_offset), in journal_file_move_to_entry_by_monotonic_for_data()
3051 le64toh(o->data.entry_array_offset), in journal_file_move_to_entry_by_monotonic_for_data()
3052 le64toh(o->data.n_entries), in journal_file_move_to_entry_by_monotonic_for_data()
3082 le64toh(o->data.entry_offset), in journal_file_move_to_entry_by_monotonic_for_data()
3083 le64toh(o->data.entry_array_offset), in journal_file_move_to_entry_by_monotonic_for_data()
3084 le64toh(o->data.n_entries), in journal_file_move_to_entry_by_monotonic_for_data()
3123 le64toh(d->data.entry_offset), in journal_file_move_to_entry_by_seqnum_for_data()
3124 le64toh(d->data.entry_array_offset), in journal_file_move_to_entry_by_seqnum_for_data()
3125 le64toh(d->data.n_entries), in journal_file_move_to_entry_by_seqnum_for_data()
3145 le64toh(d->data.entry_offset), in journal_file_move_to_entry_by_realtime_for_data()
3146 le64toh(d->data.entry_array_offset), in journal_file_move_to_entry_by_realtime_for_data()
3147 le64toh(d->data.n_entries), in journal_file_move_to_entry_by_realtime_for_data()
3164 p = le64toh(READ_NOW(f->header->header_size)); in journal_file_dump()
3182 le64toh(o->entry.seqnum), in journal_file_dump()
3183 le64toh(o->entry.monotonic), in journal_file_dump()
3184 le64toh(o->entry.realtime)); in journal_file_dump()
3192 le64toh(o->tag.seqnum), in journal_file_dump()
3193 le64toh(o->tag.epoch)); in journal_file_dump()
3210 if (p == le64toh(f->header->tail_object_offset)) in journal_file_dump()
3213 p += ALIGN64(le64toh(o->object.size)); in journal_file_dump()
3265 le64toh(f->header->header_size), in journal_file_print_header()
3266 le64toh(f->header->arena_size), in journal_file_print_header()
3267 le64toh(f->header->data_hash_table_size) / sizeof(HashItem), in journal_file_print_header()
3268 le64toh(f->header->field_hash_table_size) / sizeof(HashItem), in journal_file_print_header()
3270 le64toh(f->header->head_entry_seqnum), le64toh(f->header->head_entry_seqnum), in journal_file_print_header()
3271 le64toh(f->header->tail_entry_seqnum), le64toh(f->header->tail_entry_seqnum), in journal_file_print_header()
3272 …FORMAT_TIMESTAMP_SAFE(le64toh(f->header->head_entry_realtime)), le64toh(f->header->head_entry_real… in journal_file_print_header()
3273 …FORMAT_TIMESTAMP_SAFE(le64toh(f->header->tail_entry_realtime)), le64toh(f->header->tail_entry_real… in journal_file_print_header()
3274 …FORMAT_TIMESPAN(le64toh(f->header->tail_entry_monotonic), USEC_PER_MSEC), le64toh(f->header->tail_… in journal_file_print_header()
3275 le64toh(f->header->n_objects), in journal_file_print_header()
3276 le64toh(f->header->n_entries)); in journal_file_print_header()
3281 le64toh(f->header->n_data), in journal_file_print_header()
3282 …100.0 * (double) le64toh(f->header->n_data) / ((double) (le64toh(f->header->data_hash_table_size) … in journal_file_print_header()
3287 le64toh(f->header->n_fields), in journal_file_print_header()
3288 …100.0 * (double) le64toh(f->header->n_fields) / ((double) (le64toh(f->header->field_hash_table_siz… in journal_file_print_header()
3292 le64toh(f->header->n_tags)); in journal_file_print_header()
3295 le64toh(f->header->n_entry_arrays)); in journal_file_print_header()
3681 le64toh(f->header->head_entry_seqnum), in journal_file_archive()
3682 le64toh(f->header->head_entry_realtime)) < 0) in journal_file_archive()
3751 .monotonic = le64toh(o->entry.monotonic), in journal_file_copy_entry()
3752 .realtime = le64toh(o->entry.realtime), in journal_file_copy_entry()
3766 q = le64toh(o->entry.items[i].object_offset); in journal_file_copy_entry()
3772 l = le64toh(READ_NOW(o->object.size)); in journal_file_copy_entry()
3816 xor_hash ^= le64toh(u->data.hash); in journal_file_copy_entry()
3860 *from = le64toh(f->header->head_entry_realtime); in journal_file_get_cutoff_realtime_usec()
3867 *to = le64toh(f->header->tail_entry_realtime); in journal_file_get_cutoff_realtime_usec()
3885 if (le64toh(o->data.n_entries) <= 0) in journal_file_get_cutoff_monotonic_usec()
3889 r = journal_file_move_to_object(f, OBJECT_ENTRY, le64toh(o->data.entry_offset), &o); in journal_file_get_cutoff_monotonic_usec()
3893 *from = le64toh(o->entry.monotonic); in journal_file_get_cutoff_monotonic_usec()
3902 le64toh(o->data.entry_offset), in journal_file_get_cutoff_monotonic_usec()
3903 le64toh(o->data.entry_array_offset), in journal_file_get_cutoff_monotonic_usec()
3904 le64toh(o->data.n_entries) - 1, in journal_file_get_cutoff_monotonic_usec()
3910 *to = le64toh(o->entry.monotonic); in journal_file_get_cutoff_monotonic_usec()
3922 if (le64toh(f->header->header_size) < sizeof(Header)) { in journal_file_rotate_suggested()
3932 …if (le64toh(f->header->n_data) * 4ULL > (le64toh(f->header->data_hash_table_size) / sizeof(HashIte… in journal_file_rotate_suggested()
3936 …100.0 * (double) le64toh(f->header->n_data) / ((double) (le64toh(f->header->data_hash_table_size) … in journal_file_rotate_suggested()
3937 le64toh(f->header->n_data), in journal_file_rotate_suggested()
3938 le64toh(f->header->data_hash_table_size) / sizeof(HashItem), in journal_file_rotate_suggested()
3940 f->last_stat.st_size / le64toh(f->header->n_data)); in journal_file_rotate_suggested()
3945 …if (le64toh(f->header->n_fields) * 4ULL > (le64toh(f->header->field_hash_table_size) / sizeof(Hash… in journal_file_rotate_suggested()
3949 …100.0 * (double) le64toh(f->header->n_fields) / ((double) (le64toh(f->header->field_hash_table_siz… in journal_file_rotate_suggested()
3950 le64toh(f->header->n_fields), in journal_file_rotate_suggested()
3951 le64toh(f->header->field_hash_table_size) / sizeof(HashItem)); in journal_file_rotate_suggested()
3958 le64toh(f->header->data_hash_chain_depth) > HASH_CHAIN_DEPTH_MAX) { in journal_file_rotate_suggested()
3961 f->path, le64toh(f->header->data_hash_chain_depth)); in journal_file_rotate_suggested()
3966 le64toh(f->header->field_hash_chain_depth) > HASH_CHAIN_DEPTH_MAX) { in journal_file_rotate_suggested()
3969 f->path, le64toh(f->header->field_hash_chain_depth)); in journal_file_rotate_suggested()
3976 le64toh(f->header->n_data) > 0 && in journal_file_rotate_suggested()
3977 le64toh(f->header->n_fields) == 0) { in journal_file_rotate_suggested()
3987 h = le64toh(f->header->head_entry_realtime); in journal_file_rotate_suggested()