File Index
Files and directories
Sign in
FILE

statx.c

File preview with syntax highlighting.

linux-6.19.14/tools/perf/trace/beauty/statx.c C
 1// SPDX-License-Identifier: LGPL-2.1
 2/*
 3 * trace/beauty/statx.c
 4 *
 5 *  Copyright (C) 2017, Red Hat Inc, Arnaldo Carvalho de Melo <acme@redhat.com>
 6 */
 7
 8#include "trace/beauty/beauty.h"
 9#include <sys/types.h>
10#include <linux/log2.h>
11
12static size_t statx__scnprintf_mask(unsigned long mask, char *bf, size_t size, bool show_prefix)
13{
14	#include "trace/beauty/generated/statx_mask_array.c"
15	static DEFINE_STRARRAY(statx_mask, "STATX_");
16	return strarray__scnprintf_flags(&strarray__statx_mask, bf, size, show_prefix, mask);
17}
18
19size_t syscall_arg__scnprintf_statx_mask(char *bf, size_t size, struct syscall_arg *arg)
20{
21	bool show_prefix = arg->show_string_prefix;
22	int mask = arg->val;
23
24	return statx__scnprintf_mask(mask, bf, size, show_prefix);
25}
~/ Read-only file preview.