Skip to content

Commit a00b7e3

Browse files
mhiramatacmel
authored andcommitted
perf tools: Fix a build error on arm64 with clang
Since clang's -Wmissing-field-initializers warns if a data structure is initialized with a signle NULL as below, ---- tools/perf $ make CC=clang LLVM=1 ... arch/arm64/util/kvm-stat.c:74:9: error: missing field 'ops' initializer [-Werror,-Wmissing-field-initializers] { NULL }, ^ 1 error generated. ---- add another field initializer expressly as same as other arch's kvm-stat.c code. Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Cc: Anders Roxell <anders.roxell@linaro.org> Cc: Leo Yan <leo.yan@linaro.org> Cc: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Link: http://lore.kernel.org/lkml/162037767540.94840.15758657049033010518.stgit@devnote2 Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
1 parent b35629b commit a00b7e3

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tools/perf/arch/arm64/util/kvm-stat.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ struct kvm_reg_events_ops kvm_reg_events_ops[] = {
7171
.name = "vmexit",
7272
.ops = &exit_events,
7373
},
74-
{ NULL },
74+
{ NULL, NULL },
7575
};
7676

7777
const char * const kvm_skip_events[] = {

0 commit comments

Comments
 (0)