• Home
  • Raw
  • Download

Lines Matching refs:m

25 static void seq_print_age_or_dash(struct seq_file *m, bool valid, unsigned long dt)  in seq_print_age_or_dash()  argument
28 seq_printf(m, "\t%d", jiffies_to_msecs(dt)); in seq_print_age_or_dash()
30 seq_printf(m, "\t-"); in seq_print_age_or_dash()
33 static void __seq_print_rq_state_bit(struct seq_file *m, in __seq_print_rq_state_bit() argument
37 seq_putc(m, *sep); in __seq_print_rq_state_bit()
38 seq_puts(m, set_name); in __seq_print_rq_state_bit()
41 seq_putc(m, *sep); in __seq_print_rq_state_bit()
42 seq_puts(m, unset_name); in __seq_print_rq_state_bit()
47 static void seq_print_rq_state_bit(struct seq_file *m, in seq_print_rq_state_bit() argument
50 __seq_print_rq_state_bit(m, is_set, sep, set_name, NULL); in seq_print_rq_state_bit()
54 static void seq_print_request_state(struct seq_file *m, struct drbd_request *req) in seq_print_request_state() argument
58 seq_printf(m, "\t0x%08x", s); in seq_print_request_state()
59 seq_printf(m, "\tmaster: %s", req->master_bio ? "pending" : "completed"); in seq_print_request_state()
62 seq_puts(m, "\tlocal:"); in seq_print_request_state()
63 seq_print_rq_state_bit(m, s & RQ_IN_ACT_LOG, &sep, "in-AL"); in seq_print_request_state()
64 seq_print_rq_state_bit(m, s & RQ_POSTPONED, &sep, "postponed"); in seq_print_request_state()
65 seq_print_rq_state_bit(m, s & RQ_COMPLETION_SUSP, &sep, "suspended"); in seq_print_request_state()
67 seq_print_rq_state_bit(m, s & RQ_LOCAL_PENDING, &sep, "pending"); in seq_print_request_state()
68 seq_print_rq_state_bit(m, s & RQ_LOCAL_COMPLETED, &sep, "completed"); in seq_print_request_state()
69 seq_print_rq_state_bit(m, s & RQ_LOCAL_ABORTED, &sep, "aborted"); in seq_print_request_state()
70 seq_print_rq_state_bit(m, s & RQ_LOCAL_OK, &sep, "ok"); in seq_print_request_state()
72 seq_puts(m, " -"); in seq_print_request_state()
75 seq_printf(m, "\tnet:"); in seq_print_request_state()
77 seq_print_rq_state_bit(m, s & RQ_NET_PENDING, &sep, "pending"); in seq_print_request_state()
78 seq_print_rq_state_bit(m, s & RQ_NET_QUEUED, &sep, "queued"); in seq_print_request_state()
79 seq_print_rq_state_bit(m, s & RQ_NET_SENT, &sep, "sent"); in seq_print_request_state()
80 seq_print_rq_state_bit(m, s & RQ_NET_DONE, &sep, "done"); in seq_print_request_state()
81 seq_print_rq_state_bit(m, s & RQ_NET_SIS, &sep, "sis"); in seq_print_request_state()
82 seq_print_rq_state_bit(m, s & RQ_NET_OK, &sep, "ok"); in seq_print_request_state()
84 seq_puts(m, " -"); in seq_print_request_state()
86 seq_printf(m, " :"); in seq_print_request_state()
88 seq_print_rq_state_bit(m, s & RQ_EXP_RECEIVE_ACK, &sep, "B"); in seq_print_request_state()
89 seq_print_rq_state_bit(m, s & RQ_EXP_WRITE_ACK, &sep, "C"); in seq_print_request_state()
90 seq_print_rq_state_bit(m, s & RQ_EXP_BARR_ACK, &sep, "barr"); in seq_print_request_state()
92 seq_puts(m, " -"); in seq_print_request_state()
93 seq_printf(m, "\n"); in seq_print_request_state()
96 static void seq_print_one_request(struct seq_file *m, struct drbd_request *req, unsigned long now) in seq_print_one_request() argument
102 seq_printf(m, "0x%x\t%llu\t%u\t%s", in seq_print_one_request()
108 seq_printf(m, "\t%d", jiffies_to_msecs(now - req->start_jif)); in seq_print_one_request()
109 seq_print_age_or_dash(m, s & RQ_IN_ACT_LOG, now - req->in_actlog_jif); in seq_print_one_request()
110 seq_print_age_or_dash(m, s & RQ_LOCAL_PENDING, now - req->pre_submit_jif); in seq_print_one_request()
113 seq_print_age_or_dash(m, s & RQ_NET_SENT, now - req->pre_send_jif); in seq_print_one_request()
114 seq_print_age_or_dash(m, (s & RQ_NET_SENT) && !(s & RQ_NET_PENDING), now - req->acked_jif); in seq_print_one_request()
115 seq_print_age_or_dash(m, s & RQ_NET_DONE, now - req->net_done_jif); in seq_print_one_request()
118 seq_print_request_state(m, req); in seq_print_one_request()
122 static void seq_print_minor_vnr_req(struct seq_file *m, struct drbd_request *req, unsigned long now) in seq_print_minor_vnr_req() argument
124 seq_printf(m, "%u\t%u\t", req->device->minor, req->device->vnr); in seq_print_minor_vnr_req()
125 seq_print_one_request(m, req, now); in seq_print_minor_vnr_req()
128 static void seq_print_resource_pending_meta_io(struct seq_file *m, struct drbd_resource *resource, … in seq_print_resource_pending_meta_io() argument
133 seq_puts(m, "minor\tvnr\tstart\tsubmit\tintent\n"); in seq_print_resource_pending_meta_io()
143 seq_printf(m, "%u\t%u\t%d\t", in seq_print_resource_pending_meta_io()
147 seq_puts(m, "-\t"); in seq_print_resource_pending_meta_io()
149 seq_printf(m, "%d\t", jiffies_to_msecs(now - tmp.submit_jif)); in seq_print_resource_pending_meta_io()
150 seq_printf(m, "%s\n", tmp.current_use); in seq_print_resource_pending_meta_io()
156 static void seq_print_waiting_for_AL(struct seq_file *m, struct drbd_resource *resource, unsigned l… in seq_print_waiting_for_AL() argument
161 seq_puts(m, "minor\tvnr\tage\t#waiting\n"); in seq_print_waiting_for_AL()
180 seq_printf(m, "%u\t%u\t", device->minor, device->vnr); in seq_print_waiting_for_AL()
182 seq_printf(m, "%u\t", jiffies_to_msecs(now - jif)); in seq_print_waiting_for_AL()
184 seq_puts(m, "-\t"); in seq_print_waiting_for_AL()
185 seq_printf(m, "%u\n", n); in seq_print_waiting_for_AL()
191 static void seq_print_device_bitmap_io(struct seq_file *m, struct drbd_device *device, unsigned lon… in seq_print_device_bitmap_io() argument
208 seq_printf(m, "%u\t%u\t%c\t%u\t%u\n", in seq_print_device_bitmap_io()
216 static void seq_print_resource_pending_bitmap_io(struct seq_file *m, struct drbd_resource *resource… in seq_print_resource_pending_bitmap_io() argument
221 seq_puts(m, "minor\tvnr\trw\tage\t#in-flight\n"); in seq_print_resource_pending_bitmap_io()
224 seq_print_device_bitmap_io(m, device, now); in seq_print_resource_pending_bitmap_io()
230 static void seq_print_peer_request_flags(struct seq_file *m, struct drbd_peer_request *peer_req) in seq_print_peer_request_flags() argument
235 __seq_print_rq_state_bit(m, f & EE_SUBMITTED, &sep, "submitted", "preparing"); in seq_print_peer_request_flags()
236 __seq_print_rq_state_bit(m, f & EE_APPLICATION, &sep, "application", "internal"); in seq_print_peer_request_flags()
237 seq_print_rq_state_bit(m, f & EE_CALL_AL_COMPLETE_IO, &sep, "in-AL"); in seq_print_peer_request_flags()
238 seq_print_rq_state_bit(m, f & EE_SEND_WRITE_ACK, &sep, "C"); in seq_print_peer_request_flags()
239 seq_print_rq_state_bit(m, f & EE_MAY_SET_IN_SYNC, &sep, "set-in-sync"); in seq_print_peer_request_flags()
240 seq_print_rq_state_bit(m, f & EE_TRIM, &sep, "trim"); in seq_print_peer_request_flags()
241 seq_print_rq_state_bit(m, f & EE_ZEROOUT, &sep, "zero-out"); in seq_print_peer_request_flags()
242 seq_print_rq_state_bit(m, f & EE_WRITE_SAME, &sep, "write-same"); in seq_print_peer_request_flags()
243 seq_putc(m, '\n'); in seq_print_peer_request_flags()
246 static void seq_print_peer_request(struct seq_file *m, in seq_print_peer_request() argument
257 seq_printf(m, "%u\t%u\t", device->minor, device->vnr); in seq_print_peer_request()
259 seq_printf(m, "%llu\t%u\t%c\t%u\t", in seq_print_peer_request()
263 seq_print_peer_request_flags(m, peer_req); in seq_print_peer_request()
271 static void seq_print_device_peer_requests(struct seq_file *m, in seq_print_device_peer_requests() argument
274 seq_puts(m, "minor\tvnr\tsector\tsize\trw\tage\tflags\n"); in seq_print_device_peer_requests()
276 seq_print_peer_request(m, device, &device->active_ee, now); in seq_print_device_peer_requests()
277 seq_print_peer_request(m, device, &device->read_ee, now); in seq_print_device_peer_requests()
278 seq_print_peer_request(m, device, &device->sync_ee, now); in seq_print_device_peer_requests()
281 seq_printf(m, "%u\t%u\t-\t-\tF\t%u\tflush\n", in seq_print_device_peer_requests()
287 static void seq_print_resource_pending_peer_requests(struct seq_file *m, in seq_print_resource_pending_peer_requests() argument
295 seq_print_device_peer_requests(m, device, now); in seq_print_resource_pending_peer_requests()
300 static void seq_print_resource_transfer_log_summary(struct seq_file *m, in seq_print_resource_transfer_log_summary() argument
309 seq_puts(m, "n\tdevice\tvnr\t" RQ_HDR); in seq_print_resource_transfer_log_summary()
351 seq_printf(m, "%u\t", count); in seq_print_resource_transfer_log_summary()
352 seq_print_minor_vnr_req(m, req, now); in seq_print_resource_transfer_log_summary()
360 static int in_flight_summary_show(struct seq_file *m, void *pos) in in_flight_summary_show() argument
362 struct drbd_resource *resource = m->private; in in_flight_summary_show()
373 seq_printf(m, "v: %u\n\n", 0); in in_flight_summary_show()
375 seq_puts(m, "oldest bitmap IO\n"); in in_flight_summary_show()
376 seq_print_resource_pending_bitmap_io(m, resource, jif); in in_flight_summary_show()
377 seq_putc(m, '\n'); in in_flight_summary_show()
379 seq_puts(m, "meta data IO\n"); in in_flight_summary_show()
380 seq_print_resource_pending_meta_io(m, resource, jif); in in_flight_summary_show()
381 seq_putc(m, '\n'); in in_flight_summary_show()
383 seq_puts(m, "socket buffer stats\n"); in in_flight_summary_show()
390 seq_printf(m, "unread receive buffer: %u Byte\n", answ); in in_flight_summary_show()
393 seq_printf(m, "unacked send buffer: %u Byte\n", answ); in in_flight_summary_show()
396 seq_putc(m, '\n'); in in_flight_summary_show()
398 seq_puts(m, "oldest peer requests\n"); in in_flight_summary_show()
399 seq_print_resource_pending_peer_requests(m, resource, jif); in in_flight_summary_show()
400 seq_putc(m, '\n'); in in_flight_summary_show()
402 seq_puts(m, "application requests waiting for activity log\n"); in in_flight_summary_show()
403 seq_print_waiting_for_AL(m, resource, jif); in in_flight_summary_show()
404 seq_putc(m, '\n'); in in_flight_summary_show()
406 seq_puts(m, "oldest application requests\n"); in in_flight_summary_show()
407 seq_print_resource_transfer_log_summary(m, resource, connection, jif); in in_flight_summary_show()
408 seq_putc(m, '\n'); in in_flight_summary_show()
412 seq_printf(m, "generated in %d ms\n", jiffies_to_msecs(jif)); in in_flight_summary_show()
499 static void seq_print_one_timing_detail(struct seq_file *m, in seq_print_one_timing_detail() argument
511 seq_printf(m, "%u\t%d\t%s:%u\t%ps\n", in seq_print_one_timing_detail()
518 static void seq_print_timing_details(struct seq_file *m, in seq_print_timing_details() argument
525 seq_printf(m, "%s\n", title); in seq_print_timing_details()
532 seq_print_one_timing_detail(m, tdp+i, now); in seq_print_timing_details()
534 seq_print_one_timing_detail(m, tdp+i, now); in seq_print_timing_details()
537 static int callback_history_show(struct seq_file *m, void *ignored) in callback_history_show() argument
539 struct drbd_connection *connection = m->private; in callback_history_show()
543 seq_printf(m, "v: %u\n\n", 0); in callback_history_show()
545 seq_puts(m, "n\tage\tcallsite\tfn\n"); in callback_history_show()
546 seq_print_timing_details(m, "worker", connection->w_cb_nr, connection->w_timing_details, jif); in callback_history_show()
547 seq_print_timing_details(m, "receiver", connection->r_cb_nr, connection->r_timing_details, jif); in callback_history_show()
573 static int connection_oldest_requests_show(struct seq_file *m, void *ignored) in connection_oldest_requests_show() argument
575 struct drbd_connection *connection = m->private; in connection_oldest_requests_show()
580 seq_printf(m, "v: %u\n\n", 0); in connection_oldest_requests_show()
585 seq_print_minor_vnr_req(m, r1, now); in connection_oldest_requests_show()
589 seq_print_minor_vnr_req(m, r1, now); in connection_oldest_requests_show()
593 seq_print_minor_vnr_req(m, r2, now); in connection_oldest_requests_show()
649 static void resync_dump_detail(struct seq_file *m, struct lc_element *e) in resync_dump_detail() argument
653 seq_printf(m, "%5d %s %s %s", bme->rs_left, in resync_dump_detail()
660 static int device_resync_extents_show(struct seq_file *m, void *ignored) in device_resync_extents_show() argument
662 struct drbd_device *device = m->private; in device_resync_extents_show()
665 seq_printf(m, "v: %u\n\n", 0); in device_resync_extents_show()
668 lc_seq_printf_stats(m, device->resync); in device_resync_extents_show()
669 lc_seq_dump_details(m, device->resync, "rs_left flags", resync_dump_detail); in device_resync_extents_show()
675 static int device_act_log_extents_show(struct seq_file *m, void *ignored) in device_act_log_extents_show() argument
677 struct drbd_device *device = m->private; in device_act_log_extents_show()
680 seq_printf(m, "v: %u\n\n", 0); in device_act_log_extents_show()
683 lc_seq_printf_stats(m, device->act_log); in device_act_log_extents_show()
684 lc_seq_dump_details(m, device->act_log, "", NULL); in device_act_log_extents_show()
690 static int device_oldest_requests_show(struct seq_file *m, void *ignored) in device_oldest_requests_show() argument
692 struct drbd_device *device = m->private; in device_oldest_requests_show()
699 seq_printf(m, "v: %u\n\n", 0); in device_oldest_requests_show()
701 seq_puts(m, RQ_HDR); in device_oldest_requests_show()
710 seq_print_one_request(m, r1, now); in device_oldest_requests_show()
712 seq_print_one_request(m, r2, now); in device_oldest_requests_show()
718 static int device_data_gen_id_show(struct seq_file *m, void *ignored) in device_data_gen_id_show() argument
720 struct drbd_device *device = m->private; in device_data_gen_id_show()
730 seq_printf(m, "0x%016llX\n", md->uuid[idx]); in device_data_gen_id_show()
737 static int device_ed_gen_id_show(struct seq_file *m, void *ignored) in device_ed_gen_id_show() argument
739 struct drbd_device *device = m->private; in device_ed_gen_id_show()
740 seq_printf(m, "0x%016llX\n", (unsigned long long)device->ed_uuid); in device_ed_gen_id_show()
843 static int drbd_version_show(struct seq_file *m, void *ignored) in drbd_version_show() argument
845 seq_printf(m, "# %s\n", drbd_buildtag()); in drbd_version_show()
846 seq_printf(m, "VERSION=%s\n", REL_VERSION); in drbd_version_show()
847 seq_printf(m, "API_VERSION=%u\n", API_VERSION); in drbd_version_show()
848 seq_printf(m, "PRO_VERSION_MIN=%u\n", PRO_VERSION_MIN); in drbd_version_show()
849 seq_printf(m, "PRO_VERSION_MAX=%u\n", PRO_VERSION_MAX); in drbd_version_show()