Lines Matching refs:lrh
396 struct LFS_RECORD_HDR *lrh; // Log record header of the current lsn. member
407 kfree(lcb->lrh); in lcb_put()
2369 struct LFS_RECORD_HDR *rh = lcb->lrh; in find_log_rec()
2377 lcb->lrh = rh; in find_log_rec()
2486 hdr = lcb->lrh; in find_client_next_lsn()
2503 if (hdr != lcb->lrh) in find_client_next_lsn()
2516 kfree(lcb->lrh); in find_client_next_lsn()
2517 lcb->lrh = hdr; in find_client_next_lsn()
2524 if (hdr != lcb->lrh) in find_client_next_lsn()
2549 kfree(lcb->lrh); in find_client_next_lsn()
2550 lcb->lrh = hdr; in find_client_next_lsn()
2573 kfree(lcb->lrh); in read_next_log_rec()
2574 lcb->lrh = NULL; in read_next_log_rec()
2814 const struct LOG_REC_HDR *lrh) in check_if_attr() argument
2816 u16 ro = le16_to_cpu(lrh->record_off); in check_if_attr()
2838 const struct LOG_REC_HDR *lrh) in check_if_index_root() argument
2840 u16 ro = le16_to_cpu(lrh->record_off); in check_if_index_root()
2863 const struct LOG_REC_HDR *lrh) in check_if_root_index() argument
2865 u16 ao = le16_to_cpu(lrh->attr_off); in check_if_root_index()
3017 const struct LOG_REC_HDR *lrh, u32 op, void *data, in do_action() argument
3038 u16 roff = le16_to_cpu(lrh->record_off); in do_action()
3039 u16 aoff = le16_to_cpu(lrh->attr_off); in do_action()
3041 u64 cbo = (u64)le16_to_cpu(lrh->cluster_off) << SECTOR_SHIFT; in do_action()
3042 u64 tvo = le64_to_cpu(lrh->target_vcn) << sbi->cluster_bits; in do_action()
3154 lco = (u64)le16_to_cpu(lrh->lcns_follow) << sbi->cluster_bits; in do_action()
3204 if (!check_if_attr(rec, lrh) || roff + dlen > record_size) in do_action()
3218 if (!check_if_attr(rec, lrh) || dlen < SIZEOF_RESIDENT || in do_action()
3220 Add2Ptr(attr2, asize) > Add2Ptr(lrh, rec_len) || in do_action()
3254 if (!check_if_attr(rec, lrh)) in do_action()
3269 if (!check_if_attr(rec, lrh)) in do_action()
3275 if (lrh->redo_len == lrh->undo_len) { in do_action()
3293 used - le16_to_cpu(lrh->record_off) - asize); in do_action()
3323 if (!check_if_attr(rec, lrh) || !attr->non_res || in do_action()
3332 used - le16_to_cpu(lrh->record_off) - asize); in do_action()
3352 if (!check_if_attr(rec, lrh) || !attr->non_res) in do_action()
3381 if (!check_if_index_root(rec, lrh) || in do_action()
3382 !check_if_root_index(attr, hdr, lrh) || in do_action()
3383 Add2Ptr(data, esize) > Add2Ptr(lrh, rec_len) || in do_action()
3388 e1 = Add2Ptr(attr, le16_to_cpu(lrh->attr_off)); in do_action()
3408 if (!check_if_index_root(rec, lrh) || in do_action()
3409 !check_if_root_index(attr, hdr, lrh)) { in do_action()
3413 e1 = Add2Ptr(attr, le16_to_cpu(lrh->attr_off)); in do_action()
3432 if (!check_if_index_root(rec, lrh) || in do_action()
3433 !check_if_root_index(attr, hdr, lrh)) { in do_action()
3437 e = Add2Ptr(attr, le16_to_cpu(lrh->attr_off)); in do_action()
3447 if (!check_if_index_root(rec, lrh) || in do_action()
3448 !check_if_root_index(attr, hdr, lrh)) { in do_action()
3452 e = Add2Ptr(attr, le16_to_cpu(lrh->attr_off)); in do_action()
3462 if (!check_if_index_root(rec, lrh) || in do_action()
3463 !check_if_root_index(attr, hdr, lrh)) { in do_action()
3467 e = Add2Ptr(attr, le16_to_cpu(lrh->attr_off)); in do_action()
3509 Add2Ptr(e, esize) > Add2Ptr(lrh, rec_len) || in do_action()
3754 const struct LOG_REC_HDR *lrh; in log_replay() local
4130 lrh = lcb->log_rec; in log_replay()
4131 frh = lcb->lrh; in log_replay()
4134 if (!check_log_rec(lrh, rec_len, le32_to_cpu(frh->transact_id), in log_replay()
4140 t16 = le16_to_cpu(lrh->redo_off); in log_replay()
4142 rt = Add2Ptr(lrh, t16); in log_replay()
4170 lrh = lcb->log_rec; in log_replay()
4171 frh = lcb->lrh; in log_replay()
4174 if (!check_log_rec(lrh, rec_len, le32_to_cpu(frh->transact_id), in log_replay()
4180 t16 = le16_to_cpu(lrh->redo_off); in log_replay()
4182 rt = Add2Ptr(lrh, t16); in log_replay()
4248 lrh = lcb->log_rec; in log_replay()
4249 frh = lcb->lrh; in log_replay()
4252 if (!check_log_rec(lrh, rec_len, le32_to_cpu(frh->transact_id), in log_replay()
4258 t32 = lrh_length(lrh); in log_replay()
4261 attr_names = kmemdup(Add2Ptr(lrh, t32), rec_len, GFP_NOFS); in log_replay()
4280 lrh = lcb->log_rec; in log_replay()
4281 frh = lcb->lrh; in log_replay()
4284 if (!check_log_rec(lrh, rec_len, le32_to_cpu(frh->transact_id), in log_replay()
4290 t16 = le16_to_cpu(lrh->redo_off); in log_replay()
4292 rt = Add2Ptr(lrh, t16); in log_replay()
4386 frh = lcb->lrh; in log_replay()
4389 lrh = lcb->log_rec; in log_replay()
4391 if (!check_log_rec(lrh, rec_len, transact_id, bytes_per_attr_entry)) { in log_replay()
4438 if (lrh->undo_op == cpu_to_le16(CompensationLogRecord)) in log_replay()
4442 switch (le16_to_cpu(lrh->redo_op)) { in log_replay()
4466 t16 = le16_to_cpu(lrh->target_attr); in log_replay()
4467 t64 = le64_to_cpu(lrh->target_vcn); in log_replay()
4509 t16 = le16_to_cpu(lrh->lcns_follow); in log_replay()
4511 size_t j = (size_t)(le64_to_cpu(lrh->target_vcn) - in log_replay()
4513 dp->page_lcns[j + i] = lrh->page_lcns[i]; in log_replay()
4520 le16_to_cpu(lrh->redo_len) / sizeof(struct LCN_RANGE); in log_replay()
4522 Add2Ptr(lrh, le16_to_cpu(lrh->redo_off)); in log_replay()
4546 t16 = le16_to_cpu(lrh->target_attr); in log_replay()
4573 t16 = le16_to_cpu(lrh->redo_off); in log_replay()
4576 struct OPEN_ATTR_ENRTY_32 *oe0 = Add2Ptr(lrh, t16); in log_replay()
4585 memcpy(oe, Add2Ptr(lrh, t16), bytes_per_attr_entry); in log_replay()
4588 t16 = le16_to_cpu(lrh->undo_len); in log_replay()
4597 Add2Ptr(lrh, le16_to_cpu(lrh->undo_off)), t16); in log_replay()
4607 t16 = le16_to_cpu(lrh->target_attr); in log_replay()
4608 t64 = le64_to_cpu(lrh->target_vcn); in log_replay()
4611 size_t j = le64_to_cpu(lrh->target_vcn) - in log_replay()
4614 dp->page_lcns[j] = lrh->page_lcns[0]; in log_replay()
4864 frh = lcb->lrh; in log_replay()
4871 lrh = lcb->log_rec; in log_replay()
4873 if (!check_log_rec(lrh, rec_len, transact_id, bytes_per_attr_entry)) { in log_replay()
4879 if (lrh->lcns_follow) in log_replay()
4885 t16 = le16_to_cpu(lrh->target_attr); in log_replay()
4886 t64 = le64_to_cpu(lrh->target_vcn); in log_replay()
4895 t16 = le16_to_cpu(lrh->target_attr); in log_replay()
4916 vcn = le64_to_cpu(lrh->target_vcn); in log_replay()
4924 data = Add2Ptr(lrh, le16_to_cpu(lrh->redo_off)); in log_replay()
4925 dlen = le16_to_cpu(lrh->redo_len); in log_replay()
4930 for (i = le16_to_cpu(lrh->lcns_follow); i; i--) { in log_replay()
4934 voff = le16_to_cpu(lrh->record_off) + in log_replay()
4935 le16_to_cpu(lrh->attr_off); in log_replay()
4936 voff += le16_to_cpu(lrh->cluster_off) << SECTOR_SHIFT; in log_replay()
4939 j = le64_to_cpu(lrh->target_vcn) - le64_to_cpu(dp->vcn); in log_replay()
4969 t16 = le16_to_cpu(lrh->redo_op); in log_replay()
4974 err = do_action(log, oe, lrh, t16, data, dlen, rec_len, &rec_lsn); in log_replay()
5021 lrh = lcb->log_rec; in log_replay()
5022 frh = lcb->lrh; in log_replay()
5026 if (!check_log_rec(lrh, rec_len, transact_id, bytes_per_attr_entry)) { in log_replay()
5031 if (lrh->undo_op == cpu_to_le16(Noop)) in log_replay()
5034 oe = Add2Ptr(oatbl, le16_to_cpu(lrh->target_attr)); in log_replay()
5037 t16 = le16_to_cpu(lrh->lcns_follow); in log_replay()
5041 is_mapped = run_lookup_entry(oa->run1, le64_to_cpu(lrh->target_vcn), in log_replay()
5052 vcn = le64_to_cpu(lrh->target_vcn); in log_replay()
5056 for (i = 0, vcn = le64_to_cpu(lrh->target_vcn), in log_replay()
5071 t16 = le16_to_cpu(lrh->undo_op); in log_replay()
5076 data = Add2Ptr(lrh, le16_to_cpu(lrh->undo_off)); in log_replay()
5077 dlen = le16_to_cpu(lrh->undo_len); in log_replay()
5080 err = do_action(log, oe, lrh, t16, data, dlen, rec_len, NULL); in log_replay()