Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\trace\trace_events_hist.c Create Date:2022-07-28 12:33:36
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:event_hist_trigger_print

Proto:static int event_hist_trigger_print(struct seq_file *m, struct event_trigger_ops *ops, struct event_trigger_data *data)

Type:int

Parameter:

TypeParameterName
struct seq_file *m
struct event_trigger_ops *ops
struct event_trigger_data *data
5629  hist_data = private_data
5631  bool have_var = false
5634  seq_puts(m, "hist:")
5636  If name Then seq_printf(m, "%s:", name)
5639  seq_puts(m, "keys=")
5642  field = fields[i]
5644  If i > n_vals Then seq_puts(m, ",")
5647  If flags & HIST_FIELD_FL_STACKTRACE Then seq_puts(m, "stacktrace")
5649  Else hist_field_print(m, field)
5653  seq_puts(m, ":vals=")
5656  field = fields[i]
5657  If flags & HIST_FIELD_FL_VAR Then
5658  have_var = true
5659  Continue
5662  If i == HITCOUNT_IDX Then seq_puts(m, "hitcount")
5664  Else
5665  seq_puts(m, ",")
5666  hist_field_print(m, field)
5670  If have_var Then
5671  n = 0
5673  seq_puts(m, ":")
5676  field = fields[i]
5678  If flags & HIST_FIELD_FL_VAR Then
5679  If n++ Then seq_puts(m, ",")
5686  seq_puts(m, ":sort=")
5688  When i < n_sort_keys cycle
5693  first_key_idx = n_vals - n_vars
5695  sort_key = sort_keys[i]
5696  idx = field_idx
5698  If WARN_ON(idx >= HIST_FIELDS_MAX) Then Return -EINVAL
5701  If i > 0 Then seq_puts(m, ",")
5704  If idx == HITCOUNT_IDX Then seq_puts(m, "hitcount")
5706  Else
5707  If idx >= first_key_idx Then idx += n_vars
5712  If descending Then seq_puts(m, ".descending")
5715  seq_printf(m, ":size=%u", (1 << map_bits))
5716  If enable_timestamps Then seq_printf(m, ":clock=%s", clock)
5719  print_actions_spec(m, hist_data)
5721  If filter_str Then seq_printf(m, " if %s", filter_str)
5724  If paused Then seq_puts(m, " [paused]")
5726  Else seq_puts(m, " [active]")
5729  seq_putc(m, '\n')
5731  Return 0