From patchwork Thu Dec 17 05:23:05 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wang Nan X-Patchwork-Id: 58519 Delivered-To: patch@linaro.org Received: by 10.112.89.199 with SMTP id bq7csp151849lbb; Wed, 16 Dec 2015 21:23:46 -0800 (PST) X-Received: by 10.98.12.17 with SMTP id u17mr11531454pfi.31.1450329826284; Wed, 16 Dec 2015 21:23:46 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k86si9905591pfj.113.2015.12.16.21.23.45; Wed, 16 Dec 2015 21:23:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966437AbbLQFXo (ORCPT + 29 others); Thu, 17 Dec 2015 00:23:44 -0500 Received: from szxga03-in.huawei.com ([119.145.14.66]:11407 "EHLO szxga03-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932169AbbLQFXn (ORCPT ); Thu, 17 Dec 2015 00:23:43 -0500 Received: from 172.24.1.47 (EHLO szxeml428-hub.china.huawei.com) ([172.24.1.47]) by szxrg03-dlp.huawei.com (MOS 4.4.3-GA FastPath queued) with ESMTP id BSX91249; Thu, 17 Dec 2015 13:23:30 +0800 (CST) Received: from linux-4hy3.site (10.107.193.248) by szxeml428-hub.china.huawei.com (10.82.67.183) with Microsoft SMTP Server id 14.3.235.1; Thu, 17 Dec 2015 13:23:19 +0800 From: Wang Nan To: , , , , , , , , , , , CC: , , Wang Nan , Alexei Starovoitov Subject: [PATCH 01/10] bpf samples: bpf: Fix tracex5_kern.c compiling error Date: Thu, 17 Dec 2015 05:23:05 +0000 Message-ID: <1450329794-161948-2-git-send-email-wangnan0@huawei.com> X-Mailer: git-send-email 1.8.3.4 In-Reply-To: <1450329794-161948-1-git-send-email-wangnan0@huawei.com> References: <1450329794-161948-1-git-send-email-wangnan0@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.107.193.248] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020203.567246D3.0077, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2013-05-26 15:14:31, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 9b15a9da2c58d612736c84aa1aff05a0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org LLVM report compiling error: /kpathsamples/bpf/tracex5_kern.c:33:15: error: use of undeclared identifier '__NR_getuid'; did you mean '__NR_vgetcpu'? if (sd.nr >= __NR_getuid && sd.nr <= __NR_getsid) { ^~~~~~~~~~~ __NR_vgetcpu /kpath/arch/x86/include/uapi/asm/vsyscall.h:7:2: note: '__NR_vgetcpu' declared here __NR_vgetcpu, This patch fix it by adding asm/unistd.h to it. Signed-off-by: Wang Nan Cc: Alexei Starovoitov Cc: David S. Miller --- samples/bpf/tracex5_kern.c | 1 + 1 file changed, 1 insertion(+) -- 1.8.3.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ diff --git a/samples/bpf/tracex5_kern.c b/samples/bpf/tracex5_kern.c index b3f4295..2964efd 100644 --- a/samples/bpf/tracex5_kern.c +++ b/samples/bpf/tracex5_kern.c @@ -8,6 +8,7 @@ #include #include #include +#include #include "bpf_helpers.h" #define PROG(F) SEC("kprobe/"__stringify(F)) int bpf_func_##F