lkml.org 
[lkml]   [2017]   [Aug]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] samples/bpf: Fix cross compiler error with bpf sample
Date
When cross-compiling the bpf sample map_perf_test for aarch64, I find that
__NR_getpgrp is undefined. This causes build errors. Fix it by allowing the
deprecated syscall in the sample.

Signed-off-by: Joel Fernandes <joelaf@google.com>
---
samples/bpf/map_perf_test_user.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/samples/bpf/map_perf_test_user.c b/samples/bpf/map_perf_test_user.c
index 1a8894b5ac51..6e6fc7121640 100644
--- a/samples/bpf/map_perf_test_user.c
+++ b/samples/bpf/map_perf_test_user.c
@@ -8,7 +8,9 @@
#include <sched.h>
#include <stdio.h>
#include <sys/types.h>
+#define __ARCH_WANT_SYSCALL_DEPRECATED
#include <asm/unistd.h>
+#undef __ARCH_WANT_SYSCALL_DEPRECATED
#include <unistd.h>
#include <assert.h>
#include <sys/wait.h>
--
2.14.0.rc1.383.gd1ce394fe2-goog
\
 
 \ /
  Last update: 2017-08-04 07:47    [W:0.077 / U:0.296 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site