Lines Matching refs:opts
69 arm_spe_snapshot_resolve_auxtrace_defaults(struct record_opts *opts, in arm_spe_snapshot_resolve_auxtrace_defaults() argument
86 if (!opts->auxtrace_snapshot_size && !opts->auxtrace_mmap_pages) { in arm_spe_snapshot_resolve_auxtrace_defaults()
88 opts->auxtrace_mmap_pages = MiB(4) / page_size; in arm_spe_snapshot_resolve_auxtrace_defaults()
90 opts->auxtrace_mmap_pages = KiB(128) / page_size; in arm_spe_snapshot_resolve_auxtrace_defaults()
91 if (opts->mmap_pages == UINT_MAX) in arm_spe_snapshot_resolve_auxtrace_defaults()
92 opts->mmap_pages = KiB(256) / page_size; in arm_spe_snapshot_resolve_auxtrace_defaults()
94 } else if (!opts->auxtrace_mmap_pages && !privileged && opts->mmap_pages == UINT_MAX) { in arm_spe_snapshot_resolve_auxtrace_defaults()
95 opts->mmap_pages = KiB(256) / page_size; in arm_spe_snapshot_resolve_auxtrace_defaults()
102 if (!opts->auxtrace_snapshot_size) in arm_spe_snapshot_resolve_auxtrace_defaults()
103 opts->auxtrace_snapshot_size = opts->auxtrace_mmap_pages * (size_t)page_size; in arm_spe_snapshot_resolve_auxtrace_defaults()
109 if (!opts->auxtrace_mmap_pages) { in arm_spe_snapshot_resolve_auxtrace_defaults()
110 size_t sz = opts->auxtrace_snapshot_size; in arm_spe_snapshot_resolve_auxtrace_defaults()
113 opts->auxtrace_mmap_pages = roundup_pow_of_two(sz); in arm_spe_snapshot_resolve_auxtrace_defaults()
177 struct record_opts *opts) in arm_spe_recording_options() argument
196 opts->full_auxtrace = true; in arm_spe_recording_options()
200 if (!opts->full_auxtrace) in arm_spe_recording_options()
206 if (opts->auxtrace_snapshot_mode) { in arm_spe_recording_options()
211 if (!opts->auxtrace_snapshot_size || !opts->auxtrace_mmap_pages) in arm_spe_recording_options()
212 arm_spe_snapshot_resolve_auxtrace_defaults(opts, privileged); in arm_spe_recording_options()
217 if (opts->auxtrace_snapshot_size > opts->auxtrace_mmap_pages * (size_t)page_size) { in arm_spe_recording_options()
219 opts->auxtrace_snapshot_size, in arm_spe_recording_options()
220 opts->auxtrace_mmap_pages * (size_t)page_size); in arm_spe_recording_options()
227 if (!opts->auxtrace_snapshot_size || !opts->auxtrace_mmap_pages) { in arm_spe_recording_options()
234 if (!opts->auxtrace_mmap_pages) { in arm_spe_recording_options()
236 opts->auxtrace_mmap_pages = MiB(4) / page_size; in arm_spe_recording_options()
238 opts->auxtrace_mmap_pages = KiB(128) / page_size; in arm_spe_recording_options()
239 if (opts->mmap_pages == UINT_MAX) in arm_spe_recording_options()
240 opts->mmap_pages = KiB(256) / page_size; in arm_spe_recording_options()
245 if (opts->auxtrace_mmap_pages) { in arm_spe_recording_options()
246 size_t sz = opts->auxtrace_mmap_pages * (size_t)page_size; in arm_spe_recording_options()
256 if (opts->auxtrace_snapshot_mode) in arm_spe_recording_options()
258 opts->auxtrace_snapshot_size); in arm_spe_recording_options()
282 if (!record_opts__no_switch_events(opts)) in arm_spe_recording_options()
290 struct record_opts *opts, in arm_spe_parse_snapshot_options() argument
302 opts->auxtrace_snapshot_mode = true; in arm_spe_parse_snapshot_options()
303 opts->auxtrace_snapshot_size = snapshot_size; in arm_spe_parse_snapshot_options()