• Home
  • Raw
  • Download

Lines Matching refs:r

508 	struct printk_record r;  in log_store()  local
511 prb_rec_init_wr(&r, text_len); in log_store()
513 if (!prb_reserve(&e, prb, &r)) { in log_store()
516 prb_rec_init_wr(&r, text_len + trunc_msg_len); in log_store()
518 if (!prb_reserve(&e, prb, &r)) in log_store()
523 memcpy(&r.text_buf[0], text, text_len); in log_store()
525 memcpy(&r.text_buf[text_len], trunc_msg, trunc_msg_len); in log_store()
526 r.info->text_len = text_len + trunc_msg_len; in log_store()
527 r.info->facility = facility; in log_store()
528 r.info->level = level & 7; in log_store()
529 r.info->flags = flags & 0x1f; in log_store()
531 r.info->ts_nsec = ts_nsec; in log_store()
533 r.info->ts_nsec = local_clock(); in log_store()
534 r.info->caller_id = caller_id; in log_store()
536 memcpy(&r.info->dev_info, dev_info, sizeof(r.info->dev_info)); in log_store()
544 trace_android_vh_logbuf(prb, &r); in log_store()
691 int r; in devkmsg_emit() local
694 r = vprintk_emit(facility, level, NULL, fmt, args); in devkmsg_emit()
697 return r; in devkmsg_emit()
767 struct printk_record *r = &user->record; in devkmsg_read() local
779 if (!prb_read_valid(prb, user->seq, r)) { in devkmsg_read()
788 prb_read_valid(prb, user->seq, r)); in devkmsg_read()
794 if (r->info->seq != user->seq) { in devkmsg_read()
796 user->seq = r->info->seq; in devkmsg_read()
802 len = info_print_ext_header(user->buf, sizeof(user->buf), r->info); in devkmsg_read()
804 &r->text_buf[0], r->info->text_len, in devkmsg_read()
805 &r->info->dev_info); in devkmsg_read()
807 user->seq = r->info->seq + 1; in devkmsg_read()
1092 struct printk_record *r) in add_to_rb() argument
1097 prb_rec_init_wr(&dest_r, r->info->text_len); in add_to_rb()
1102 memcpy(&dest_r.text_buf[0], &r->text_buf[0], r->info->text_len); in add_to_rb()
1103 dest_r.info->text_len = r->info->text_len; in add_to_rb()
1104 dest_r.info->facility = r->info->facility; in add_to_rb()
1105 dest_r.info->level = r->info->level; in add_to_rb()
1106 dest_r.info->flags = r->info->flags; in add_to_rb()
1107 dest_r.info->ts_nsec = r->info->ts_nsec; in add_to_rb()
1108 dest_r.info->caller_id = r->info->caller_id; in add_to_rb()
1109 memcpy(&dest_r.info->dev_info, &r->info->dev_info, sizeof(dest_r.info->dev_info)); in add_to_rb()
1124 struct printk_record r; in setup_log_buf() local
1178 prb_rec_init_rd(&r, &info, &setup_text_buf[0], sizeof(setup_text_buf)); in setup_log_buf()
1192 prb_for_each_record(0, &printk_rb_static, seq, &r) in setup_log_buf()
1193 free -= add_to_rb(&printk_rb_dynamic, &r); in setup_log_buf()
1362 static size_t record_print_text(struct printk_record *r, bool syslog, in record_print_text() argument
1365 size_t text_len = r->info->text_len; in record_print_text()
1366 size_t buf_size = r->text_buf_size; in record_print_text()
1367 char *text = r->text_buf; in record_print_text()
1382 prefix_len = info_print_prefix(r->info, syslog, time, prefix); in record_print_text()
1458 r->text_buf[len] = 0; in record_print_text()
1483 struct printk_record r; in syslog_print() local
1491 prb_rec_init_rd(&r, &info, text, LOG_LINE_MAX + PREFIX_MAX); in syslog_print()
1498 if (!prb_read_valid(prb, syslog_seq, &r)) { in syslog_print()
1502 if (r.info->seq != syslog_seq) { in syslog_print()
1504 syslog_seq = r.info->seq; in syslog_print()
1516 n = record_print_text(&r, true, syslog_time); in syslog_print()
1519 syslog_seq = r.info->seq + 1; in syslog_print()
1552 struct printk_record r; in syslog_print_all() local
1578 prb_rec_init_rd(&r, &info, text, LOG_LINE_MAX + PREFIX_MAX); in syslog_print_all()
1581 prb_for_each_record(seq, prb, seq, &r) { in syslog_print_all()
1584 textlen = record_print_text(&r, true, time); in syslog_print_all()
1951 struct printk_record r; in log_output() local
1953 prb_rec_init_wr(&r, text_len); in log_output()
1954 if (prb_reserve_in_last(&e, prb, &r, caller_id, LOG_LINE_MAX)) { in log_output()
1955 memcpy(&r.text_buf[r.info->text_len], text, text_len); in log_output()
1956 r.info->text_len += text_len; in log_output()
1958 r.info->flags |= LOG_NEWLINE; in log_output()
1964 trace_android_vh_logbuf_pr_cont(&r, text_len); in log_output()
2108 int r; in printk() local
2111 r = vprintk_func(fmt, args); in printk()
2114 return r; in printk()
2124 #define prb_read_valid(rb, seq, r) false argument
2132 static size_t record_print_text(const struct printk_record *r, in record_print_text() argument
2449 struct printk_record r; in console_unlock() local
2456 prb_rec_init_rd(&r, &info, text, sizeof(text)); in console_unlock()
2494 if (!prb_read_valid(prb, console_seq, &r)) in console_unlock()
2497 if (console_seq != r.info->seq) { in console_unlock()
2498 console_dropped += r.info->seq - console_seq; in console_unlock()
2499 console_seq = r.info->seq; in console_unlock()
2502 if (suppress_message_printing(r.info->level)) { in console_unlock()
2525 r.info); in console_unlock()
2528 &r.text_buf[0], in console_unlock()
2529 r.info->text_len, in console_unlock()
2530 &r.info->dev_info); in console_unlock()
2532 len = record_print_text(&r, in console_unlock()
3107 int r; in vprintk_deferred() local
3109 r = vprintk_emit(0, LOGLEVEL_SCHED, NULL, fmt, args); in vprintk_deferred()
3112 return r; in vprintk_deferred()
3118 int r; in printk_deferred() local
3121 r = vprintk_deferred(fmt, args); in printk_deferred()
3124 return r; in printk_deferred()
3311 struct printk_record r; in kmsg_dump_get_line_nolock() local
3315 prb_rec_init_rd(&r, &info, line, size); in kmsg_dump_get_line_nolock()
3322 if (!prb_read_valid(prb, dumper->cur_seq, &r)) in kmsg_dump_get_line_nolock()
3324 l = record_print_text(&r, syslog, printk_time); in kmsg_dump_get_line_nolock()
3335 dumper->cur_seq = r.info->seq + 1; in kmsg_dump_get_line_nolock()
3398 struct printk_record r; in kmsg_dump_get_buffer() local
3406 prb_rec_init_rd(&r, &info, buf, size); in kmsg_dump_get_buffer()
3428 if (r.info->seq >= dumper->next_seq) in kmsg_dump_get_buffer()
3431 seq = r.info->seq + 1; in kmsg_dump_get_buffer()
3438 if (r.info->seq >= dumper->next_seq) in kmsg_dump_get_buffer()
3441 seq = r.info->seq + 1; in kmsg_dump_get_buffer()
3449 while (prb_read_valid(prb, seq, &r)) { in kmsg_dump_get_buffer()
3450 if (r.info->seq >= dumper->next_seq) in kmsg_dump_get_buffer()
3453 l += record_print_text(&r, syslog, time); in kmsg_dump_get_buffer()
3456 prb_rec_init_rd(&r, &info, buf + l, size - l); in kmsg_dump_get_buffer()
3458 seq = r.info->seq + 1; in kmsg_dump_get_buffer()